Support custom codec - #3383
Support custom codec#3383tongyuantongyu wants to merge 6 commits into
Conversation
|
@y-guyon I saw your PR #2381. I think allowing users to implement their own codec is better than adding callback. + @wantehchang @maryla-uc Asking if we want this feature. We probably need to refactor the codec interface to be forward-compatible and versioned, so I want to hear your opinion before working on this further. |
Could you describe what is better exactly? I agree it probably is more complete and powerful, but it also exposes more internal stuff in the public API. I am fine with both approaches, I just wonder if the work is worth it overall. Also maybe CrabbyAvif is a more future-looking location for such a feature. |
|
Expose codec interface in a new header
codec.hso custom codecs can be registered and used by libavif.I made this while building my own tool that performs batched hardware encoding using a long-living GPU encode session. At its best it may be added to
contrib/after some more polishing, but it's definitely too niche to be accepted as a built-in codec.This PR allows anyone to add another codec into libavif without hacking into the library code.