Specific video players for Wayland ?

Hello.

I'm running Wayland / Wayfire right now. I would like to watch some videos,but I see that the tools that I use usually when I run Xorg don't work on Wayland. They crash. Instead I would like to use a good player that can offer also the video acceleration,since the GPU that I'm using is nvidia and it is well recognized. (and yes,I have enabled xwayland).

For example :

Code:
smplayer :

mpv --no-quiet --terminal --no-msg-color --input-ipc-server=/tmp/smplayer-mpv-1772
--msg-level=ffmpeg/demuxer=error --video-rotate=no --no-config --no-fs --hwdec=no
--sub-auto=fuzzy --vo=xv,x11, --no-input-default-bindings --input-vo-keyboard=no
--no-input-cursor --cursor-autohide=no --no-keepaspect --wid=6 --monitorpixelaspect=1
--osd-level=2 --osd-scale=1 --osd-bar-align-y=0.6 --sub-ass --embeddedfonts
--sub-ass-line-spacing=0 --sub-scale=1 --sub-font=Arial --sub-color=#ffffffff
--sub-shadow-color=#ff000000 --sub-border-color=#ff000000 --sub-border-size=0.75
--sub-shadow-offset=2.5 --sub-font-size=50 --sub-bold=no --sub-italic=no --sub-margin-y=8
--sub-margin-x=20 --sub-codepage=ISO-8859-1 --sub-pos=100 --volume=72 --cache=auto
--screenshot-template=cap_%F_%p_%02n --screenshot-format=jpg
--screenshot-directory=/home/marietto/Pictures/smplayer_screenshots
--audio-pitch-correction=yes --volume-max=110 --loop-file=inf
--term-playing-msg=MPV_VERSION=${=mpv-version:}

--audio-client-name=SMPlayer --term-status-msg=STATUS: ${=time-pos}
/ ${=duration:${=length:0}} P: ${=pause} B:${=paused-for-cache} I: ${=core-idle}
VB: ${=video-bitrate:0} AB: ${=audio-bitrate:0} /mnt/zroot2/zroot2/P/W/video.mp4

(+) Video --vid=1 (*) (h264 1280x720 25.000fps)
(+) Audio --aid=1 (*) (aac 2ch 44100Hz)
[vo/xv/x11] X11 error: BadDrawable (invalid Pixmap or Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: 6, serial: 12
[vo/xv/x11] Error code: 9, request code: e, minor code: 0
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: 6, serial: 13
[vo/xv/x11] Error code: 3, request code: 28, minor code: 0
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: 6, serial: 14
[vo/xv/x11] Error code: 3, request code: 2, minor code: 0
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: 6, serial: 18
[vo/xv/x11] Error code: 3, request code: 1, minor code: 0
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: a00002, serial: 1b
[vo/xv/x11] Error code: 3, request code: 12, minor code: 0
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: a00002, serial: 1e
[vo/xv/x11] Error code: 3, request code: 92, minor code: 3
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: a00002, serial: 20
[vo/xv/x11] Error code: 3, request code: 12, minor code: 0
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: a00002, serial: 21
[vo/xv/x11] Error code: 3, request code: 12, minor code: 0
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: a00002, serial: 23
[vo/xv/x11] Error code: 3, request code: 12, minor code: 0
[vo/xv/x11] X11 error: BadWindow (invalid Window parameter)
[vo/xv/x11] Type: 0, display: 0xf1214484000, resourceid: a00002, serial: 24
[vo/xv/x11] Error code: 3, request code: 12, minor code: 0
[vo/xv] No Xvideo support found.
X Error of failed request:  BadWindow (invalid Window parameter)
Major opcode of failed request:  4 (X_DestroyWindow)
Resource id in failed request:  0xa00002
Serial number of failed request:  40
Current serial number in output stream:  43

$ vlc

VLC media player 3.0.20 Vetinari (revision 3.0.20-0-g6f0d0ab126b)

DRI3 not available
failed to load driver: zink

main playlist: playlist is empty
MESA: error: CreateSwapchainKHR failed with VK_ERROR_OUT_OF_DEVICE_MEMORY
MESA: error: zink: could not create swapchain
chain filter error: Too high level of recursion (3)
main filter error: Failed to create video converter
chain filter error: Too high level of recursion (3)
main filter error: Failed to create video converter
main filter error: Failed to create video converter
main filter error: Failed to create video converter
main vout display error: Failed to create video converter
main vout display error: Failed to adapt decoder format to display
main video output error: video output creation failed
main decoder error: failed to create video output
DRI3 not available
failed to load driver: zink
avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  550.54.14
Thu Feb 22 01:04:00 UTC 2024 for hardware decoding
avcodec decoder error: hardware acceleration picture allocation failed
[h264 @ 0x822d6b400] get_buffer() failed
[h264 @ 0x822d6b400] thread_get_buffer() failed
[h264 @ 0x822d6b400] decode_slice_header error
[h264 @ 0x822d6b400] no frame!

what's the reason ? what's broken ? Should I use a specific player for Wayland ? what's the name ?
 
Code:
marietto@marietto:/mnt/zroot2/zroot2/P/W $ xvinfo
X-Video Extension version 2.2
screen #0
no adaptors present

what's this mean ? whats missing ? how to fix it ?
 
Code:
marietto@marietto:/mnt/zroot2/zroot2/P/W $ kldstat | grep nvidia
15    2 0xffffffff83510000   125678 nvidia-modeset.ko
16    2 0xffffffff83800000  3118000 nvidia.ko
18    1 0xffffffff83668000    108f0 nvidia-drm.ko
 
there is no specific player for wayland. There is an actual error in your output for vlc.
[0000000822c66760] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library 550.54.14 Thu Feb 22 01:04:00 UTC 2024 for hardware decoding
[0000000822c66760] avcodec decoder error: hardware acceleration picture allocation failed
simply try, mpv --hwdec=vdpau your-file-to-play, but i can't tell for sure but I recalling that mpv for hardware acceleration on not-too-old nvidia cards using NVDEC and it needs CUDA ( i.e mpv --hwdec=nvdec ). I think it is possible to enable cuda somehow to be accessed from FreeBSD.
 
mpv is the best video player on freebsd and linux
hardware acceleration and yt-dlp in the backend


 
Well, what you might have to use here is a video player that falls back to plain X11 without XVideo. I am surprised that the players you tried don't do that (anymore?). Try xine.
 
Is this correct ? because it does not work properly. What's the correct value to put there ?

20240312_15h41m00s_grim.png
 
i dont use smplayer
try using just mpv and see if that works

you just need vo=gpu in the mpv.conf

~/.config/mpv/mpv.conf

Code:
 mpv.conf

# list profiles with: mpv --profile=help

# load hwdec profile automatically
profile=hwdec

# hardware acceleration profile
[hwdec]
profile-desc="hardware acceleration, no cache, yt-dlp 1080 or less"
vo=gpu

# hide: GNOME's wayland compositor lacks support for the idle inhibit protocol.
#msg-level=ffmpeg=fatal,vo/gpu/wayland=no

# cache no for internet streams
cache=no

# yt-dlp best format 1080 or less
ytdl-format="bestvideo[height<=?1080]+bestaudio/best"

# show milliseconds in the on screen display
osd-fractions

# alsa pipewire audio device
#audio-device=alsa/pipewire

# youtube subs - J to switch to subs
sub-auto=fuzzy
ytdl-raw-options=sub-lang="en",write-sub=,write-auto-sub=
sub-font='NotoColorEmoji'

# screenshot timecode
screenshot-template="%F-[%P]v%#01n"

# show progress bar in the terminal
#term-osd-bar
 
ok it works with the pure "mpv",but not with the smplayer gui. Would be interesting to understand how to make it work with the gui,also. vlc does not work at all.
 
Well, what you might have to use here is a video player that falls back to plain X11 without XVideo. I am surprised that the players you tried don't do that (anymore?). Try xine.

Code:
marietto@marietto:/mnt/zroot2/zroot2/P/W $ xine
(c) 2000-2019 The xine Team.
XIO:  fatal IO error 35 (Resource temporarily unavailable) on X server ":0"
      after 1664 requests (1661 known processed) with 0 events remaining.
 
Code:
marietto@marietto:/mnt/zroot2/zroot2/P/W $ xine
(c) 2000-2019 The xine Team.
XIO:  fatal IO error 35 (Resource temporarily unavailable) on X server ":0"
      after 1664 requests (1661 known processed) with 0 events remaining.

Well, that looks like a broken X11 server.
 
I just checked xvinfo under a wayland session on Ubuntu. XVideo is present:

Code:
X-Video Extension version 2.2
screen #0
  Adaptor #0: "glamor textured video"
    number of ports: 16
    port base: 100
    operations supported: PutImage 
    supported visuals:
      depth 24, visualID 0x47
    number of attributes: 5
      "XV_BRIGHTNESS" (range -1000 to 1000)
              client settable attribute
              client gettable attribute (current value is 0)
      "XV_CONTRAST" (range -1000 to 1000)
              client settable attribute
              client gettable attribute (current value is 0)
      "XV_SATURATION" (range -1000 to 1000)
              client settable attribute
              client gettable attribute (current value is 0)
      "XV_HUE" (range -1000 to 1000)
              client settable attribute
              client gettable attribute (current value is 0)
      "XV_COLORSPACE" (range 0 to 1)
              client settable attribute
              client gettable attribute (current value is 0)
    maximum XvImage size: 16384 x 16384
    Number of image formats: 3
      id: 0x32315659 (YV12)
        guid: 59563132-0000-0010-8000-00aa00389b71
        bits per pixel: 12
        number of planes: 3
        type: YUV (planar)
      id: 0x30323449 (I420)
        guid: 49343230-0000-0010-8000-00aa00389b71
        bits per pixel: 12
        number of planes: 3
        type: YUV (planar)
      id: 0x3231564e (NV12)
        guid: 4e563132-0000-0010-8000-00aa00389b71
        bits per pixel: 12
        number of planes: 2
        type: YUV (planar)
 
Back
Top