It can play 4K h264 but with a fair bit of dropped frames. CPU resources usage is fairly low. I don’t think it will support HEVC-10bits (earlier rpi-ffmpeg-6.0 crashes the system).
4K-HEVC-10bits immediately crashes the whole system! Per my understanding currenly “VDEC” does not support HEVC 10bits.
Ok. media.ffvpx.enabled default is “true”. Now set it to “false” Firefox 116.0.3 now stream https://www.youtube.com/watch?v=aqz-KE-bpKQ vp09 1080p/60 with much less dropped frame rates (<1% droppe frames). But the CPU resource use is still quite high (all 6 CPU Core > 50% , this lead me to believe no vpu hw acceleration.
jfl@jfl-gtkpro MOZ_GFX_DEBUG=1 MOZ_LOG=“PlatformDecoderModule:5” firefox
GLX_TEST: childgltest start
GLX_TEST: get_pci_status start
GLX_TEST: get_pci_status finished
GLX_TEST: x11_egltest start
GLX_TEST: get_egl_status start
GLX_TEST: get_egl_gl_status start
GLX_TEST: get_egl_gl_status finished
GLX_TEST: get_egl_status finished with return: 1
GLX_TEST: get_xrandr_info start
GLX_TEST: get_xrandr_info finished
GLX_TEST: x11_egltest finished
DRI_DRIVER
meson
VENDOR
Mesa
RENDERER
Mali-G52 (Panfrost)
VERSION
OpenGL ES 3.1 Mesa 23.1.4
TFP
TRUE
WARNING
DRM render node not clearly detectable. Falling back to using the only one that was found.
DRM_RENDERDEVICE
/dev/dri/renderD128
MESA_VENDOR_ID
0x2970
MESA_DEVICE_ID
0x001b
TEST_TYPE
EGL
GLX_TEST: childgltest finished
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM render node not clearly detectable. Falling back to using the only one that was found. (t=1.59464) [GFX1-]: glxtest: DRM render node not clearly detectable. Falling back to using the only one that was found.
vaapitest start, device /dev/dri/renderD128
libva error: /usr/lib/dri/v4l2_request_drv_video.so init failed
vaInitialize failed 1
ERROR
VA-API test failed: failed to initialise VAAPI connection.
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM render node not clearly detectable. Falling back to using the only one that was found. (t=1.59464) |[1][GFX1-]: vaapitest: ERROR (t=1.65877) [GFX1-]: vaapitest: ERROR
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM render node not clearly detectable. Falling back to using the only one that was found. (t=1.59464) |[1][GFX1-]: vaapitest: ERROR (t=1.65877) |[2][GFX1-]: vaapitest: VA-API test failed: failed to initialise VAAPI connection.
(t=1.65884) [GFX1-]: vaapitest: VA-API test failed: failed to initialise VAAPI connection.
v4l2test probing device '/dev/video0'
v4l2test driver meson-vdec card Amlogic Video Decoder bus_info platform:meson-vdec version 393514
V4L2_SPLANE
FALSE
V4L2_MPLANE
TRUE
V4L2_CAPTURE_FMTS
NM12
V4L2_OUTPUT_FMTS
VP90 HEVC H264 MPG1 MPG2
V4L2_SUPPORTED
TRUE
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.
(firefox:6280): dconf-WARNING **: 23:04:27.967: unable to open file '/etc/dconf/db/local': /etc/dconf/db/local: invalid gvdb header; expect degraded performance
It is interesting you have less dropped frams using ffmpeg than what firefox has internal.
Just to be clear mpv with rpi-ffmpeg performed much better than Firefox in terms of dropped frames and CPU resources usage.
Firefox with media.ffvpx.enabled = false performed much better than with media.ffvpx.enabled = true in terms of dropped frames.
Yes, mpv and rpi-ffmpeg-6.0 vpu hw acceleration is working with h264 up to 1080p/60.
jfl@jfl-gtkpro mpv --gpu-context=wayland --hwdec=v4l2m2m https://www.larmoire.info/jellyfish/media/jellyfish-40-mbps-hd-hevc.mkv
(+) Video --vid=1 (*) (hevc 1920x1080 29.970fps)
[vo/gpu/wayland] GNOME's wayland compositor lacks support for the idle inhibit protocol. This means the screen can blank during playback.
Using hardware decoding (v4l2m2m).
VO: [gpu] 1920x1080 drm_prime[nv12]
V: 00:00:29 / 00:00:30 (99%) Cache: 0.0s
Invalid video timestamp: 29.997000 -> 29.930000
V: 00:00:29 / 00:00:30 (99%) Cache: 0.0s
Exiting... (End of file)
With 4k-uhd-h264.mkv dropped frames is around 40%.
jfl@jfl-gtkpro mpv --gpu-context=wayland --hwdec=v4l2m2m '/home/jfl/Videos/jellyfish-120-mbps-4k-uhd-h264.mkv'
(+) Video --vid=1 (*) (h264 3840x2160 29.970fps)
[vo/gpu/wayland] GNOME's wayland compositor lacks support for the idle inhibit protocol. This means the screen can blank during playback.
Using hardware decoding (v4l2m2m).
VO: [gpu] 3840x2160 drm_prime[nv12]
V: 00:00:29 / 00:00:30 (100%) Dropped: 360
Exiting... (End of file)
Firefox wutg roi-ffmpeg-6.0 doesn’t seems to enable vpu hw acceleration on my device. Could it be environmental settings issue?
Well thanks to your rpi-ffmpeg-6.0 packaging, vpu hw acceleration is enabled on mpv.
When Chromium 116 lands on Unstable Branch will check whether vpu hw acceleration enabled.
On my device dropped frames 360 is equivalent to 40% dropped frames [360/(30x30)] and video was jerky.
jfl@jfl-gtkpro mpv --gpu-context=wayland --hwdec=v4l2m2m '/home/jfl/Videos/jellyfish-120-mbps-4k-uhd-h264.mkv'
(+) Video --vid=1 (*) (h264 3840x2160 29.970fps)
[vo/gpu/wayland] GNOME's wayland compositor lacks support for the idle inhibit protocol. This means the screen can blank during playback.
Using hardware decoding (v4l2m2m).
VO: [gpu] 3840x2160 drm_prime[nv12]
V: 00:00:29 / 00:00:30 (100%) Dropped: 360
Exiting... (End of file)
Yes it does pretty much like yours. See my above post. Watching the video though I do not see any jerking. There are a huge amount of frames in that video going at 120 mbps.
Just wondering what “libva” packages need to be install in order to trigger Firefox not to fail “libva-v4l2-request”?
Currently on my system the “libva” and “libva-v4l2-request” had been installed. Is this what had been installed in your system only?
“libva-mesa-driver” “libva-utils” and “libva1” had not been installed. Are these packages required?
Additional info:
On Manjaro-Arm-KDE-linux-aml-6.1.42-1 which had "ffmpeg-m2m-1:4.4-7 installed
launching Firefox with Debug Mode, there is NO “v4l2_request_drv_video.so init failed”
O Manjaro-Arm-Gnome-linux-aml-6.1.42-1 which has “rpi-ffmpeg” installed the “v4l2_request_drv_video.so init failed” is there.
But both Firefox does not have vpu hw acceleration as far as I can tell base on CPU Resources used when streaming h264 video.
Manjaro-Arm-KDE-linux-aml-6.1.42-1 Unstable Branch
MOZ_GFX_DEBUG=1 MOZ_LOG=“PlatformDecoderModule:5” firefox
[jfl@jfl-mnjro ~]$ MOZ_GFX_DEBUG=1 MOZ_LOG=“PlatformDecoderModule:5” firefox
GLX_TEST: childgltest start
GLX_TEST: get_pci_status start
GLX_TEST: get_pci_status finished
GLX_TEST: x11_egltest start
GLX_TEST: get_egl_status start
GLX_TEST: get_egl_gl_status start
GLX_TEST: get_egl_gl_status finished
GLX_TEST: get_egl_status finished with return: 1
GLX_TEST: get_xrandr_info start
GLX_TEST: get_xrandr_info finished
GLX_TEST: x11_egltest finished
DRI_DRIVER
meson
VENDOR
Mesa
RENDERER
Mali-G52 (Panfrost)
VERSION
OpenGL ES 3.1 Mesa 23.1.4
TFP
TRUE
WARNING
DRM render node not clearly detectable. Falling back to using the only one that was found.
DRM_RENDERDEVICE
/dev/dri/renderD128
MESA_VENDOR_ID
0x75f0
MESA_DEVICE_ID
0xbc8e
TEST_TYPE
EGL
GLX_TEST: childgltest finished
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM render node not clearly detectable. Falling back to using the only one that was found. (t=1.0686) [GFX1-]: glxtest: DRM render node not clearly detectable. Falling back to using the only one that was found.
vaapitest start, device /dev/dri/renderD128
vaInitialize failed -1
ERROR
VA-API test failed: failed to initialise VAAPI connection.
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM render node not clearly detectable. Falling back to using the only one that was found. (t=1.0686) |[1][GFX1-]: vaapitest: ERROR (t=1.12897) [GFX1-]: vaapitest: ERROR
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM render node not clearly detectable. Falling back to using the only one that was found. (t=1.0686) |[1][GFX1-]: vaapitest: ERROR (t=1.12897) |[2][GFX1-]: vaapitest: VA-API test failed: failed to initialise VAAPI connection.
(t=1.12904) [GFX1-]: vaapitest: VA-API test failed: failed to initialise VAAPI connection.
v4l2test probing device '/dev/video0'
v4l2test driver meson-vdec card Amlogic Video Decoder bus_info platform:meson-vdec version 393514
V4L2_SPLANE
FALSE
V4L2_MPLANE
TRUE
V4L2_CAPTURE_FMTS
NM12
V4L2_OUTPUT_FMTS
VP90 HEVC H264 MPG1 MPG2
V4L2_SUPPORTED
TRUE
ATTENTION: default value of option mesa_glthread overridden by environment.
RPi does not use VAAPI. A lot of those libva programs get installed as depends with various programs to be used if supported by various devices. Since you have HW with mpv and not firefox I would say that the issue is in firefox it’s self and maybe lack of support for your vpu. I have no clue though other than that.
I’m not seing that here on the unstable branch. I wonder if you have some git version installed from when you were messing with mpv with HW a while back.
[ray@jellyfin ~]$ ls -lah /usr/lib/libSPIRV.so*
lrwxrwxrwx 1 root root 14 Jul 28 12:33 /usr/lib/libSPIRV.so -> libSPIRV.so.12
lrwxrwxrwx 1 root root 11 Jul 28 12:33 /usr/lib/libSPIRV.so.0 -> libSPIRV.so
lrwxrwxrwx 1 root root 18 Jul 28 12:33 /usr/lib/libSPIRV.so.12 -> libSPIRV.so.12.3.1
-rwxr-xr-x 1 root root 3.1M Jul 28 12:33 /usr/lib/libSPIRV.so.12.3.1
[ray@jellyfin ~]$ pacman -Qo /usr/lib/libSPIRV.so.12
/usr/lib/libSPIRV.so.12 is owned by glslang 12.3.1-2
[ray@jellyfin ~]$ pacman -Ss glslang
extra/glslang 12.3.1-2 [installed]
OpenGL and OpenGL ES shader front end and validator
[ray@jellyfin ~]$ pacman -Qi glslang
...
Required By : libplacebo shaderc
...