12 12
JMCC

[Development] RK3399 media script

Recommended Posts

After installation of the media script, I experience very slow window dragging, i. e. moving a window is laggy and delayed - the mouse is faster and the window follows only very slowly. Do you experience the same?

 

"Enable display compositing" in Window Manager Tweaks is disabled as advised. Enabling "Hide the content of the window while moving" in Window Manager Advance settings at least speeds up moving windows a little bit, but not much.

 

Is this normal behavior or is there anything I can do to improve display performance?

Share this post


Link to post
Share on other sites
Armbian is a community driven open source project. Do you like to contribute your code?

@mar0ni - yes this is normal behaviour i think as there is some inefficient memory copying happening between the gpu and the x server and there is no proper 2d acceleration (used for such window moves) around ... but i guess @JMCC can explain it in more detail ...

 

best wishes - hexdump

Share this post


Link to post
Share on other sites

Yes, it is a known issue with glamor, that instead of "accelerating" it slows down certain 2D operations. In the case of Rockchip's modified glamor to work with OpenGL-ES, It is even worse. It is the trade-off for having the possibility of an accelerated canvas for 3D, video playing, browser, etc.

 

However, in the mainline kernel and current X server, they are tweaking glamor to be much more efficient. Hopefully we can see a stable version soon.

Share this post


Link to post
Share on other sites

Thanks for clarification :thumbup:. I have read this in your first post's documentation and therefor chose "amsoc" during installation. It seems that armsoc is also not that snappy, but good to know that glamor is even worse. Let's hope mainline with a current X server arrives soon :)

Share this post


Link to post
Share on other sites

The script is not compatible with Armbian 20.02.0-rc1, as the Kodi uses `nodm`, but Armbian 20.02.0-rc1 uses lightdm. 

 

I have to modify the kodi-gbm-wrapper script to get it work. However, to `service lightdm stop` requiring *authentication*.  so it wont smoothly go to kodi. 

 

Last thing is the version - kodi  18rc4 - it doesn't have PVR addons, and it seems to be a known issue:

https://forum.kodi.tv/showthread.php?tid=336841

 

Update: Feb 7

After further search, I find the PVR addons for Ubuntu platform requires special installation

https://kodi.wiki/view/Ubuntu_PVR_add-ons

 

I tried `apt install kodi-pvr-iptvsimple`, but failed with dependency error: 

kodi-api-pvr (= 5.2.1)

 

I am looking for an update for the Kodi installation script :) 

Share this post


Link to post
Share on other sites
On 2/6/2020 at 10:48 AM, Lesca said:

The script is not compatible with Armbian 20.02.0-rc1, as the Kodi uses `nodm`, but Armbian 20.02.0-rc1 uses lightdm. 

 

I am looking for an update for the Kodi installation script :) 

Ditto. Friendly seem to have permanently broken the video acceleration even though Chromium reports it as there. They have also added lots of junk.

 

Armbian with this script is my preference.

 

Share this post


Link to post
Share on other sites
On 2/7/2020 at 9:10 AM, Secarius said:

Hi did anyone managed to use the eDP port on the Nano PC T4?

 

I couldn't get it to work at all. IMO, Friendly generally has sketchy hardware compatibility and only loosely adheres to specs and standards.

Share this post


Link to post
Share on other sites

Working on Wayland integration and would like a good starting point.

 

Please post which boards work and specific test results.

 

I'll keep the list updated.

 

 Board  Overall 

 GPU

 accelerated

 Desktop

 WebGL  VPU encode

 VPU decode

 4K@60

 10-bit

 HEVC

 OpenGL ES 3.2  OpenCL 1.2
 NanoPi TC4  ?        OK    
 NanoPi M4  ?        Some freezing    
 RockPro 64  OK

 OK

 X11

 OK

Chromium

 ?  OK  OK  OK
 Khadas EDGE  ?        OK    
 RockPi 4B   Install failed        ?    
 ROCK960C  ?        OK    
               
               
               

 

last updated: 2020-06-01

Share this post


Link to post
Share on other sites

hello, 

 

After install the media script i can not get gpu hw acceleration.

my current system is

orange pi 4 with rk3399

kernel 4.4.216-rk3399
Description:    Ubuntu 18.04.4 LTS
Release:    18.04
Codename:    bionic

when I play video with mpv the cpu go  more of 150%.

how can I know that the orange pi has the hw acceleration enabled?

 

 

note > only one day hw acceleration was working but the next day stop working.

 

Thx!

 

Regards


 

 

Share this post


Link to post
Share on other sites

Maybe some update overwrote the config. Have you tried re-running the script?

Share this post


Link to post
Share on other sites

yes  I run the script again , today let me test in a clean armbian image.

 

 

6 hours ago, JMCC said:

Maybe some update overwrote the config. Have you tried re-running the script?

 

Share this post


Link to post
Share on other sites
14 hours ago, Memo said:

yes  I run the script again , today let me test in a clean armbian image.

 

 

 

I re running the script but the cpu % goes to high, after that  I run script again but  in  a new armbian image, and cpu goes to high to

 

how can I launch 

I use differents options to launch mpv (--hwdec=rkmpp --vo=drm). but always cpu goes to high

what I doing wrong?

Thx

Share this post


Link to post
Share on other sites
4 hours ago, Memo said:

I re running the script but the cpu % goes to high, after that  I run script again but  in  a new armbian image, and cpu goes to high to

 

how can I launch 

I use differents options to launch mpv (--hwdec=rkmpp --vo=drm). but always cpu goes to high

what I doing wrong?

Thx

 

Please post the output of the following commands:

$ uname -r
$ ls -l /dev/mali*
$ ls -l /dev/rk*
$ ls -l /dev/vpu*

 

Share this post


Link to post
Share on other sites
16 hours ago, JMCC said:

 

Please post the output of the following commands:


$ uname -r
$ ls -l /dev/mali*
$ ls -l /dev/rk*
$ ls -l /dev/vpu*

 

hello  here is the output 

 

 

4.4.213-rk3399

crw-rw---- 1 root video 10, 53 Jun 14 04:37 /dev/mali0

crw-rw---- 1 root video 243, 0 Jun 14 04:37 /dev/rkvdec

crw-rw---- 1 root video 244, 0 Jun 14 04:37 /dev/vpu_service
 

 

Share this post


Link to post
Share on other sites
    _    ____  __  __        __   _  _
   / \  |  _ \|  \/  |      / /_ | || |
  / _ \ | |_) | |\/| |_____| '_ \| || |_
 / ___ \|  _ <| |  | |_____| (_) |__   _|
/_/   \_\_| \_\_|  |_|      \___/   |_|

Welcome to Armbian Focal with Linux 5.7.0-rc2-arm-64

No end-user support: built from trunk & unsupported (focal) userspace!

System load:   2.50 0.64 0.22  	Up time:       0 min
Memory usage:  17 % of 3797MB 	IP:            169.254.13.15 192.168.1.167
CPU temp:      69°C
Usage of /:    18% of 29G    	storage/:      1% of 117G

[ General system configuration (beta): armbian-config ]


294 updates can be installed immediately.
101 of these updates are security updates.
To see these additional updates run: apt list --upgradable

Last login: Tue Apr 28 13:19:17 2020 from 192.168.1.214

root@orangepi-arm-64:~# uname -a
Linux orangepi-arm-64 5.7.0-rc2-arm-64 #20.05.3 SMP PREEMPT Sat Apr 25 13:17:40 MSK 2020 aarch64 aarch64 aarch64 GNU/Linux

Hello, i run armbian on orange pi rk3399 , bun I don`t know how take ffmpeg accelerated and other 

 

ls -l /dev/vpu* /dev/rk* /dev/vpu*
ls: cannot access '/dev/vpu*': No such file or directory
ls: cannot access '/dev/rk*': No such file or directory
ls: cannot access '/dev/vpu*': No such file or directory
[    33.917] (--) Log file renamed from "/var/log/Xorg.pid-1938.log" to "/var/log/Xorg.0.log"
[    33.921]
X.Org X Server 1.20.8
X Protocol Version 11, Revision 0
[    33.921] Build Operating System: Linux 4.4.0-177-generic aarch64 Ubuntu
[    33.921] Current Operating System: Linux orangepi-arm-64 5.7.0-rc2-arm-64 #20.05.3 SMP PREEMPT Sat Apr 25 13:17:40 MSK 2020 aarch64
[    33.921] Kernel command line: root=LABEL=ROOTFS rootflags=data=writeback rw console=uart8250,mmio32,0xff1a0000 console=tty0 no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0
[    33.921] Build Date: 06 April 2020  09:39:29AM
[    33.921] xorg-server 2:1.20.8-2ubuntu2 (For technical support please see http://www.ubuntu.com/support)
[    33.921] Current version of pixman: 0.38.4
[    33.921] 	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
[    33.921] Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[    33.921] (==) Log file: "/var/log/Xorg.0.log", Time: Fri Aug  7 15:17:24 2020
[    33.929] (==) Using config directory: "/etc/X11/xorg.conf.d"
[    33.929] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[    33.940] (==) No Layout section.  Using the first Screen section.
[    33.941] (==) No screen section available. Using defaults.
[    33.941] (**) |-->Screen "Default Screen Section" (0)
[    33.941] (**) |   |-->Monitor "<default monitor>"
[    33.949] (==) No device specified for screen "Default Screen Section".
	Using the first device section listed.
[    33.949] (**) |   |-->Device "Default Device"
[    33.949] (==) No monitor specified for screen "Default Screen Section".
	Using a default monitor configuration.
[    33.949] (**) Option "AutoAddGPU" "off"
[    33.949] (**) Option "Debug" "dmabuf_capable"
[    33.949] (==) Automatically adding devices
[    33.949] (==) Automatically enabling devices
[    33.949] (**) Not automatically adding GPU devices
[    33.949] (==) Automatically binding GPU devices
[    33.949] (==) Max clients allowed: 256, resource mask: 0x1fffff
[    33.982] (WW) The directory "/usr/share/fonts/X11/cyrillic" does not exist.
[    33.982] 	Entry deleted from font path.
[    33.982] (WW) The directory "/usr/share/fonts/X11/100dpi/" does not exist.
[    33.982] 	Entry deleted from font path.
[    33.982] (WW) The directory "/usr/share/fonts/X11/75dpi/" does not exist.
[    33.982] 	Entry deleted from font path.
[    33.987] (WW) The directory "/usr/share/fonts/X11/100dpi" does not exist.
[    33.987] 	Entry deleted from font path.
[    33.987] (WW) The directory "/usr/share/fonts/X11/75dpi" does not exist.
[    33.987] 	Entry deleted from font path.
[    33.987] (==) FontPath set to:
	/usr/share/fonts/X11/misc,
	/usr/share/fonts/X11/Type1,
	built-ins
[    33.987] (==) ModulePath set to "/usr/lib/xorg/modules"
[    33.987] (II) The server relies on udev to provide the list of input devices.
	If no devices become available, reconfigure udev or disable AutoAddDevices.
[    33.987] (II) Loader magic: 0xaaaab21f4010
[    33.987] (II) Module ABI versions:
[    33.987] 	X.Org ANSI C Emulation: 0.4
[    33.987] 	X.Org Video Driver: 24.1
[    33.987] 	X.Org XInput driver : 24.1
[    33.987] 	X.Org Server Extension : 10.0
[    33.989] (++) using VT number 2

[    33.993] (II) systemd-logind: took control of session /org/freedesktop/login1/session/_32
[    33.995] (II) xfree86: Adding drm device (/dev/dri/card0)
[    33.996] (II) systemd-logind: got fd for /dev/dri/card0 226:0 fd 12 paused 0
[    33.997] (II) xfree86: Adding drm device (/dev/dri/card1)
[    33.999] (II) systemd-logind: got fd for /dev/dri/card1 226:1 fd 13 paused 0
[    34.000] (II) no primary bus or device found
[    34.000] 	falling back to /sys/devices/platform/display-subsystem/drm/card0
[    34.000] (II) LoadModule: "glx"
[    34.006] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[    34.164] (II) Module glx: vendor="X.Org Foundation"
[    34.164] 	compiled for 1.20.8, module version = 1.0.0
[    34.164] 	ABI class: X.Org Server Extension, version 10.0
[    34.164] (II) LoadModule: "modesetting"
[    34.171] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[    34.183] (II) Module modesetting: vendor="X.Org Foundation"
[    34.183] 	compiled for 1.20.8, module version = 1.20.8
[    34.183] 	Module class: X.Org Video Driver
[    34.184] 	ABI class: X.Org Video Driver, version 24.1
[    34.184] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[    34.185] (II) modeset(0): using drv /dev/dri/card0
[    34.186] (II) modeset(0): Creating default Display subsection in Screen section
	"Default Screen Section" for depth/fbbpp 24/32
[    34.187] (==) modeset(0): Depth 24, (==) framebuffer bpp 32
[    34.187] (**) modeset(0): Option "AccelMethod" "none"
[    34.187] (==) modeset(0): RGB weight 888
[    34.187] (==) modeset(0): Default visual is TrueColor
[    34.187] (**) modeset(0): glamor disabled
[    34.187] (II) modeset(0): ShadowFB: preferred NO, enabled NO
[    34.187] (II) modeset(0): Output HDMI-1 has no monitor section
[    34.187] (II) modeset(0): EDID for output HDMI-1
[    34.187] (II) modeset(0): Output HDMI-1 disconnected
[    34.187] (WW) modeset(0): No outputs definitely connected, trying again...
[    34.187] (II) modeset(0): Output HDMI-1 disconnected
[    34.187] (WW) modeset(0): Unable to find connected outputs - setting 1024x768 initial framebuffer
[    34.187] (==) modeset(0): Using gamma correction (1.0, 1.0, 1.0)
[    34.187] (==) modeset(0): DPI set to (96, 96)
[    34.187] (II) Loading sub module "fb"
[    34.187] (II) LoadModule: "fb"
[    34.194] (II) Loading /usr/lib/xorg/modules/libfb.so
[    34.201] (II) Module fb: vendor="X.Org Foundation"
[    34.201] 	compiled for 1.20.8, module version = 1.0.0
[    34.201] 	ABI class: X.Org ANSI C Emulation, version 0.4
[    34.223] (==) modeset(0): Backing store enabled
[    34.223] (==) modeset(0): Silken mouse enabled
[    34.231] (II) modeset(0): Initializing kms color map for depth 24, 8 bpc.
[    34.232] (==) modeset(0): DPMS enabled
[    34.232] (II) Initializing extension Generic Event Extension
[    34.232] (II) Initializing extension SHAPE
[    34.233] (II) Initializing extension MIT-SHM
[    34.234] (II) Initializing extension XInputExtension
[    34.237] (II) Initializing extension XTEST
[    34.238] (II) Initializing extension BIG-REQUESTS
[    34.239] (II) Initializing extension SYNC
[    34.239] (II) Initializing extension XKEYBOARD
[    34.240] (II) Initializing extension XC-MISC
[    34.240] (II) Initializing extension SECURITY
[    34.241] (II) Initializing extension XFIXES
[    34.242] (II) Initializing extension RENDER
[    34.242] (II) Initializing extension RANDR
[    34.243] (II) Initializing extension COMPOSITE
[    34.244] (II) Initializing extension DAMAGE
[    34.245] (II) Initializing extension MIT-SCREEN-SAVER
[    34.246] (II) Initializing extension DOUBLE-BUFFER
[    34.246] (II) Initializing extension RECORD
[    34.247] (II) Initializing extension DPMS
[    34.247] (II) Initializing extension Present
[    34.248] (II) Initializing extension DRI3
[    34.248] (II) Initializing extension X-Resource
[    34.248] (II) Initializing extension XVideo
[    34.249] (II) Initializing extension XVideo-MotionCompensation
[    34.249] (II) Initializing extension SELinux
[    34.249] (II) SELinux: Disabled on system
[    34.249] (II) Initializing extension GLX
[    34.250] (II) AIGLX: Screen 0 is not DRI2 capable
[    37.380] (II) IGLX: Loaded and initialized swrast
[    37.380] (II) GLX: Initialized DRISWRAST GL provider for screen 0
[    37.380] (II) Initializing extension XFree86-VidModeExtension
[    37.381] (II) Initializing extension XFree86-DGA
[    37.381] (II) Initializing extension XFree86-DRI
[    37.390] (II) Initializing extension DRI2
[    37.391] (II) modeset(0): Damage tracking initialized
[    37.638] (II) config/udev: Adding input device adc-keys (/dev/input/event1)
[    37.638] (**) adc-keys: Applying InputClass "libinput keyboard catchall"
[    37.638] (II) LoadModule: "libinput"
[    37.638] (II) Loading /usr/lib/xorg/modules/input/libinput_drv.so
[    37.666] (II) Module libinput: vendor="X.Org Foundation"
[    37.666] 	compiled for 1.20.4, module version = 0.29.0
[    37.666] 	Module class: X.Org XInput Driver
[    37.666] 	ABI class: X.Org XInput driver, version 24.1
[    37.666] (II) Using input driver 'libinput' for 'adc-keys'
[    37.671] (II) systemd-logind: got fd for /dev/input/event1 13:65 fd 22 paused 0
[    37.671] (**) adc-keys: always reports core events
[    37.671] (**) Option "Device" "/dev/input/event1"
[    37.671] (**) Option "_source" "server/udev"
[    37.695] (II) event1  - adc-keys: is tagged by udev as: Keyboard
[    37.695] (II) event1  - adc-keys: device is a keyboard
[    37.696] (II) event1  - adc-keys: device removed
[    37.696] (**) Option "config_info" "udev:/sys/devices/platform/adc-keys/input/input1/event1"
[    37.696] (II) XINPUT: Adding extended input device "adc-keys" (type: KEYBOARD, id 6)
[    37.696] (**) Option "xkb_model" "pc105"
[    37.696] (**) Option "xkb_layout" "us"
[    37.700] (II) event1  - adc-keys: is tagged by udev as: Keyboard
[    37.700] (II) event1  - adc-keys: device is a keyboard
[    37.703] (II) config/udev: Adding input device gpio-keys (/dev/input/event0)
[    37.703] (**) gpio-keys: Applying InputClass "libinput keyboard catchall"
[    37.703] (II) Using input driver 'libinput' for 'gpio-keys'
[    37.707] (II) systemd-logind: got fd for /dev/input/event0 13:64 fd 25 paused 0
[    37.708] (**) gpio-keys: always reports core events
[    37.708] (**) Option "Device" "/dev/input/event0"
[    37.708] (**) Option "_source" "server/udev"
[    37.711] (II) event0  - gpio-keys: is tagged by udev as: Keyboard
[    37.711] (II) event0  - gpio-keys: device is a keyboard
[    37.711] (II) event0  - gpio-keys: device removed
[    37.711] (**) Option "config_info" "udev:/sys/devices/platform/gpio-keys/input/input0/event0"
[    37.711] (II) XINPUT: Adding extended input device "gpio-keys" (type: KEYBOARD, id 7)
[    37.711] (**) Option "xkb_model" "pc105"
[    37.711] (**) Option "xkb_layout" "us"
[    37.715] (II) event0  - gpio-keys: is tagged by udev as: Keyboard
[    37.715] (II) event0  - gpio-keys: device is a keyboard

 

Share this post


Link to post
Share on other sites
On 1/10/2019 at 2:38 PM, JMCC said:

You need a fresh Armbian Bionic desktop image with legacy kernel installed.

 

31 minutes ago, whitefox said:

Welcome to Armbian Focal with Linux 5.7.0-rc2-arm-64 No end-user support: built from trunk & unsupported (focal) userspace!

 

Share this post


Link to post
Share on other sites
4 hours ago, NicoD said:

I don't want an legacy kernel.

I fund comment https://github.com/rockchip-linux/ffmpeg/issues/5#issuecomment-526955549
and build first mpp


git clone https://github.com/hizukiayaka/rockchip_mpp.git
cd ../mpp/
cmake -DRKPLATFORM=ON -DHAVE_DRM=ON -DCMAKE_BUILD_TYPE=Release
make -j7
make install

then I build rockchip ffmpeg 4.2 from https://github.com/stweiz/ffmpeg/tree/rockchip-ffmpeg-stevog/release/4.2
 


apt-get build-dep ffmpeg
git clone https://github.com/stweiz/ffmpeg/tree/rockchip-ffmpeg-stevog/release/4.2
cd ffmpeg/
./configure --prefix=/usr --extra-version=1ubuntu0.1 --toolchain=hardened --libdir=/usr/lib/aarch64-linux-gnu --incdir=/usr/include/aarch64-linux-gnu --arch=arm64 --enable-gpl --disable-stripping --enable-avresample --disable-filter=resample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librsvg --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-shared --enable-rkmpp --enable-version3
make -j7
make install

 

I want to do it humanly use ppa repo

 

 

Share this post


Link to post
Share on other sites
53 minutes ago, whitefox said:

 

OK, you are free to do whatever you want. But this is a thread about using my media script with Armbian legacy kernel. If you want to do something different, please don't discuss it here.

Share this post


Link to post
Share on other sites
2 hours ago, whitefox said:

I don't want an legacy kernel.

 

1 hour ago, JMCC said:

please don't discuss it here.

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
12 12