[webkit-reviews] review granted: [Bug 206289] [GStreamer][WPE] Client-side video rendering support : [Attachment 387790] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Jan 15 08:41:04 PST 2020
Xabier Rodríguez Calvar <calvaris at igalia.com> has granted Philippe Normand
<pnormand at igalia.com>'s request for review:
Bug 206289: [GStreamer][WPE] Client-side video rendering support
https://bugs.webkit.org/show_bug.cgi?id=206289
Attachment 387790: Patch
https://bugs.webkit.org/attachment.cgi?id=387790&action=review
--- Comment #2 from Xabier Rodríguez Calvar <calvaris at igalia.com> ---
Comment on attachment 387790
--> https://bugs.webkit.org/attachment.cgi?id=387790
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=387790&action=review
>
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:259
> +
wpe_video_plane_display_dmabuf_source_update(videoPlaneDisplayDmaBufSource,
m_dmabufFD, rect.x(), rect.y(), m_size.width(), m_size.height(),
m_dmabufStride, [](void* data) {
> + gst_buffer_unref(GST_BUFFER_CAST(data));
> + }, gst_buffer_ref(m_buffer.get()));
Is this lambda a C callback? If not, then it would be nice to capture the smart
pointer (by copy!) inside the lambda.
>
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:487
> +#if USE(WPE_VIDEO_PLANE_DISPLAY_DMABUF)
> + if (m_wpeVideoPlaneDisplayDmaBuf)
> +
wpe_video_plane_display_dmabuf_source_destroy(m_wpeVideoPlaneDisplayDmaBuf);
> +#endif
> +
I think we can use GUniquePtr by defining this as deleter in
GUniquePtrGStreamer.h, can't we?
>
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:3146
> + GStreamerDMABufHolePunchClient(std::unique_ptr<GstVideoFrameHolder>
frameHolder, struct wpe_video_plane_display_dmabuf_source*
videoPlaneDisplayDmaBufSource)
I think we should be taking a std::unique_ptr<GstVideoFrameHolder>&&
frameHolder, specially with the way you call this constructor.
>
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:3181
> + proxy.pushNextBuffer(WTFMove(layerBuffer));
And from what I see, TextureMapperPlatformLayerProxy::pushNextBuffer lacks a &&
in the parameter as well. Either we add it or we are not taking advantage of
all the WTFMove calling it.
More information about the webkit-reviews
mailing list