RESOLVED FIXED 208572
[GStreamer][GL] External OES textures rendering support
https://bugs.webkit.org/show_bug.cgi?id=208572
Summary [GStreamer][GL] External OES textures rendering support
Philippe Normand
Reported 2020-03-04 07:10:36 PST
.
Attachments
Patch (18.35 KB, patch)
2020-03-04 07:16 PST, Philippe Normand
no flags
Patch (19.23 KB, patch)
2020-03-04 09:53 PST, Philippe Normand
no flags
Patch (18.13 KB, patch)
2020-03-04 09:55 PST, Philippe Normand
no flags
Patch (18.14 KB, patch)
2020-03-05 03:06 PST, Philippe Normand
zan: review+
Philippe Normand
Comment 1 2020-03-04 07:16:15 PST
Philippe Normand
Comment 2 2020-03-04 07:21:09 PST
Checking GTK build.
Xabier Rodríguez Calvar
Comment 3 2020-03-04 07:52:53 PST
Comment on attachment 392412 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=392412&action=review This looks good from the GStreamer perspective but maybe some other people with more graphics proficiency could have another look. > Source/WebCore/platform/graphics/gstreamer/GLVideoSinkGStreamer.cpp:235 > - gst_pad_add_probe(pad.get(), static_cast<GstPadProbeType>(GST_PAD_PROBE_TYPE_PUSH | GST_PAD_PROBE_TYPE_QUERY_DOWNSTREAM | GST_PAD_PROBE_TYPE_EVENT_FLUSH), [] (GstPad*, GstPadProbeInfo* info, gpointer userData) -> GstPadProbeReturn { > + gst_pad_add_probe(pad.get(), static_cast<GstPadProbeType>(GST_PAD_PROBE_TYPE_PUSH | GST_PAD_PROBE_TYPE_QUERY_DOWNSTREAM | GST_PAD_PROBE_TYPE_EVENT_FLUSH), [] (GstPad* pad, GstPadProbeInfo* info, gpointer userData) -> GstPadProbeReturn { > + These change seems to be unnecessary.
Philippe Normand
Comment 4 2020-03-04 08:15:12 PST
Comment on attachment 392412 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=392412&action=review > Source/WebCore/platform/graphics/texmap/TextureMapperShaderProgram.cpp:173 > + GLSL_DIRECTIVE(extension GL_OES_EGL_image_external : require) This and the sampler declaration break GTK at runtime. The shader seems to fail to compile but no error is reported.
Philippe Normand
Comment 5 2020-03-04 09:53:15 PST
Philippe Normand
Comment 6 2020-03-04 09:55:32 PST
Zan Dobersek
Comment 7 2020-03-05 02:23:46 PST
Comment on attachment 392431 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=392431&action=review > Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:331 > - return makeUnique<Buffer>(Buffer::TextureVariant { Buffer::RGBTexture { *static_cast<GLuint*>(m_videoFrame.data[0]) } }, m_size, m_flags, GL_RGBA); > + return makeUnique<Buffer>(Buffer::TextureVariant { Buffer::RGBTexture { m_textureID } }, m_size, m_flags, GL_RGBA); For a separate patch: we could maybe drop m_textureID in favor of using m_videoFrame.data directly. > Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:394 > + GstGLTextureTarget m_textureTarget; This could be default-initialized to `GST_GL_TEXTURE_TARGET_NONE`. > Source/WebCore/platform/graphics/texmap/TextureMapperShaderProgram.cpp:178 > + OES_EGL_IMAGE_EXTERNAL_DIRECTIVE I think this directive should be written only if the program options demand it.
Philippe Normand
Comment 8 2020-03-05 03:06:14 PST
Zan Dobersek
Comment 9 2020-03-10 01:10:31 PDT
Comment on attachment 392553 [details] Patch LGTM.
Philippe Normand
Comment 10 2020-03-10 05:09:13 PDT
Radar WebKit Bug Importer
Comment 11 2020-03-10 05:10:13 PDT
Note You need to log in before you can comment on or make changes to this bug.