-
Notifications
You must be signed in to change notification settings - Fork 126
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
intel-vaapi-driver fails to load in a Gnome Shell Wayland session #203
Comments
totem drops write permission before accessing device file, please refer to https://github.com/01org/libva/issues/53. As for gst-play, it seems this is an issue in gst-vaapi. |
try mpv player it does not use gst-vaapi. On my ubuntu 17.04 gst-vaapi lags mpv does not. |
Thanks @montvid , I closed this bug as 'not our bug'. @vanvugt Please file a bug on http://bugzilla.gnome.org to track your gst-vaapi issue. |
mpv does not use VAAPI by default. It defaults to high-CPU software decoding (50% CPU). If you force it to use VAAPI (mpv --hwdec vaapi) then performance is excellent (2% CPU). However the same issue remains -- intel-vaapi-driver is only willing to work in a Xorg session but fails in a Wayland session. This proves that VAAPI works well with ffmpeg (gst-vaapi is not in use). And that the only common factor in this bug is intel-vaapi-driver. The problem is not Gstreamer... Output from a Gnome-on-Wayland session:
|
Please reopen this bug. It has been shown to not be an issue that is specific to GStreamer, but occurs with FFmpeg hwaccel too. Put another way, both GStreamer and FFmpeg playback crashes in the same place inside intel-vaapi-driver when you're using Wayland. |
Ah, mpv actually seems to reimplement VA-API support independently of ffmpeg's hwaccel architecture. However the important point remains that it's also not using GStreamer. So whatever this bug is, it exists in mpv too... |
The assertion failure was fixed on master branch weeks ago. Does your wayland compositor support wl_drm interface? You can run weston-info to check whether wl_drm is used if you is using weston. $> weston-info | grep drm Note: the assertion failure means the player fails to create a workable connection to the native display server for VA-API, you should check your environment. |
mpv works for me under Wayland. $ mpv --hwdec vaapi 720p.mp4 Playing: 720p.mp4 |
gst-play-1.0 works too, the cpu usage is about 2~3. $ gst-play-1.0 720p.mp4 |
I'm using Gnome Shell on Wayland....
but still:
It only works in a Xorg session still. |
Perhaps weston-info isn't actually getting that data from Gnome Shell, but the weston binaries (which we're not using). |
Yes, I can confirm Weston works fine. This bug seems to be Gnome Shell on Wayland only. |
OK, we have multiple bugs here. mpv can be made to work in a Gnome Shell Wayland session if you unset $DISPLAY (which is always set for legacy apps to use Xwayland). However that does not fix gst-play-1.0 or totem. Seems https://github.com/01org/libva/issues/53 is still a separate bug for totem. And there might be a third bug for gst-play-1.0. |
For wayland support in mpv use --opengl-backend=wayland it works with latest software for sure. Also check https://wiki.ubuntu.com/IntelQuickSyncVideo Good luck. |
Thanks. That seems to further confirm the problem is incorrect detection of Wayland vs X. This works in Gnome Shell on Wayland: mpv --hwdec --opengl-backend=wayland I don't really need to check out that wiki page though, because I wrote it :) |
The Intel i965 VA-API driver works well in Xorg sessions (Unity7 and Gnome Shell). But it refuses to load when in a Wayland session:
$ totem bbb_sunflower_1080p_60fps_normal.mp4
libva error: va_getDriverName() failed with unknown libva error,driver_name=(null)
$ env LIBVA_DRIVER_NAME=i965 totem bbb_sunflower_1080p_60fps_normal.mp4
totem: intel_driver.c:112: intel_driver_init: Assertion `VA_CHECK_DRM_AUTH_TYPE(ctx, VA_DRM_AUTH_DRI1) || VA_CHECK_DRM_AUTH_TYPE(ctx, VA_DRM_AUTH_DRI2) || VA_CHECK_DRM_AUTH_TYPE(ctx, VA_DRM_AUTH_CUSTOM)' failed.
Aborted (core dumped)
$ gst-play-1.0 bbb_sunflower_1080p_60fps_normal.mp4
Press 'k' to see a list of keyboard shortcuts.
Now playing /home/dan/Videos/bbb_sunflower_1080p_60fps_normal.mp4
Redistribute latency...
Redistribute latency...
ERROR Internal error: could not render surface for file:///home/dan/Videos/bbb_sunflower_1080p_60fps_normal.mp4
ERROR debug information: ../../../gst/vaapi/gstvaapisink.c(1482): gst_vaapisink_show_frame_unlocked (): /GstPlayBin:playbin/GstPlaySink:playsink/GstBin:vbin/GstVaapiSink:vaapisink0
See also: https://bugs.launchpad.net/bugs/1698287
The text was updated successfully, but these errors were encountered: