I have been trying to use these two to achieve hard decoding:https://linux-sunxi.org/Sunxi-Cedrus and https://linux-sunxi.org/Cedrus /libvdpau-sunxi .
libva-v4l2-request I used someone else's version because it was a lower version: https://github.com/kwizart/libva-v4l2-request/tree/HACK_HEVC
It can be compiled and installed successfully under the 6.6 kernel
libva info: VA-API version 1.17.0
libva info: User environment variable requested driver 'v4l2_request'
libva info: Trying to open /usr/lib/aarch64-linux-gnu/dri/v4l2_request_drv_video.so
libva info: Found init function __vaDriverInit_1_17
libva info: va_openDriver() returns 0
vainfo: VA-API version: 1.17 (libva 2.12.0)
vainfo: Driver version: v4l2-request
vainfo: Supported profile and entrypoints
VAProfileMPEG2Simple : VAEntrypointVLD
VAProfileMPEG2Main : VAEntrypointVLD
VAProfileH264Main : VAEntrypointVLD
VAProfileH264High : VAEntrypointVLD
VAProfileH264ConstrainedBaseline: VAEntrypointVLD
VAProfileH264MultiviewHigh : VAEntrypointVLD
VAProfileH264StereoHigh : VAEntrypointVLD
VAProfileHEVCMain : VAEntrypointVLD
Unfortunately, when I use vaapi, the kernel crashes,command:mpv -v --hwdec=vaapi
The libvdpau-sunxi project compiles without modification, but some devices are no longer used in kernel 6.6
command:mpv -v --hwdec=vdpau
There was no crash using vdpau, but as I said, the lack of a corresponding device caused it to become unusable and switch to soft decoding
mpv -v --hwdec=vdpau IAmLegend-Trailer.mp4
[cplayer] Command line options: '-v' '--hwdec=vdpau' 'IAmLegend-Trailer.mp4'
[cplayer] mpv 0.35.1 Copyright © 2000-2023 mpv/MPlayer/mplayer2 projects
[cplayer] built on UNKNOWN
[cplayer] FFmpeg library versions:
[cplayer] libavutil 57.28.100
[cplayer] libavcodec 59.37.100
[cplayer] libavformat 59.27.100
[cplayer] libswscale 6.7.100
[cplayer] libavfilter 8.44.100
[cplayer] libswresample 4.7.100
[cplayer] FFmpeg version: 5.1.4-0+deb12u1
[cplayer]
[cplayer] Configuration: meson configure build -Dprefix=/usr -Dbuildtype=plain -Doptimization=plain
[cplayer] List of enabled features: alsa av-channel-layout caca cdda cplayer cplugins cuda-hwaccel cuda-interop dmabuf-interop-gl dmabuf-interop-pl dmabuf-wayland drm drm-is-kms dvbin dvdnav egl egl-drm egl-helpers egl-x11 ffmpeg ffnvcodec gbm gl gl-wayland glibc-thread-name glob glob-posix gpl iconv jack javascript jpeg jpegxl lcms2 libarchive libass libavdevice libbluray libdl libm libmpv-shared libplacebo libplacebo-next librt linux-fstatfs lua52 manpage-build memfd_create noexecstack pipewire plain-gl posix pulse rubberband rubberband-3 sdl2 sdl2-audio sdl2-gamepad sdl2-video sixel spirv-cross stdatomic threads uchardet vaapi vaapi-drm vaapi-egl vaapi-libplacebo vaapi-wayland vaapi-x-egl vaapi-x11 vdpau vector vt.h vulkan wayland wayland_protocols_1_24 x11 xv zimg zlib
[cplayer] Reading config file /etc/mpv/encoding-profiles.conf
[cplayer] Applying profile 'default'...
[cplayer] Setting option 'v' = '' (flags = 8)
[cplayer] Setting option 'hwdec' = 'vdpau' (flags = 8)
[cplayer] Waiting for scripts...
[osd/libass] libass API version: 0x1701000
[osd/libass] libass source: tarball: 0.17.1
[osd/libass] Shaper: FriBidi 1.0.8 (SIMPLE) HarfBuzz-ng 6.0.0 (COMPLEX)
[osd/libass] Setting up fonts...
[osd/libass] Using font provider fontconfig
[osd/libass] Done.
[cplayer] Set property: shared-script-properties -> 1
[cplayer] Set property: shared-script-properties -> 1
[cplayer] Done loading scripts.
[cplayer] Running hook: ytdl_hook/on_load
[ytdl_hook] ytdl:// hook
[ytdl_hook] not a ytdl:// url
[ifo_dvdnav] Opening IAmLegend-Trailer.mp4
[bdmv/bluray] Opening IAmLegend-Trailer.mp4
[file] Opening IAmLegend-Trailer.mp4
[demux] Trying demuxers for level=normal.
[cplayer] Set property: shared-script-properties -> 1
[osd/libass] libass API version: 0x1701000
[osd/libass] libass source: tarball: 0.17.1
[osd/libass] Shaper: FriBidi 1.0.8 (SIMPLE) HarfBuzz-ng 6.0.0 (COMPLEX)
[osd/libass] Setting up fonts...
[osd/libass] Using font provider fontconfig
[osd/libass] Done.
[cplayer] Set property: shared-script-properties -> 1
[cplayer] Set property: shared-script-properties -> 1
[lavf] Found 'mov,mp4,m4a,3gp,3g2,mj2' at score=100 size=2048.
[file] stream level seek from 131072 to 126886094
[demux] Detected file format: mov,mp4,m4a,3gp,3g2,mj2 (libavformat)
[cplayer] Opening done: IAmLegend-Trailer.mp4
[find_files] Loading external files in .
[cplayer] Running hook: ytdl_hook/on_preloaded
[lavf] select track 0
[lavf] select track 1
[cplayer] (+) Video --vid=1 (*) (h264 1920x816 23.976fps)
[cplayer] (+) Audio --aid=1 (*) (aac 6ch 48000Hz)
[vo/gpu] Probing for best GPU context.
[vo/gpu/opengl] Initializing GPU context 'wayland'
[vo/gpu/opengl] Initializing GPU context 'x11egl'
[vo/gpu/x11] X11 opening display: :0.0
[vo/gpu/x11] Display 0 (HDMI-1): [0, 0, 1920, 1080] @ 60.000000 FPS
[vo/gpu/x11] Current display FPS: 60.000000
[vo/gpu/opengl] EGL_VERSION=1.4
[vo/gpu/opengl] EGL_VENDOR=Mesa Project
[vo/gpu/opengl] EGL_CLIENT_APIS=OpenGL OpenGL_ES
[vo/gpu/opengl] Trying to create Desktop OpenGL context.
[vo/gpu/opengl] Choosing visual EGL config 0x9, visual ID 0x21
[vo/gpu/x11] The XPresent extension was found.
[vo/gpu/x11] XPresent disabled.
[vo/gpu/opengl] GL_VERSION='3.1 Mesa 22.3.6'
[vo/gpu/opengl] Detected desktop OpenGL 3.1.
[vo/gpu/opengl] GL_VENDOR='Panfrost'
[vo/gpu/opengl] GL_RENDERER='Mali-G31 (Panfrost)'
[vo/gpu/opengl] GL_SHADING_LANGUAGE_VERSION='1.40'
[vo/gpu/opengl] Loaded extension GL_ARB_sync.
[vo/gpu/opengl] Loaded extension GL_ARB_invalidate_subdata.
[vo/gpu/opengl] Loaded extension GL_ARB_get_program_binary.
[vo/gpu/opengl] Loaded extension GL_ARB_buffer_storage.
[vo/gpu/opengl] Loaded extension GL_ARB_shader_image_load_store.
[vo/gpu/opengl] Loaded extension GL_ARB_shader_storage_buffer_object.
[vo/gpu/opengl] Loaded extension GL_ARB_arrays_of_arrays.
[vo/gpu/opengl] Loaded extension GL_ARB_debug_output.
[vo/gpu/opengl] Loaded extension GL_KHR_debug.
[vo/gpu] Testing FBO format rgba16f
[vo/gpu] Using FBO format rgba16f.
[vo/gpu] Disabling HDR peak computation (one or more of the following is not supported: compute shaders=0, SSBO=1).
[vo/gpu] No advanced processing required. Enabling dumb mode.
[vo/gpu] Assuming 60.000000 FPS for display sync.
[vd] Container reported FPS: 23.975986
[vd] Codec list:
[vd] h264 - H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
[vd] h264_v4l2m2m (h264) - V4L2 mem2mem H.264 decoder wrapper
[vd] h264_cuvid (h264) - Nvidia CUVID H264 decoder
[vd] Opening decoder h264
[vd] Looking at hwdec h264-vdpau...
[vo/gpu] Loading hwdec drivers for format: 'vdpau'
[vd] Could not create device.
[vd] No hardware decoding available for this codec.
[vd] Using software decoding.
[vd] Detected 4 logical cores.
[vd] Requesting 5 threads for decoding.
[vd] Selected codec: h264 (H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10)
[vf] User filter list:
[vf] (empty)
[ad] Codec list:
[ad] aac - AAC (Advanced Audio Coding)
[ad] aac_fixed (aac) - AAC (Advanced Audio Coding)
[ad] Opening decoder aac
[ad] Requesting 1 threads for decoding.
[ad] Selected codec: aac (AAC (Advanced Audio Coding))
[af] User filter list:
[af] (empty)
[cplayer] Starting playback...
[file] stream level seek from 126886145 to 57472
[vd] DR failed - disabling.
[vd] Using software decoding.
[vd] Decoder format: 1920x816 yuv420p auto/auto/auto/auto/auto CL=mpeg2/4/h264
[vf] [in] 1920x816 yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264
[vf] [userdeint] 1920x816 yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264
[vf] [userdeint] (disabled)
[vf] [autorotate] 1920x816 yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264
[vf] [autorotate] (disabled)
[vf] [convert] 1920x816 yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264
[vf] [convert] (disabled)
[vf] [out] 1920x816 yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264
[af] [in] 48000Hz 5.1 6ch floatp
[af] [userspeed] 48000Hz 5.1 6ch floatp
[af] [userspeed] (disabled)
[af] [convert] 48000Hz 5.1 6ch floatp
[ao] Trying audio driver 'pipewire'
[ao/pipewire] requested format: 48000 Hz, 5.1 channels, floatp
[ao/pipewire] Headers version: 0.3.65
[ao/pipewire] Library version: 0.3.65
[W][09924.973570] pw.conf | [ conf.c: 939 try_load_conf()] can't load config client.conf: No such file or directory
[E][09924.973889] pw.conf | [ conf.c: 963 pw_conf_load_conf_for_context()] can't load default config client.conf: No such file or directory
[ao] Trying audio driver 'pulse'
[ao/pulse] requested format: 48000 Hz, 5.1 channels, floatp
[ao/pulse] Library version: 16.1.0
[ao/pulse] Proto: 35
[ao/pulse] Server proto: 4294967295
[ao/pulse] Channel layouts:
[ao/pulse] - #fl
[ao/pulse] - #fr
[ao/pulse] - #fc
[ao/pulse] - #lfe
[ao/pulse] - #bl
[ao/pulse] - #br
[ao/pulse] - #flc
[ao/pulse] - #frc
[ao/pulse] - #bc
[ao/pulse] - #sl
[ao/pulse] - #sr
[ao/pulse] - #tc
[ao/pulse] - #tfl
[ao/pulse] - #tfc
[ao/pulse] - #tfr
[ao/pulse] - #tbl
[ao/pulse] - #tbc
[ao/pulse] - #tbr
[ao/pulse] result: 5.1
[ao/pulse] device buffer: 6718 samples.
[ao/pulse] using soft-buffer of 9600 samples.
[cplayer] AO: [pulse] 48000Hz 5.1 6ch float
[cplayer] AO: Description: PulseAudio audio output
[autoconvert] inserting resampler
[swresample] format change, reinitializing resampler
[swresample] 48000Hz 5.1 floatp -> 48000Hz 5.1 float
[af] [out] 48000Hz 5.1 6ch float
[cplayer] VO: [gpu] 1920x816 yuv420p
[cplayer] VO: Description: Shader-based GPU Renderer
[vo/gpu] DR path suspected slow/uncached, disabling..reconfig to 1920x816 yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264
[vo/gpu] Resize: 1920x816
[vo/gpu] Window size: 1920x816 (Borders: l=0 t=0 r=0 b=0)
[vo/gpu] Video source: 1920x816 (1:1)
[vo/gpu] Video display: (0, 0) 1920x816 -> (0, 0) 1920x816
[vo/gpu] Video scale: 1.000000/1.000000
[vo/gpu] OSD borders: l=0 t=0 r=0 b=0
[vo/gpu] Video borders: l=0 t=0 r=0 b=0
[vo/gpu] Reported display depth: 8
[vo/gpu] Texture for plane 0: 1920x816
[vo/gpu] Texture for plane 1: 960x408
[vo/gpu] Texture for plane 2: 960x408
[vo/gpu] Testing FBO format rgba16f
[vo/gpu] Using FBO format rgba16f.
[vo/gpu] No advanced processing required. Enabling dumb mode.
[cplayer] first video frame after restart shown
[cplayer] audio ready
[cplayer] starting audio playback
[cplayer] playback restart complete @ 0.041708, audio=playing, video=playing
[vo/gpu/x11] Disabling screensaver.
[ao/pulse] starting AO
[statusline] AV: 00:00:00 / 00:02:03 (0%) A-V: 0.000
[cplayer] Set property: shared-script-properties -> 1
[cplayer] Set property: shared-script-properties -> 1
[statusline] AV: 00:00:06 / 00:02:03 (5%) A-V: 0.000
[cplayer] EOF code: 5
[cplayer] finished playback, success (reason 3)
[cplayer]
[cplayer] Exiting... (Quit)
[cplayer] Set property: shared-script-properties -> 1
[vo/gpu/x11] Enabling screensaver.
That's all I've ever known and tried