[GStreamer][WebRTC] Implement GstMappedRtpBuffer#9373
[GStreamer][WebRTC] Implement GstMappedRtpBuffer#9373webkit-early-warning-system merged 1 commit intoWebKit:mainfrom
Conversation
|
EWS run on previous version of this PR (hash 793f937) Details
|
|
EWS run on previous version of this PR (hash 23e2bb8) Details
|
There was a problem hiding this comment.
If this implementation is the same as the GstMappedBuffer with the only difference of map/unmap functions, I think we should do some templating here and optionally pass the map/unmap functions. Then, if you want, you can create the GstRTPMappedBuffer with a using.
The public API differs though. |
|
In what, other than the type? |
GstMappedBuffer has |
Source/WebCore/Modules/mediastream/gstreamer/GStreamerWebRTCUtils.h
Outdated
Show resolved
Hide resolved
I still think it is worth trying. It does not hurt to have them. You need four template parameters, but nothing outstanding. If you want, you can avoid using default parameters and create a GstBufferBaseMappedBuffer with the four template parameters (GstBuffer, GstMapInfo (which also seems to differ for RTP), map and unmap). Then you create GstBufferMap with a We would be reducing a lot the code duplication. |
Yes and I tried this already :) |
You don't need to use all the API. I am very reluctant to create something that is almost equal in code to something that can change a couple of types and functions. That's what templates are for, right? |
|
Let's revisit this PR when we have more than one usage of |
|
For me, one use is enough and templating is the way to go |
|
EWS run on previous version of this PR (hash d761e31) Details
|
|
EWS run on current version of this PR (hash 0ffe5ca) Details
|
https://bugs.webkit.org/show_bug.cgi?id=251428 Reviewed by Xabier Rodriguez-Calvar. With this new RAII object for mapping RTP buffers we don't need to manually unmap anymore. Canonical link: https://commits.webkit.org/261074@main
0ffe5ca to
7878d72
Compare
|
Committed 261074@main (7878d72): https://commits.webkit.org/261074@main Reviewed commits have been landed. Closing PR #9373 and removing active labels. |
7878d72
0ffe5ca
🧪 ios-wk2🧪 api-mac🧪 api-ios🧪 mac-AS-debug-wk2