Repository navigation
Fix AMF hwcontext transfer format selection - #8280
Open
Hotactioncop wants to merge 1 commit into
Open
Hotactioncop wants to merge 1 commit into
Hotactioncop wants to merge 1 commit into
Conversation
2 of 7 tasks
Hotactioncop
force-pushed
the
amf_dec_fix_transfer_format_selection
branch
from
November 20, 2026 15:44
e7341cf to
5cf63fe
Compare
Hotactioncop
marked this pull request as draft
November 20, 2026 15:45
Hotactioncop
marked this pull request as ready for review
November 20, 2026 15:45
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of Change
Add a contrib/ffmpeg patch to fix AMF transfer format selection.
Previously, the AMF backend returned its full list of supported transfer formats.
FFmpeg selected the first entry, NV12, even when downloading a P010 surface.
The AMF transfer handler rejected this mismatch with EINVAL, causing HDR10+ preview generation to fail in HandBrake.
Return only the frames context's software pixel format, matching the AMF approach.
Return ENOSYS if that format is not supported for transfers.
Github Issue
AMF Decode - "error transferring data to system memory" #8265
AI Usage
Details:
I identified the root cause through debugging.
AI helped compare existing FFmpeg hardware backends and applied a small change following the existing implementation.
Testing
Confirmed that the fix resolves the reported HDR10+ preview failure in HandBrake with AMF decoding.
Screenshots / Activity logs (If Relevant)