rohlik
Posts: 9
Joined: Sun Apr 05, 2020 3:58 pm

FullHD playback on RPi4 with hardware acceleration

Sun Apr 05, 2020 4:23 pm

Hello everyone,
I am the owner of Raspberry Pi 4B with 2GB RAM and latest Raspbian OS.
I already did some basic testing with HTML5 FullHD video or with Youtube and 1080p video, but playback is jerky and definitely not smooth.
I tried legacy GL driver and also fake KMS with GPU memory is setup to 256MB. I tried different combinations but without success.

Is even possible to get what I want on RPi4? :roll:

My current CHROMIUM_FLAGS are:

Code: Select all

CHROMIUM_FLAGS="${CHROMIUM_FLAGS} --ignore-gpu-blacklist --enable-one-copy-rasterizer --enable-gpu-rasterization --enable-native-gpu-memory-buffers --enable-checker-imaging --enable-quic --site-per-process --enable-tcp-fastopen --disable-features=MaterialDesignBookmarks --disable-gpu-compositing --enable-fast-unload --enable-experimental-canvas-features --enable-scroll-prediction --answers-in-suggest --ppapi-flash-path=/usr/lib/chromium-browser/libpepflashplayer.so --ppapi-flash-args=enable_stagevideo_auto=0 --ppapi-flash-version= --max-tiles-for-interest-area=512 --num-raster-threads=4 --default-tile-height=512"
chrome://gpu output:

Code: Select all

Graphics Feature Status
Canvas: Hardware accelerated
Flash: Hardware accelerated
Flash Stage3D: Hardware accelerated
Flash Stage3D Baseline profile: Hardware accelerated
Compositing: Hardware accelerated
Multiple Raster Threads: Enabled
Out-of-process Rasterization: Disabled
OpenGL: Enabled
Hardware Protected Video Decode: Unavailable
Rasterization: Hardware accelerated
Skia Renderer: Enabled
Video Decode: Unavailable
Viz Display Compositor: Enabled
Vulkan: Disabled
WebGL: Hardware accelerated
WebGL2: Hardware accelerated

snowballEarth
Posts: 92
Joined: Wed Feb 18, 2015 9:05 pm

Re: FullHD playback on RPi4 with hardware acceleration

Sun Apr 12, 2020 10:48 am

For smooth fullscreen 1080p30 playback:
sudo raspi-config > Advanced Options > Compositor > "No"
In the top right of browser, click the "h" icon. Then in h264ify settings block 60fps.
Reboot and restart browser.
Screen tearing only fixed in full screen, when cursor/toolbar has faded away.
Dropped frames only eliminated up to 30fps.
Haven't tested 4k playback

Return to “Beginners”