SIP API media codecs

橙三吉。 提交于 2019-12-10 18:45:35

问题


I am trying to develop an android application with SIP API (provided in Android 2.3 or higher). I want to know which audio codecs and video codecs does this API supports ? does this API have any tools allowing to configure/choose codecs ? please help me.


回答1:


I want to know which audio codecs and video codecs does this API supports?

You can get supported codec list from docs itself, check AudioCodec.

Those are:

  • PCMU
  • PCMA
  • GSM_EFR
  • GSM
  • AMR

does this API have any tools allowing to configure/choose codecs ?

you could use the APIs related to the SIP and RTP. android.net.rtp contains the AudioStream, AudioGroup and AudioCodec classes that are easy to use. The last of these allows you to choose the codec which you want.

You can create codec as given in above link:

AudioCodec codec = AudioCodec.getCodec(100, "AMR/8000", "mode-set=1");

Then you can set this codec to your AudioStream using setCodec(codec) method.



来源:https://stackoverflow.com/questions/36915903/sip-api-media-codecs

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!