[opus] [PATCH] Support for Channel Mapping 253.

Jean-Marc Valin jmvalin at jmvalin.ca
Wed Nov 1 19:04:35 UTC 2017


>     8) I see there's a "gain" field in the matrix, but I can't see it used
>     anywhere. Did I miss something?
> 
> Gain should be pulled out by the user via
> a  OPUS_PROJECTION_GET_DEMIXING_MATRIX_GAIN call and add it to the
> overall output gain. We assume the mixing matrix gain is always zero and
> that this only matters for the output gain from the demixing matrix.

Yeah OK, I forgot about the feature. Just to make sure I remember
correctly... The (user) encoder code calls
OPUS_PROJECTION_GET_DEMIXING_MATRIX_GAIN() and uses the result to fill
the "gain" field of the header, right?

>     11) So one issue I just noticed is that opus_projection_encode() and
>     opus_projection_encode_float() (same for the decoder) use arbitrarily
>     large amounts of stack memory for "buf". In opus_multistream_encode()
>     that's avoided by converting just two channels at a time, but here it's
>     not quite clear how to do that without duplicating a lot of the
>     multistream code. If we can't address the issue with this patch, the
>     least would be to abort when trying to use these calls with
>     NONTHREADSAFE_PSEUDOSTACK
> 
> Done. Let me know if we should try designing something around this. 

Yes, I think that needs to be addressed. Since the feature isn't enabled
by default and this patch is already complicated enough, I think it
should be addressed in a separate patch. I'm not yet sure what the best
approach is. That'll require some thought.

I'm having another look at your revised patches and I'll get back to you.

Cheers,

	Jean-Marc



More information about the opus mailing list