Skip to content

[FR]: V4L2 codec support for ARM devices #210

@Halhadus

Description

@Halhadus

Description

Enabling V4L2 codecs for modern ARM devices

Who's implementing?

  • I'm willing to implement this feature myself

The problem

Most (perhaps all) ARM devices do not support the default hardware-accelerated video decoding options

Possible solutions

Enabling the V4L2 codec option, now a standard for ARM devices, would resolve this issue.
For reference, the Debian Chromium team already enables the V4L2 codec options in their build rules to support this standard:
https://salsa.debian.org/chromium-team/chromium/-/blob/master/debian/rules?ref_type=heads#L91-L96
I am currently using this method on my Orange Pi 5 Plus without any issues. Specifically for my device, I can seamlessly use AV1, H264, and HEVC options thanks to the "Rockchip upstream enablement efforts" Linux kernel developed by Collabora.

Additional context

I can't take screenshots due to a problem with Mesa, but I can share data as text:
{ "properties": { "render_id": 159, "player_id": 0, "created": "2026-03-07 21:22:29.290286 UTC", "origin_url": "", "kFrameUrl": "", "kFrameTitle": "BİLEMEDİM Kİ - YouTube", "url": "", "info": "Selected V4L2VideoDecoder for video decoding, config: codec: h264, profile: h264 high, level: 42, alpha_mode: is_opaque, coded size: [1920,1080], visible rect: [0,0,1920,1080], natural size: [1920,1080], has extra data: false, encryption scheme: Unencrypted, rotation: 0°, flipped: 0, color space: {primaries:BT709, transfer:BT709, matrix:BT709, range:LIMITED}", "kRendererName": "RendererImpl", "pipeline_state": "kPlaying", "kVideoTracks": [ { "alpha mode": "is_opaque", "codec": "h264", "coded size": "1920x1080", "color space": { "matrix": "BT709", "primaries": "BT709", "range": "LIMITED", "transfer": "BT709" }, "encryption scheme": "Unencrypted", "has extra data": false, "hdr metadata": {}, "natural size": "1920x1080", "orientation": "0°", "profile": "h264 high", "visible rect": "0,0 1920x1080" } ], "kAudioTracks": [ { "bytes per channel": 4, "bytes per frame": 8, "channel layout": "STEREO", "channels": 2, "codec": "opus", "codec delay": 312, "discard decoder delay": true, "encryption scheme": "Unencrypted", "has extra data": true, "profile": "unknown", "sample format": "Float 32-bit", "samples per second": 48000, "seek preroll": "80000us" } ], "kIsAudioDecryptingDemuxerStream": false, "kAudioDecoderName": "FFmpegAudioDecoder", "kIsPlatformAudioDecoder": false, "kIsVideoDecryptingDemuxerStream": false, "kVideoDecoderName": "V4L2VideoDecoder", "kIsPlatformVideoDecoder": true, "duration": 646.261, "audio_buffering_state": { "state": "BUFFERING_HAVE_ENOUGH" }, "event": "kPlay", "dimensions": "1920x1080", "kResolution": "1920x1080", "video_buffering_state": { "state": "BUFFERING_HAVE_ENOUGH" }, "pipeline_buffering_state": { "for_suspended_start": false, "state": "BUFFERING_HAVE_ENOUGH" } }, "events": [ { "time": 0, "key": "created", "value": "2026-03-07 21:22:29.290286 UTC" }, { "time": 6.388000000268221, "key": "origin_url", "value": "" }, { "time": 6.400000000372529, "key": "kFrameUrl", "value": "" }, { "time": 6.411000000312924, "key": "kFrameTitle", "value": "BİLEMEDİM Kİ - YouTube" }, { "time": 6.603000000119209, "key": "url", "value": "" }, { "time": 6.6650000009685755, "key": "info", "value": "ChunkDemuxer" }, { "time": 6.687000000849366, "key": "kRendererName", "value": "RendererImpl" }, { "time": 6.728000000119209, "key": "pipeline_state", "value": "kStarting" }, { "time": 928.5950000006706, "key": "kVideoTracks", "value": [ { "alpha mode": "is_opaque", "codec": "h264", "coded size": "1920x1080", "color space": { "matrix": "BT709", "primaries": "BT709", "range": "LIMITED", "transfer": "BT709" }, "encryption scheme": "Unencrypted", "has extra data": false, "hdr metadata": {}, "natural size": "1920x1080", "orientation": "0°", "profile": "h264 high", "visible rect": "0,0 1920x1080" } ] }, { "time": 928.7039999999106, "key": "kAudioTracks", "value": [ { "bytes per channel": 4, "bytes per frame": 8, "channel layout": "STEREO", "channels": 2, "codec": "opus", "codec delay": 312, "discard decoder delay": true, "encryption scheme": "Unencrypted", "has extra data": true, "profile": "unknown", "sample format": "Float 32-bit", "samples per second": 48000, "seek preroll": "80000us" } ] }, { "time": 934.0409999992698, "key": "kIsAudioDecryptingDemuxerStream", "value": false }, { "time": 934.0520000010729, "key": "kAudioDecoderName", "value": "FFmpegAudioDecoder" }, { "time": 934.0570000000298, "key": "kIsPlatformAudioDecoder", "value": false }, { "time": 934.1349999997765, "key": "info", "value": "Selected FFmpegAudioDecoder for audio decoding, config: codec: opus, profile: unknown, bytes_per_channel: 4, channel_layout: STEREO, channels: 2, samples_per_second: 48000, sample_format: Float 32-bit, bytes_per_frame: 8, seek_preroll: 80000us, codec_delay: 312, has extra data: true, encryption scheme: Unencrypted, discard decoder delay: true, target_output_channel_layout: STEREO, target_output_sample_format: Unknown sample format" }, { "time": 934.410000000149, "key": "info", "value": "Cannot select DecryptingVideoDecoder for video decoding" }, { "time": 964.0030000004917, "key": "info", "value": "Effective playback rate changed from 0 to 1" }, { "time": 990.2740000002086, "key": "info", "value": "VideoDecoderPipeline |decoder_| Initialize() successful" }, { "time": 990.695000000298, "key": "kIsVideoDecryptingDemuxerStream", "value": false }, { "time": 990.6990000009537, "key": "kVideoDecoderName", "value": "V4L2VideoDecoder" }, { "time": 990.7009999994189, "key": "kIsPlatformVideoDecoder", "value": true }, { "time": 990.7369999997318, "key": "info", "value": "Selected V4L2VideoDecoder for video decoding, config: codec: h264, profile: h264 high, level: 42, alpha_mode: is_opaque, coded size: [1920,1080], visible rect: [0,0,1920,1080], natural size: [1920,1080], has extra data: false, encryption scheme: Unencrypted, rotation: 0°, flipped: 0, color space: {primaries:BT709, transfer:BT709, matrix:BT709, range:LIMITED}" }, { "time": 990.7709999997169, "key": "pipeline_state", "value": "kPlaying" }, { "time": 79.44900000095367, "key": "duration", "value": 646.261 }, { "time": 1180.1459999997169, "key": "audio_buffering_state", "value": { "state": "BUFFERING_HAVE_ENOUGH" } }, { "time": 964.2039999999106, "key": "event", "value": "kPlay" }, { "time": 1234.7939999997616, "key": "dimensions", "value": "1920x1080" }, { "time": 1234.801000000909, "key": "kResolution", "value": "1920x1080" }, { "time": 1217.1349999997765, "key": "video_buffering_state", "value": { "state": "BUFFERING_HAVE_ENOUGH" } }, { "time": 1234.8570000007749, "key": "pipeline_buffering_state", "value": { "for_suspended_start": false, "state": "BUFFERING_HAVE_ENOUGH" } }, { "time": 3519.1349999997765, "key": "video_buffering_state", "value": { "state": "BUFFERING_HAVE_ENOUGH" } } ] }

Metadata

Metadata

Assignees

No one assigned

    Labels

    featFeature requestpendingMaintainers have not discussed this yet

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions