Adds support for encoding to adpcm_ima_amv and muxing to AMV. Things to note: - AMV is a hard-coded (and broken) subset of AVI. It's not worth sullying the existing AVI muxer with its filth. - The muxer is extremely pedantic about its streams, this is to not break certain software players. - The sizes of certain tags are deliberately set to 0 as some players break when they're set correctly. Ditto with some header fields. - Players can be **very** sensitive to the frame order and sizes. - Frames must be strictly interleaved as V-A, any V-V or A-A will cause crashes. - Variable audio frame sizes cause crashes. - If audio is shorter than video, it's padded with silence. - If video is shorter than audio, the most recent frame is repeated.
v4: - Always use the coded sample count if its a sensible value - Fix decoder odd sample check v3: [2] - Use ffio_fill() v2: [1] - Unref allocated audio frame - Check return value of av_packet_ref() - Remove unnecessary initialisations - Add deinit() function [1]: https://ffmpeg.org/pipermail/ffmpeg-devel/2020-November/271837.html [2]: https://ffmpeg.org/pipermail/ffmpeg-devel/2020-November/271882.html Zane van Iperen (5): avcodec/adpcm_ima_amv: restrict to 1 channel avcodec/adpcm_ima_amv: use coded sample count avcodec/adpcm_ima_amv: document header format avcodec: add adpcm_ima_amv encoder avformat: add amv muxer MAINTAINERS | 1 + doc/general_contents.texi | 2 +- libavcodec/adpcm.c | 34 ++- libavcodec/adpcmenc.c | 58 ++++- libavcodec/allcodecs.c | 1 + libavcodec/utils.c | 3 +- libavformat/Makefile | 1 + libavformat/allformats.c | 1 + libavformat/amvenc.c | 413 +++++++++++++++++++++++++++++++++++ tests/ref/fate/adpcm-ima-amv | 312 +++++++++++++------------- 10 files changed, 665 insertions(+), 161 deletions(-) create mode 100644 libavformat/amvenc.c -- 2.28.0 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".