Jump to content

Video playback Ubuntu 16.04 vs 20.04


Gausus

Recommended Posts

I have tested video playback on:

 X96max plus (S905x3)
 TX5 pro (S905x)
 M96X (S912)

 

-1080p youtube playback from chromium h264ify addon.
-Video playback 1080p from MPV  in full screen, window mode often lag.

 

On bionic video plays fine from chromium and youtube , but in focal video lags.

Testet on kernel 5.7 rc 2 before and after apt upgrade to kernel 5.7.16
Tested on latest focal and earlier versions on focal. 

 

No setting are changed

 

Even when running same kernel on focal and bionic the same thing happen (video lag on focal).
Why does focal videoplayback lag.

What settings are changed i focal ?

After kernel verion 5,7 rc7 there is a vertical green line on the left side of the screen in focal and bionic.
 

Link to comment
Share on other sites

Yes.

 

Tested panfrost, no difference in chromium or MPV.

sudo nano /etc/X11/xorg.conf.d/01-armbian-defaults.conf

Option      "AccelMethod"    "glamor"     ### "glamor" to enable 3D acceleration, "none"

 

Desktop often gets blurred when enabling and 2D slow.

 

There most be some other settings / tweak changed from bionic to focal.

 

Link to comment
Share on other sites

5 hours ago, Gausus said:

Yes.

 

Tested panfrost, no difference in chromium or MPV.

sudo nano /etc/X11/xorg.conf.d/01-armbian-defaults.conf

Option      "AccelMethod"    "glamor"     ### "glamor" to enable 3D acceleration, "none"

 

Desktop often gets blurred when enabling and 2D slow.

 

There most be some other settings / tweak changed from bionic to focal.

 

panfrost doesn't accelerate video decoding, for that in amlogic you need vdec. Work as been done, but I don't now what is the state now , @UniformBuffer in this

 was able to make it work with kernel 5.7.15. I wasn't able to make it work with balbes image Ver 20200828 kernel 5.7.16 in my X96 air (S905x3)

Maybe some one can say some thing about the state of video hardware decoding.

Edited by dante6913
Link to comment
Share on other sites

Hi,

i confirm that for me hardware acceleration works. I use AML-S905X-CC board on kernel 5.8.5 (updated today).

Maybe a difference with my configuration is that i do not use Xorg, i use Wayland desktop environments.

There are many out there and some can be even installed from apt, like Gnome,Sway and Phosh. I personally use Wayfire that i have compiled myself.

Another difference (maybe) is that i have added Debian Sid to my repository list, so i got very cutting edge mesa drivers. I currently have mesa 20.1.6.

When running "mpv --hwdec=yes *a youtube video*" i got

Spoiler

 (+) Video --vid=1 (*) (vp9 1280x720 30.000fps)
 (+) Audio --aid=1 --alang=eng (*) (opus 2ch 48000Hz)
     Subs  --sid=1 --slang=fr 'vtt' (webvtt) (external)
     Subs  --sid=2 --slang=ko 'vtt' (webvtt) (external)
     Subs  --sid=3 --slang=uk 'vtt' (webvtt) (external)
     Subs  --sid=4 --slang=zh-HK 'vtt' (webvtt) (external)
     Subs  --sid=5 --slang=en 'vtt' (webvtt) (external)
     Subs  --sid=6 --slang=th 'vtt' (webvtt) (external)
     Subs  --sid=7 --slang=bg 'vtt' (webvtt) (external)
     Subs  --sid=8 --slang=es-419 'vtt' (webvtt) (external)
     Subs  --sid=9 --slang=ar 'vtt' (webvtt) (external)
     Subs  --sid=10 --slang=hu 'vtt' (webvtt) (external)
     Subs  --sid=11 --slang=iw 'vtt' (webvtt) (external)
     Subs  --sid=12 --slang=cs 'vtt' (webvtt) (external)
     Subs  --sid=13 --slang=sv 'vtt' (webvtt) (external)
     Subs  --sid=14 --slang=ja 'vtt' (webvtt) (external)
     Subs  --sid=15 --slang=vi 'vtt' (webvtt) (external)
     Subs  --sid=16 --slang=el 'vtt' (webvtt) (external)
     Subs  --sid=17 --slang=de 'vtt' (webvtt) (external)
     Subs  --sid=18 --slang=hi 'vtt' (webvtt) (external)
     Subs  --sid=19 --slang=ru 'vtt' (webvtt) (external)
     Subs  --sid=20 --slang=tr 'vtt' (webvtt) (external)
     Subs  --sid=21 --slang=pt 'vtt' (webvtt) (external)
     Subs  --sid=22 --slang=es 'vtt' (webvtt) (external)
     Subs  --sid=23 --slang=ro 'vtt' (webvtt) (external)
     Subs  --sid=24 --slang=fa 'vtt' (webvtt) (external)
     Subs  --sid=25 --slang=mn 'vtt' (webvtt) (external)
     Subs  --sid=26 --slang=id 'vtt' (webvtt) (external)
     Subs  --sid=27 --slang=pl 'vtt' (webvtt) (external)
     Subs  --sid=28 --slang=it 'vtt' (webvtt) (external)
[vaapi] libva: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)
Failed to open VDPAU backend libvdpau_nvidia.so: cannot open shared object file: No such file or directory
AO: [pulse] 48000Hz stereo 2ch float
Using hardware decoding (v4l2m2m-copy).
VO: [gpu] 1280x720 nv12
AV: 00:00:00 / 00:05:44 (0%) A-V:  0.423 Cache: 34s/3MB

 

After saying this, hardware decoding is not working great, i got a lot of dropped frames and warning messages from mpv like:

Spoiler

Audio/Video desynchronisation detected! Possible reasons include too slow
hardware, temporary CPU spikes, broken drivers, and broken files. Audio
position will not match to the video (see A-V status field).

 

Running the same command without "--hwdec" run much better and, even if it do not use the hardware decoding, the video player is still hardware accelerated on the gpu (VO: [gpu] 1280x720 nv12).

Don't get me wrong, i appreciate a lot that something at least start working, i know it's not easy to manage this kind of things, so congrats Armbian Team :beer:.

Can't wait to get full hardware decoding support! :D

 

Edit:

oh, i forgot to say that i have found no way to get the same thing on browsers, so i generally watch videos on mpv.

Maybe enabling Firefox Webrender could allow hardware decoding from v4l2. Unfortunatly i got errors regarding "failed to create EGL context" when enabled.

Link to comment
Share on other sites

9 minutes ago, UniformBuffer said:

Hi,

i confirm that for me hardware acceleration works. I use AML-S905X-CC board on kernel 5.8.5 (updated today).

Maybe a difference with my configuration is that i do not use Xorg, i use Wayland desktop environments.

There are many out there and some can be even installed from apt, like Gnome,Sway and Phosh. I personally use Wayfire that i have compiled myself.

Another difference (maybe) is that i have added Debian Sid to my repository list, so i got very cutting edge mesa drivers. I currently have mesa 20.1.6.

When running "mpv --hwdec=yes *a youtube video*" i got

  Reveal hidden contents

 (+) Video --vid=1 (*) (vp9 1280x720 30.000fps)
 (+) Audio --aid=1 --alang=eng (*) (opus 2ch 48000Hz)
     Subs  --sid=1 --slang=fr 'vtt' (webvtt) (external)
     Subs  --sid=2 --slang=ko 'vtt' (webvtt) (external)
     Subs  --sid=3 --slang=uk 'vtt' (webvtt) (external)
     Subs  --sid=4 --slang=zh-HK 'vtt' (webvtt) (external)
     Subs  --sid=5 --slang=en 'vtt' (webvtt) (external)
     Subs  --sid=6 --slang=th 'vtt' (webvtt) (external)
     Subs  --sid=7 --slang=bg 'vtt' (webvtt) (external)
     Subs  --sid=8 --slang=es-419 'vtt' (webvtt) (external)
     Subs  --sid=9 --slang=ar 'vtt' (webvtt) (external)
     Subs  --sid=10 --slang=hu 'vtt' (webvtt) (external)
     Subs  --sid=11 --slang=iw 'vtt' (webvtt) (external)
     Subs  --sid=12 --slang=cs 'vtt' (webvtt) (external)
     Subs  --sid=13 --slang=sv 'vtt' (webvtt) (external)
     Subs  --sid=14 --slang=ja 'vtt' (webvtt) (external)
     Subs  --sid=15 --slang=vi 'vtt' (webvtt) (external)
     Subs  --sid=16 --slang=el 'vtt' (webvtt) (external)
     Subs  --sid=17 --slang=de 'vtt' (webvtt) (external)
     Subs  --sid=18 --slang=hi 'vtt' (webvtt) (external)
     Subs  --sid=19 --slang=ru 'vtt' (webvtt) (external)
     Subs  --sid=20 --slang=tr 'vtt' (webvtt) (external)
     Subs  --sid=21 --slang=pt 'vtt' (webvtt) (external)
     Subs  --sid=22 --slang=es 'vtt' (webvtt) (external)
     Subs  --sid=23 --slang=ro 'vtt' (webvtt) (external)
     Subs  --sid=24 --slang=fa 'vtt' (webvtt) (external)
     Subs  --sid=25 --slang=mn 'vtt' (webvtt) (external)
     Subs  --sid=26 --slang=id 'vtt' (webvtt) (external)
     Subs  --sid=27 --slang=pl 'vtt' (webvtt) (external)
     Subs  --sid=28 --slang=it 'vtt' (webvtt) (external)
[vaapi] libva: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)
Failed to open VDPAU backend libvdpau_nvidia.so: cannot open shared object file: No such file or directory
AO: [pulse] 48000Hz stereo 2ch float
Using hardware decoding (v4l2m2m-copy).
VO: [gpu] 1280x720 nv12
AV: 00:00:00 / 00:05:44 (0%) A-V:  0.423 Cache: 34s/3MB

 

After saying this, hardware decoding is not working great, i got a lot of dropped frames and warning messages from mpv like:

  Reveal hidden contents

Audio/Video desynchronisation detected! Possible reasons include too slow
hardware, temporary CPU spikes, broken drivers, and broken files. Audio
position will not match to the video (see A-V status field).

 

Running the same command without "--hwdec" run much better and, even if it do not use the hardware decoding, the video player is still hardware accelerated on the gpu (VO: [gpu] 1280x720 nv12).

Don't get me wrong, i appreciate a lot that something at least start working, i know it's not easy to manage this kind of things, so congrats Armbian Team :beer:.

Can't wait to get full hardware decoding support! :D

 

Edit:

oh, i forgot to say that i have found no way to get the same thing on browsers, so i generally watch videos on mpv

I was using ubuntu 20.04 focal, I even tried with wayland but no luck to. Maybe this was the reason

Link to comment
Share on other sites

10 minutes ago, dante6913 said:

I was using ubuntu 20.04 focal, I even tried with wayland but no luck to. Maybe this was the reason

My original image is Debian Buster, then i have added Debian Sid repository. I don't know if this could be the root of the problem, in general Ubuntu should be, as far as i know, a more updated version of Debian, but i could be wrong. Obviously there are much more differences, but i don't think some of them could make this problem. I think that a more robust reason could be packages versions, Debian Sid provide a much more cutting edge (tecnically experimental) than standard Ubuntu.

Link to comment
Share on other sites

2 hours ago, Bozza said:

How do you install Ubuntu on your system? Is there a way to run other operating systems besides Balbes' images? 

 

I tested on Armbian_20.05.3_Arm-64_bionic_current_5.7.0-rc2_desktop_20200425.img (Ubuntu 16.04).

Before and after apt upgrade to kernel 5.7.16.

 

Its only in bionic video plays fine.

 

Video plays fine from MPV in full screen and almost fine inn chromium using h264ify video add-on.

Have tested new bionic images from Balbes installing desktop from armbian-config, video lags on them to.

There most be some change inn config , on older images video plays fine even when upgrading to latest kernel.

 

Video tested MPV.

 

Format                       : MPEG-4
Format profile            : Base Media
Codec ID                    : isom (isom/avc1)
File size                      : 2.00 GiB
Duration                     : 1 h 56 min
Overall bit rate mode : Variable
Overall bit rate            : 2 472 kb/

 

 

Link to comment
Share on other sites

Hi,

i have plugged a monitor with a different resolution (1920x1080) and i have noticed that i don't get hardware acceleration anymore.

To get the hardware acceleration i have to run the mpv at 1280x720 resolution.

If i use "mpv --hwdec=yes --ytdl-format="bestvideo[height<=?720][fps<=?60][vcodec=?vp9]+bestaudio/best" *youtube video*" to force resolution to 1280x720, i get hw acceleration again.

Running "v4l2-ctl --all" i got:

Spoiler


Driver Info:
    Driver name      : meson-vdec
    Card type        : Amlogic Video Decoder
    Bus info         : platform:meson-vdec
    Driver version   : 5.8.5
    Capabilities     : 0x84204000
        Video Memory-to-Memory Multiplanar
        Streaming
        Extended Pix Format
        Device Capabilities
    Device Caps      : 0x04204000
        Video Memory-to-Memory Multiplanar
        Streaming
        Extended Pix Format
Priority: 2
Format Video Capture Multiplanar:
    Width/Height      : 1280/720
    Pixel Format      : 'NM12' (Y/CbCr 4:2:0 (N-C))
    Field             : None
    Number of planes  : 2
    Flags             :  
    Colorspace        : Default
    Transfer Function : Default
    YCbCr/HSV Encoding: Default
    Quantization      : Default
    Plane 0           :
       Bytes per Line : 1280
       Size Image     : 983040
    Plane 1           :
       Bytes per Line : 1280
       Size Image     : 491520
Format Video Output Multiplanar:
    Width/Height      : 1280/720
    Pixel Format      : 'VP90' (VP9)
    Field             : None
    Number of planes  : 1
    Flags             :  
    Colorspace        : Default
    Transfer Function : Default
    YCbCr/HSV Encoding: Default
    Quantization      : Default
    Plane 0           :
       Bytes per Line : 0
       Size Image     : 1048576
 
User Controls
 
  min_number_of_capture_buffers 0x00980927 (int)    : min=1 max=32 step=1 default=1 value=1 flags=read-only

 

As you can see it reports support for vp9 1280x720, so maybe you (and now also me :() don't get hardware acceleration because your monitor have an unsupported resolution for the vpu (or at least the vpu driver, the board should support up tp 4k 60fps).

Edited by UniformBuffer
Precisation
Link to comment
Share on other sites

  • Werner locked this topic
Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines