zoukankan      html  css  js  c++  java
  • 十天冲刺(第二阶段)

    一、说在前面

     今天开始完善自己的相遇过程中 俩人的语音聊天还是那么难但是自己差不多做完了

    二、完成情况

     语音基本功能实现接下来就是去完成一些细节化比如可以最小化啥的

       CloudManager.getInstance().setReceivedCallListener(new IRongReceivedCallListener() {
                @Override
                public void onReceivedCall(RongCallSession rongCallSession) {
                   // String call=new Gson().toJson(rongCallSession);
    
                    LogUtils.i("rongCallSession");
    
                    if (!CloudManager.getInstance().isVoIPEnabled(CloudService.this))
                    {
                        return;
                    }
                    //呼叫端
                  String callUserId=  rongCallSession.getCallerUserId();
                  callId=  rongCallSession.getCallId();
                  //播放来电铃声
                    mAudioCallMedia.startPlay(CloudManager.callAudioPath);
                    updateWindowInfo(0, rongCallSession.getMediaType(),callUserId);
    
                    if (rongCallSession.getMediaType().equals(RongCallCommon.CallMediaType.AUDIO))
                    {
                        LogUtils.i("音频通话");
    
                        WindowHelper.getInstance().showView(mFullAudioView);
                    }else if (rongCallSession.getMediaType().equals(RongCallCommon.CallMediaType.VIDEO))
                    {
                        LogUtils.i("vieo");
                        WindowHelper.getInstance().showView(mFullVideoView);
                    }
                    isReceiverTo = 1;
                    isCallOrReceiver=false;
                }
    
                @Override
                public void onCheckPermission(RongCallSession rongCallSession) {
                    LogUtils.i("onCheckPermission"+rongCallSession.toString());
                }
            });
            //监听通话状态
            CloudManager.getInstance().setVoIPCallListener(new IRongCallListener() {
                @Override
                public void onCallOutgoing(RongCallSession rongCallSession, SurfaceView surfaceView) {
             //       String call=new Gson().toJson(rongCallSession);
    
                    LogUtils.i("onCallOutgoing");
                    isCallTo=1;
                    isCallOrReceiver=true;
                    //更新信息
                    String targetId=rongCallSession.getTargetId();
                    updateWindowInfo(1,rongCallSession.getMediaType(),targetId);
    //通话Id
                    callId=  rongCallSession.getCallId();
    
                    if (rongCallSession.getMediaType().equals(RongCallCommon.CallMediaType.AUDIO))
                    {
                        LogUtils.i("音频通话");
                        WindowHelper.getInstance().showView(mFullAudioView);
                    }else if (rongCallSession.getMediaType().equals(RongCallCommon.CallMediaType.VIDEO))
                    {
                        LogUtils.i("音频通话");
                        WindowHelper.getInstance().showView(mFullVideoView);
                        //显示 摄像头
                        mLocalView=surfaceView;
                        video_big_video.addView(mLocalView);
                    }
                }
    
                @Override
    

      

     
  • 相关阅读:
    需求采集
    <转>jmeter(十七)目录结构
    《Google软件测试之道》测试开发工程师
    聊聊学习和读书这件事
    聊聊用户
    jmeter(十六)配置元件之计数器
    《探索性软件测试》
    一个完整的性能测试流程
    js外部样式和style属性的添加移除
    jquery获取第一层li
  • 原文地址:https://www.cnblogs.com/guziteng1/p/13044306.html
Copyright © 2011-2022 走看看