public override int ChangeRole(GCloudVoiceRole role, string roomName = "")
        {
            Debug.Log("GCloudVoice_C# API: ChangeRole");
            if (!bInit)
            {
                return((int)GCloudVoiceErr.GCLOUD_VOICE_NEED_INIT);
            }
            int nRet = GCloudVoice_ChangeRole((int)role, roomName);

            Debug.Log("GCloudVoice_C# API: GCloudVoice_ChangeRole  nRet=" + nRet);
            return(nRet);
        }
        public override int JoinNationalRoom(string roomName, GCloudVoiceRole role, int msTimeout)
        {
            Debug.Log("GCloudVoice_C# API: JoinNationalRoom");
            if (!bInit)
            {
                return((int)GCloudVoiceErr.GCLOUD_VOICE_NEED_INIT);
            }

            int nRet = GCloudVoice_JoinNationalRoom(roomName, (int)role, msTimeout);

            Debug.Log("GCloudVoice_C# API: JoinNationalRoom  nRet=" + nRet);
            return(nRet);
        }
Ejemplo n.º 3
0
    private void JoinNationalRoom(string strRoomName, GCloudVoiceRole role)
    {
        if (m_voiceengine != null)
        {
            if (m_GCloudVoiceMode != GCloudVoiceMode.RealTime)
            {
                SetModel(GCloudVoiceMode.RealTime);
            }
            IsOpenMicInRoom       = false;
            m_strLastJoinRoomName = "national" + strRoomName;
            m_lastRole            = role;
            Debug.Log("GVoiceManger JoinNationalRoom:" + m_strLastJoinRoomName + role);

            m_voiceengine.JoinNationalRoom(m_strLastJoinRoomName, role, 6000);
        }
    }
Ejemplo n.º 4
0
 /// <summary>
 /// Join in national room with token.
 /// </summary>
 /// <returns>return GCLOUD_VOICE_SUCC</returns>
 public abstract int JoinNationalRoom(string roomName, string token, int timestamp, GCloudVoiceRole role, int msTimeout);
Ejemplo n.º 5
0
 /// <summary>
 /// change role in nation room.
 /// </summary>
 /// <param name="roomName">the room.</param>
 /// <param name="role">the new role value for role conversion.</param>
 /// <returns>if success return GCLOUD_VOICE_SUCC, failed return other errno @see GCloudVoiceErrno</returns>
 public abstract int ChangeRole(GCloudVoiceRole role, string roomName = "");
Ejemplo n.º 6
0
 /// <summary>
 /// Join in a national room.
 /// </summary>
 /// <param name="roomName">the room to join, should be less than 127byte, composed by alpha.</param>
 /// <param name="role"> GCloudVoiceRole value illustrate wheather can send voice data.</param>
 /// <param name="msTimeout">time for join, it is micro second. value range[5000, 60000]</param>
 /// <returns>if success return GCLOUD_VOICE_SUCC, failed return other errno @see GCloudVoiceErrno</returns>
 public abstract int JoinNationalRoom(string roomName, GCloudVoiceRole role, int msTimeout);