csipsimple语音呼叫-主叫流程

发布于:2021-11-27 22:06:26

UE-A

DialerFragment 1、发起语音单呼

SipServer

PjSipService

pjsuaJNI

UE-B

2、onCreateView (1)加载布局dialer_digit.xml,布局include了DialerCallBar布局; (2)获取组件,并设置监听事件; (3)实现DialerCallBar类定义的接口OnDialActionListener:语音呼叫placeCall(),视频呼叫placeVideoCall();

3、输入主叫号码,点击语音呼叫按钮

(1)通过placeCall()调用placeCallWithOption();

4、呼叫placeCallWithOption(Bundle b) (1)获取当前选择的登录帐户信息; (2)获取主叫号码; (3)判断登录帐户类型:SIP帐户,调用SipService.makeCallWithOptions()方法;其它帐户,CallHandlerPlugin-->placePluginCall();

5、makeCallWithOptions()方法 (1)获取权限,并启动SipService; (2)判断当前若已有通话,是否支持多路呼叫; (3)发送广播sendOrderedBroadcast;

6、mPlaceCallResultReceiver类处理接收消息 (1)检查参数有效性; (2)获取handle调用pjService.makeCall()完成呼叫

7、makeCall() (1)构建ToCall对象; (2)添加视频呼叫设置; (3)添加消息数据至headers; 8、call_make_call()

9、pj_pool_release()

呼叫被叫号码


相关推荐

最新更新

猜你喜欢