PINE64
kodi-git build script for mainline hwaccel media decoding - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: Pinebook Pro (https://forum.pine64.org/forumdisplay.php?fid=111)
+--- Forum: Linux on Pinebook Pro (https://forum.pine64.org/forumdisplay.php?fid=114)
+--- Thread: kodi-git build script for mainline hwaccel media decoding (/showthread.php?tid=9877)

Pages: 1 2 3


RE: kodi-git build script for mainline hwaccel media decoding - xmixahlx - 06-14-2020

you probably need to add your user to the input group.: sudo adduser <user> input


RE: kodi-git build script for mainline hwaccel media decoding - Odel - 06-15-2020

(06-14-2020, 07:47 PM)xmixahlx Wrote: you probably need to add your user to the input group.: sudo adduser <user> input
Yep that was the trick! I actually found that on some Kodi thread somewhere

Now video playback fails to work, there's no content and it just gives me a nice cursor trail instead Big Grin

The kodi.log is getting spammed with:
CDVDVideoCodecDRMPRIME::GetFormat - unsupported pixel format
CDVDVideoCodecDRMPRIME::AddData - send packet failed: Invalid data found when processing input (-1094995529)

Not sure where I went wrong


RE: kodi-git build script for mainline hwaccel media decoding - xmixahlx - 06-15-2020

your build steps need to be linux > (mesa) > ffmpeg > (libudfread) > kodi, with (package) being optional, but recommended. is that what you did?


RE: kodi-git build script for mainline hwaccel media decoding - Odel - 06-15-2020

(06-15-2020, 11:35 AM)xmixahlx Wrote: your build steps need to be linux > (mesa) > ffmpeg > (libudfread) > kodi, with (package) being optional, but recommended. is that what you did?
Just tried building all these again in that order, getting the same result


RE: kodi-git build script for mainline hwaccel media decoding - xmixahlx - 06-15-2020

are you building mesa? do you have X/wayland running?
kill X/wayland
run: ffmpeg -re -hwaccel drm -hwaccel_device /dev/dri/card0 -i <VIDEOFILE> -pix_fmt bgra -report -t 1 -f fbdev /dev/fb0
upload the log here. it will be ffmpeg_date.log in the terminal directory.


RE: kodi-git build script for mainline hwaccel media decoding - xmixahlx - 06-15-2020

(06-13-2020, 09:28 AM)spikerguy Wrote: Hi @xmixahlx

I have added your vdec patch to `linux-pinebookpro` it built fine then I tried building ffmpeg full but it have too many extra libs enabled so I moved to ffmpeg with only v4l2_request and it was build just fine.

Now I am stuck with kodi-git I tried my PKGBuild with your config and it fails with errors then I think I will just run your script and it fails with missing deps and after I install those deps then it fails with missing packages which are not part of arch linux example `fstrcmp` and `libdvdread` errors.

Have you tried building using the kodi script on your pbp-tools repo? Can you add full dep list?

Thanks for your work.

@spikerguy

see CMakeLists.txt and note the -DENABLE_INTERNAL_?=OFF entries, and the ON entries under general. you may have to toggle those. also review required dependencies, and optional:
https://github.com/xbmc/xbmc/blob/master/CMakeLists.txt

from:
https://gitlab.manjaro.org/manjaro-arm/packages/community/kodi/-/blob/master/PKGBUILD
https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=kodi-git

try:
pacman -S afpfs-ng bluez-libs cmake curl doxygen glew gperf hicolor-icon-theme java-runtime libaacs libass libbluray libcdio libcec libgl mariadb-libs libmicrohttpd libmodplug libmpeg2 libnfs libplist libpulse libva libvdpau libxrandr libxslt lirc lzo mesa nasm python-pycryptodomex python-pillow python-pybluez python-simplejson shairplay smbclient taglib tinyxml swig upower giflib rapidjson ghostscript desktop-file-utils hicolor-icon-theme mesa python-pycryptodomex python-pillow python-simplejson xorg-xdpyinfo shairplay git meson gtest bluez-libs curl lcms2 libass libbluray libcdio libcec libinput libmicrohttpd libnfs libpulse libva libxkbcommon libxslt lirc mariadb-libs python smbclient taglib tinyxml libpng giflib libjpeg-turbo lzo afpfs-ng bluez python-pybluez libplist pulseaudio upower

cmake .. \
-DCORE_PLATFORM_NAME=gbm \
-DGBM_RENDER_SYSTEM=gles \
-DFFMPEG_PATH=/usr/local \
-DENABLE_TESTING=OFF \
-DCMAKE_INSTALL_LIBDIR=/usr/local/lib/aarch64-linux-gnu \
-DENABLE_INTERNAL_FFMPEG=OFF \
-DENABLE_INTERNAL_FMT=ON \
-DENABLE_INTERNAL_CROSSGUID=ON \
-DENABLE_INTERNAL_FSTRCMP=ON \
-DENABLE_INTERNAL_FLATBUFFERS=ON \
-DENABLE_INTERNAL_SPDLOG=ON

you may need to pair these down. when you get something that works, LMK.


RE: kodi-git build script for mainline hwaccel media decoding - Odel - 06-15-2020

(06-15-2020, 04:34 PM)xmixahlx Wrote: are you building mesa? do you have X/wayland running?
kill X/wayland
run: ffmpeg -re -hwaccel drm -hwaccel_device /dev/dri/card0 -i <VIDEOFILE> -pix_fmt bgra -report -t 1 -f fbdev /dev/fb0
upload the log here. it will be ffmpeg_date.log in the terminal directory.
Yes I'm building mesa (KDE works great with it) and yes I'm trying to run kodi without x/wayland running at the time

That test seems to work fine, I tried clearing my .kodi directory too but I'm really at a loss here


.log   ffmpeg-20200615-225201.log (Size: 44.61 KB / Downloads: 379)


RE: kodi-git build script for mainline hwaccel media decoding - xmixahlx - 06-16-2020

i updated the ffmpeg and kodi scripts. hopefully that solves both of your issues.

unclear why i don't see the same problems, but we'll figure it out.

@spikerguy try BUILDCONFIG=internal ./pbp-build-kodi

there is a change in installdirs:
manually delete the old ffmpeg includes in /usr/local/include/aarch64-linux-gnu
manually delete kodi libs in /usr/local/lib, i moved them to /usr/local/lib/aarch64-linux-gnu


RE: kodi-git build script for mainline hwaccel media decoding - Odel - 06-16-2020

(06-16-2020, 02:23 AM)xmixahlx Wrote: i updated the ffmpeg and kodi scripts. hopefully that solves both of your issues.

unclear why i don't see the same problems, but we'll figure it out.

My latest build is working now, great work!
1080p H.264 and H.265 (even 10 bit!) are both working well

Now hopefully some day the userspace apis will get figured out and we can run MPV on x/wayland but this is more than good enough for now


RE: kodi-git build script for mainline hwaccel media decoding - xmixahlx - 06-16-2020

excellent. i've been pleased with kodi + inputstream.adaptive + youtube + jellyfin for most of my media. there is some new progress with gstreamer that i am following that looks promising. more to come.