[asterisk-dev] Advanced Codec Negotiation: Asymmetric Codecs

George Joseph gjoseph at digium.com
Mon Jun 15 13:28:23 CDT 2020


On Mon, Jun 15, 2020 at 11:57 AM Joshua Elson <joshelson at gmail.com> wrote:

> So I am the one responsible for this situation, if I recall the discussion
> a few years back. We actually have had to support several phones - Yealink
> being the most distinctly memorable - that support asymmetric codecs on a
> single call leg, and from our reading, it's legal in the RFC. In some very
> high throughput cases, it was preferable to reduce overall transcoding use
> in our infrastructure when you did the math on having a few thousand of
> these phones in the same situation.
>
>
So if we send an offer to Bob (who has one of the phones in question) with
g722, ulaw, alaw in that order, would Bob respond with an answer in the
same order but then start sending ulaw for instance?  Or would Bob send an
answer with uaw, g722, alaw?   The reason I ask is that if they respond
with g722, ulaw, alaw, then we'll probably also send that back in the
answer to Alice. If Bob subsequently starts sending ulaw, we _may_ (I have
to check) simply pass that through to Alice since ulaw was in the final
topology but Alice's phone might not be prepared to receive media in a
format other than the first in the answer.  This seems to be common,
especially if the phone uses the pjproject SIP stack.

Other things to consider...
Does Alice's asymmetric_codecs setting apply?
If transcode is "no" would we have to trigger a topology change and do
re-INVITES?   This could get ugly.
If transcode is "yes" but Alice's asymmetric_codecs is "no" do we transcode
in the 1 direction only?

How does this fit with earlier "general" assumptions that Asterisk should
not be trying to compensate for broken UAs?


> That being said, it's conceivable we could live without that option now,
> and some phone vendors do still not properly implement the RFC standard
> around this, but we do still run in production with asymmetric codecs on a
> single call leg for a slight majority of our devices.
>
> Josh
>
> On Mon, Jun 15, 2020 at 10:42 AM Michael Maier <m1278468 at mailbox.org>
> wrote:
>
>> Hello George,
>>
>> in terms of uses cases? I'm not aware of any use case which would need
>> asymmetric codecs. The opposite is true: my phones can't handle asymmetric
>> codecs at all - therefore it's
>> forbidden.
>>
>> But I'm not the only one using asterisk - others may have an use case.
>>
>>
>> On 15.06.20 at 01:56 George Joseph wrote:
>> > Given the earlier discussions, under what conditions is it desirable to
>> use
>> > a different codec in one direction than the other on the same call leg?
>>
>>
>> Thanks
>> Michael
>>
>> --
>> _____________________________________________________________________
>> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>>
>> asterisk-dev mailing list
>> To UNSUBSCRIBE or update options visit:
>>    http://lists.digium.com/mailman/listinfo/asterisk-dev
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> asterisk-dev mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-dev



-- 
George Joseph
Asterisk Software Developer
direct/fax +1 256 428 6012
Check us out at www.sangoma.com and www.asterisk.org
[image: image.png]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20200615/1ea1bc8d/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 5142 bytes
Desc: not available
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20200615/1ea1bc8d/attachment.png>


More information about the asterisk-dev mailing list