[FFmpeg-devel] [PATCH] libopusenc: Add channel mapping family argument

Michael Graczyk mgraczyk at google.com
Tue Jun 21 00:48:43 CEST 2016


I have fixed the problems Mark pointed out and attached new patches.
I'll address Mark's comments inline.

> This implies that -mapping_family -1 (the default) is the same as some
> other -mapping_family 0..255, determined by the input, but it is not.

I updated the doc to explain these differences.

> This removes the restrictions on input channel layouts, allowing any
> channel layout to be accepted.

I added explicit checks in the new function
libopus_check_vorbis_layout for this.

> When channels <= 2, the mapping family will still be 0 even if -mapping_family 255 was explicitly specified.

Thanks, fixed.

> If there are more than 8 channels it appears that it will read beyond
the end of the array.  If the input does not have a family 1 layout
and mapping family 255 was specified, it will still remap the channels
as if they had a family 1 layout.

That's right, this was incorrect but now fixed. I only reorder the
channels when necessary and I explicitly check that the input channel
layout is the expected one.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-libopusenc-Refactor-to-simplify-forthcoming-mapping_.patch
Type: text/x-patch
Size: 6351 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20160620/200cae5c/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-libopusenc-Add-channel-mapping-family-argument.patch
Type: text/x-patch
Size: 12039 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20160620/200cae5c/attachment-0001.bin>

More information about the ffmpeg-devel mailing list