[asterisk-users] can PJSIP_MEDIA_OFFER work like SIP_CODEC?

d tbsky tbskyd at gmail.com
Sun Sep 28 10:07:51 CDT 2014

2014-09-28 14:01 GMT+08:00 Markus <universe at truemetal.org>:
> Am 27.09.2014 17:28, schrieb d tbsky:
>>     can someone give an example for the function? thanks for the help.
> Not a programmer here, just grep -r'ed through the code, but maybe try one
> of these:
> G711A
> G711_ALAW

   thanks a lot for help!!  I tried both but none works. maybe this
function can not work like the old channel variable "SIP_CODEC", which
can change inbound call codec. but I do notice something different
between chan_sip and chan_pjsip.

  I use zoiper softphone for testing:

   when I dialout  sip trunk with chan_sip, the remote peer rings, and
zoiper now shows what codec to use. if I use "SIP_CODEC"  before dial
to change the codec,  zoiper will use the new CODEC, but asterisk
internal won't change and still transcoding in the middle.(at least
"core show channel sip/xxxxx" told me transcoding)

  when I dialout sip trunk with chan_pjsip, the remote peer rings, but
zoiper didn't show what codec to use. only after the callee answer the
phone, zoiper shows what codec to use. so it seems chan_pjsip have
better chance to do the right thing without transcoding. it's sad that
chan_pjsip won't select best codec match two peers automatically
without transcoding. but I hope it at least can provide  a magic
function or channel variable like "SIP_CODEC/SIP_CODEC_INBOUND" to
make correct codec selection.


More information about the asterisk-users mailing list