On Thu, Jun 29, 2017 at 5:23 AM, wm4 <[email protected]> wrote:
> On Wed, 28 Jun 2017 18:11:02 -0400
> Vittorio Giovara <[email protected]> wrote:
>
>> Resampling or conversion to/from ambisonic audio are currently
>> unsupported features.
>>
>> Signed-off-by: Vittorio Giovara <[email protected]>
>> ---
>>  libavresample/utils.c | 8 ++++++++
>>  1 file changed, 8 insertions(+)
>>
>> diff --git a/libavresample/utils.c b/libavresample/utils.c
>> index 15c827efbe..af2b9dbf2d 100644
>> --- a/libavresample/utils.c
>> +++ b/libavresample/utils.c
>> @@ -70,6 +70,14 @@ int avresample_open(AVAudioResampleContext *avr)
>>          av_channel_layout_default(&avr->out_ch_layout, 
>> avr->out_ch_layout.nb_channels);
>>      }
>>
>> +    if (( avr->in_ch_layout.order == AV_CHANNEL_ORDER_AMBISONIC ||
>> +         avr->out_ch_layout.order == AV_CHANNEL_ORDER_AMBISONIC) &&
>> +        av_channel_layout_compare(&avr->in_ch_layout, &avr->out_ch_layout)) 
>> {
>> +        av_log(avr, AV_LOG_ERROR,
>> +               "Resampling to/from ambisonic channel layouts is not 
>> supported.\n");
>> +        return AVERROR(ENOSYS);
>> +    }
>> +
>>      /* set channel mixing parameters */
>>  #if FF_API_OLD_CHANNEL_LAYOUT
>>      if (avr->in_channel_layout) {
>
> Did it error out in all cases before this patch? It shouldn't use a
> blacklist for unknown channel orders, but a whitelist for supported
> ones.

In the past it used to support up any layout up to 62 channels, but it
never errored out.
I will change it to use a whitelist for only NATIVE and UNSPEC orders,
in the first lavr patch, and modify this one to only allow
passthrough.
-- 
Vittorio
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to