@termac from the mainline kernel thread
it's notable that ffmpeg currently doesn't list the v4l2request hwaccel decoders in runtime ((ffmpeg -decoders|grep v4l2), but does list v4l2request codecs as detected during build.
it's also notable that these patches handle drm hwaccel because that is what LibreElec uses for kodi.
kernel patch info:
Kwiboo's LibreElec Rockchip 5.6 patches and pull request:
https://github.com/Kwiboo/LibreELEC.tv/t...ux/default
https://github.com/LibreELEC/LibreELEC.tv/pull/4377
Kwiboo hevc kernel repo branch:
https://github.com/Kwiboo/linux-rockchip...ist-v5.6.6
https://github.com/Kwiboo/linux-rockchip...5.6.6-hevc
make a diff of these two above repositories (exclude=.git exclude=sunxi)
Kwiboo's ffmpeg branch supporting rkvdec:
https://github.com/Kwiboo/FFmpeg/tree/v4...2.2-rkvdec
build: ./configure --prefix=/usr/local --libdir=/usr/local/lib/aarch64-linux-gnu --shlibdir=/usr/local/lib/aarch64-linux-gnu --enable-shared --enable-pic --enable-v4l2-request --enable-libdrm --enable-libudev && make -j6 && sudo make install
pbp linux 5.7-rc5 hwaccel patch sequence:
tsys 5.7.0-rc2 branch
5.7.0-rc3 incremental patch
5.7.0-rc4 incremental patch
5.7.0-rc5 incremental patch
LibreElec 002, 0012, 0013, 0021, 0022, 1000 patches
Kwiboo hevc patch
Quote:... i tried my hands on getting hardware decoding working, for that I added the rkvdec kernel patches from https://patchwork.kernel.org/project/lin...ter=179601 and patched libva and libva-v4l2-request as per Your instructions in the other thread. vainfo still would only show support for MPEG2. At that point I did give up. So now it is either waiting for full mainline support or have enough time and motivation to figure out where I went wrong.vainfo will display a single media decoder module, and it defaults to /dev/video0 or whatever you have set as LIBVA_V4L2_REQUEST_VIDEO_PATH (see first few posts). since rk3399 has two (hantro and rkvdec) you need to select them with vainfo separately. with mpeg2 you are seeing hantro. check devices with v4l2-ctl --list-devices. check each device with v4l2-ctl -d /dev/video# --all.
it's notable that ffmpeg currently doesn't list the v4l2request hwaccel decoders in runtime ((ffmpeg -decoders|grep v4l2), but does list v4l2request codecs as detected during build.
it's also notable that these patches handle drm hwaccel because that is what LibreElec uses for kodi.
kernel patch info:
Kwiboo's LibreElec Rockchip 5.6 patches and pull request:
https://github.com/Kwiboo/LibreELEC.tv/t...ux/default
https://github.com/LibreELEC/LibreELEC.tv/pull/4377
Kwiboo hevc kernel repo branch:
https://github.com/Kwiboo/linux-rockchip...ist-v5.6.6
https://github.com/Kwiboo/linux-rockchip...5.6.6-hevc
make a diff of these two above repositories (exclude=.git exclude=sunxi)
Kwiboo's ffmpeg branch supporting rkvdec:
https://github.com/Kwiboo/FFmpeg/tree/v4...2.2-rkvdec
build: ./configure --prefix=/usr/local --libdir=/usr/local/lib/aarch64-linux-gnu --shlibdir=/usr/local/lib/aarch64-linux-gnu --enable-shared --enable-pic --enable-v4l2-request --enable-libdrm --enable-libudev && make -j6 && sudo make install
pbp linux 5.7-rc5 hwaccel patch sequence:
tsys 5.7.0-rc2 branch
5.7.0-rc3 incremental patch
5.7.0-rc4 incremental patch
5.7.0-rc5 incremental patch
LibreElec 002, 0012, 0013, 0021, 0022, 1000 patches
Kwiboo hevc patch