-
Notifications
You must be signed in to change notification settings - Fork 1.6k
[GStreamer][GL] Enable DMABuf sink #10588
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
EWS run on previous version of this PR (hash e9832c9)
|
if (webKitDMABufVideoSinkIsEnabled() && webKitDMABufVideoSinkProbePlatform()) | ||
if (webKitDMABufVideoSinkProbePlatform()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These two conditions should match conditions in createVideoSinkDMABuf()
. Otherwise things can get weird with using TextureMapperPlatformLayerProxyDMABuf along with a GL sink.
So I would recommend keeping webKitDMABufVideoSinkIsEnabled()
, and using WEBKIT_GST_DISABLE_DMABUF_SINK
env to disable it. That way behavior between DMABuf sink and GL sink can be examined by selectively disabling one or the other, as long as they coexist.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense! I'll update the PR, thanks for the review.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we can make this work with GST_PLUGIN_FEATURE_RANK=webkitdmabufsink:0
too. I can try that, I've been wondering lately about avoid new env vars when we can...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
GST_PLUGIN_FEATURE_RANK works only during gst_init_check()
so for our custom elements registered afterwards we'd need to re-parse the env var... Not sure it's worth.
EWS run on previous version of this PR (hash 5a20129)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other than what @zdobersek said, I think we would be good to go.
EWS run on previous version of this PR (hash 681cc1e)
|
The test bots doesn't like this PR at all. Somehow the dmabuf sink is misbehaving there, is that supposed to work in XvFB and similar antique setups? |
Check https://ews-build.webkit.org/#/builders/86/builds/389 And the GTK EWS for layout tests seems to be detecting something similar. |
Yeah I noticed the previous version of the patch was already flagged... Crash is in gbm_bo_create()... I guess those bots don't have whatever GBM requires, like a GPU? |
That is right: the bots don't have a GPU. There are no |
@zdobersek wdyt about making |
Sounds a bit hackish. Maybe an idea is checking that we pass a valid device when calling I guess (not checked) the call to |
We want to fallback to the GL sink when dmabuf sink is not usable, so doing the check in GBMBufferSwapchain seems a bit late, no? |
EWS run on current version of this PR (hash bd1b6f2) |
bd1b6f2 worked 🎉 -> https://ews-build.webkit.org/#/builders/86/builds/590 |
https://bugs.webkit.org/show_bug.cgi?id=252826 Reviewed by Žan Doberšek and Xabier Rodriguez-Calvar. Unconditionally enable the DMABuf sink when running with GStreamer 1.22 and newer. The WEBKIT_GST_DMABUF_SINK_DISABLED environment variable can be set to fallback to the GL sink. * Source/WebCore/platform/graphics/gstreamer/DMABufVideoSinkGStreamer.cpp: (webKitDMABufVideoSinkGetProperty): (webKitDMABufVideoSinkIsEnabled): (webKitDMABufVideoSinkProbePlatform): * Tools/Scripts/webkitpy/port/glib.py: (GLibPort.setup_environ_for_server): Canonical link: https://commits.webkit.org/260881@main
bd1b6f2
to
e962336
Compare
Committed 260881@main (e962336): https://commits.webkit.org/260881@main Reviewed commits have been landed. Closing PR #10588 and removing active labels. |
e962336
bd1b6f2