Photon Voice 2: Speaker not linked issue on Oculus Quest

JohnTubeJohnTube mod
edited May 6 in Photon Voice
Hey as already reported on multiple discussions (here, here, here and here) by @BFX, @Lassiiter, @Aitor, @SaravanaPerumal and @CompuGeniusPrograms, PUN 2 integration for Photon Voice 2 using Photon Voice 2 does not seem to work properly on Oculus Quest.

So what needs to be checked:

- Oculus OVR "Can Use Microphone": disable exclusive microphone access,
"LocalAvatarWithGrab" or "+LocalAvatar" GameObject -> "Ovr Avatar (Script)" component -> "Can Own Microphone" checkbox, un-check it.

- all PUN clients need to be joined to a PUN room.
- all PUN clients need to be joined to the same PUN room.
- PhotonView attached to the same GameObject as PhotonVoiceView needs to have a valid ViewID > 0 (but should be > MAX_VIEW_ID, so by default, > 1000, otherwise it may be a scene object)
- all Voice clients need to be joined to a voice room.
- all Voice clients need to be joined to the same voice room.

Local prefab only:

Recorder setup (one option at least needs to be chosen in order for the PhotonVoiceView to have a Recorder):

a- PhotonVoiceVIew.UsePrimaryRecorder is true and PhotonVoiceNetwork.PrimaryRecorder is set
b- PhotonVoiceView.RecorderInUse is set in Editor
c- PhotonVoiceView GameObject has a Recorder in the hierarchy
d- PhotonVoiceView.AutoCreateRecorderIfNotFound is true

other checks:

- PhotonVoiceView.RecorderInUse needs to be initialized
- PhotonVoiceView.RecorderInUse needs to be recording
- PhotonVoiceView.RecorderInUse needs to be transmitting

Remote only or DebugEchoMode+SetupDebugSpeaker:

Speaker setup (one option at least needs to be chosen in order for the PhotonVoiceView to have a Speaker):

a- PhotonVoiceView.SpeakerInUse set in Editor
b- PhotonVoiceView GameObject has a Speaker in hierarchy
c- PhotonVoiceNetwork.AutoCreateSpeakerIfNotFound true + PhotonVoiceNetwork.SpeakerPrefab set (has Speaker in hierarchy)

Things to log for debugging:
PhotonVoiceView.IsPhotonViewReady
PhotonVoiceView.IsSetup
PhotonVoiceView.IsRecorder // local only
PhotonVoiceView.IsRecording // local only
PhotonVoiceView.IsSpeaker
PhotonVoiceView.IsSpeakerLinked
PhotonVoiceView.IsSpeaking

For testing it would help if VAD is disabled.
Also preferably no AudioSource 3D settings changes.

Increase logging level in Voice components to WARNING at least.
Do this for PhotonVoiceView and PhotonVoiceNetwork at least.

(last resort) To force linking:
photonVoiceView.Init();

maybe call it in a loop/coroutine or bind it to a UI button, etc.

Please test again after importing this unitypackage into Photon Voice 2.16.1 (if you downloaded the patch before and tried it, try again as I updated it today).
«1

Comments

  • Hi,

    I'm having this issue so keen to try this fix.

    I've cleared the Photon assets from my project. Downloaded latest version of Voice - 2.16.1 from asset store. No errors. When I apply the patch above I get this error:

    Assets\Photon\PhotonVoice\Code\PUN\PhotonVoiceView.cs(338,41): error CS1503: Argument 1: cannot convert from 'Photon.Voice.PUN.PhotonVoiceNetwork' to 'Photon.Voice.VoiceClient'


    I'm also a bit confused by the fact that in PhotonServerSettings it reports PUN version 2.15. Is that correct? I though PUN had recently been updated to 2.18.1? Or is Voice not compatible with the latest version?

    Thanks,
  • hi @gstevenson,

    It looks like you use an old Photon Voice version.
    Make sure to update Photon Voice 2 properly, sometimes Unity's assets cache mess things up.
    You may need to clear asset store cached files locally on your computer first.
    Check Photon Voice 2's changelog file at "Assets\Photon\PhotonVoice\changes-voice.txt".
    Photon Voice v2.11 (October 11th, 2019) and v2.10 (September 25th, 2019) had PUN 2.15.
  • BFXBFX
    • Updated PUN 2 to 2.18.1
    • Updated Photon Voice to 2.16.1
    • Applied the patch
    From a first test using Desktop and Oculus Quest, it seems happening less, but still happening. Hard to identify the exact sequence of connection/disconnection between the users in the room: looks pretty random.

    When it happens this is the log on the Desktop (VoiceDebug is on the Local Avatar while Remote Voice Debug is on the Remote Avatar)

    https://ibb.co/zRfnhGt
    https://ibb.co/jMnQYXC

    You will probably notice the NullReferenceException, which happens because this line in the VoiceDebug.cs script fails since
    SpeakerInUse
    
    is NULL:
    // debug Speaker status
            if (speaker != null)
            {
                Debug.Log("[Voice Debug] Photon Voice View - IsSpeakerLinked:" + photonVoiceView.SpeakerInUse.IsLinked);
            }
    



    and this is the log on the Oculus Quest:

    LOCAL VOICE DEBUG
    05-06 21:02:33.033 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.033 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.033 4734 4751 I Unity :
    05-06 21:02:33.033 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.033 4734 4751 I Unity :
    05-06 21:02:33.033 4734 4751 I Unity : [Voice Debug] Photon View - View ID:3001
    05-06 21:02:33.033 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.033 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.033 4734 4751 I Unity :
    05-06 21:02:33.033 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.033 4734 4751 I Unity :
    05-06 21:02:33.033 4734 4751 I Unity : [Voice Debug] Photon Voice View - IsSetup:False
    05-06 21:02:33.033 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.033 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.033 4734 4751 I Unity :
    05-06 21:02:33.033 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.033 4734 4751 I Unity :
    05-06 21:02:33.033 4734 4751 I Unity : [Voice Debug] Photon Voice View - IsRecorder:True
    05-06 21:02:33.033 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.033 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.033 4734 4751 I Unity :
    05-06 21:02:33.033 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.033 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : [Voice Debug] Photon Voice View - IsSpeaker:False
    05-06 21:02:33.034 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.034 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.RecorderInUse.IsRecording:True
    05-06 21:02:33.034 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.034 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.RecorderInUse.TransmitEnabled:True
    05-06 21:02:33.034 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.034 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : [Voice Debug] Recorder - IsInitialized:True
    05-06 21:02:33.034 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.034 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : [Voice Debug] Recorder - IsRecording:True
    05-06 21:02:33.034 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.034 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : [Voice Debug] Recorder - TransmitEnabled:True
    05-06 21:02:33.034 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.034 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.034 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.034 4734 4751 I Unity :
    05-06 21:02:33.035 4734 4751 I Unity : [Voice Debug] Recorder - IsCurrentlyTransmitting:False
    05-06 21:02:33.035 4734 4751 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 21:02:33.035 4734 4751 I Unity : VoiceDebug:Update()
    05-06 21:02:33.035 4734 4751 I Unity :
    05-06 21:02:33.035 4734 4751 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 21:02:33.035 4734 4751 I Unity :
    05-06 21:02:33.035 4734 4751 E Unity : NullReferenceException: Object reference not set to an instance of an object.
    05-06 21:02:33.035 4734 4751 E Unity : at VoiceDebug.Update () [0x00000] in <00000000000000000000000000000000>:0
    05-06 21:02:33.035 4734 4751 E Unity :
    05-06 21:02:33.035 4734 4751 E Unity : (Filename: currently not available on il2cpp Line: -1)
    05-06 21:02:33.035 4734 4751 E Unity :

    For some reason remote voice debug is not printing anything.


    The debug script I'm using are

    LOCAL AVATAR VOICE DEBUG
    public class VoiceDebug : MonoBehaviour
    {
    Recorder recorder;
    Speaker speaker;
    PhotonVoiceView photonVoiceView;
    PhotonView photonView;

    // Start is called before the first frame update
    void Start()
    {

    photonVoiceView = GetComponent<PhotonVoiceView>();
    //photonVoiceView.Init();

    recorder = GetComponent<Recorder>();
    speaker = GetComponent<Speaker>();
    photonView = GetComponent<PhotonView>();

    // if (recorder != null)
    // {
    // Debug.Log("Reinitialising microphone...");
    // recorder.MicrophoneType = Recorder.MicType.Photon;
    // recorder.RestartRecording();
    // }
    }

    // Update is called once per frame
    void Update()
    {
    Debug.Log("
    LOCAL AVATAR VOICE DEBUG
    ");
    // debug Photon View
    if (photonView != null)
    {
    Debug.Log("[Voice Debug] Photon View - View ID:" + photonView.ViewID);
    }

    if (photonVoiceView != null)
    {
    Debug.Log("[Voice Debug] Photon Voice View - IsSetup:" + photonVoiceView.IsSetup);
    Debug.Log("[Voice Debug] Photon Voice View - IsRecorder:" + photonVoiceView.IsRecorder);
    Debug.Log("[Voice Debug] Photon Voice View - IsSpeaker:" + photonVoiceView.IsSpeaker);
    Debug.Log("[Voice Debug] Photon Voice View - photonVoiceView.RecorderInUse.IsRecording:" + photonVoiceView.RecorderInUse.IsRecording);
    Debug.Log("[Voice Debug] Photon Voice View - photonVoiceView.RecorderInUse.TransmitEnabled:" + photonVoiceView.RecorderInUse.TransmitEnabled);
    }

    // debug Recorder status

    if (recorder != null)
    {
    Debug.Log("[Voice Debug] Recorder - IsInitialized:" + recorder.IsInitialized);
    Debug.Log("[Voice Debug] Recorder - IsRecording:" + recorder.IsRecording);
    Debug.Log("[Voice Debug] Recorder - TransmitEnabled:" + recorder.TransmitEnabled);
    Debug.Log("[Voice Debug] Recorder - IsCurrentlyTransmitting:" + recorder.IsCurrentlyTransmitting);
    } else {
    Debug.Log("Recorder not set!");
    }

    // debug Speaker status
    if (speaker != null)
    {
    Debug.Log("[Voice Debug] Photon Voice View - IsSpeakerLinked:" + photonVoiceView.SpeakerInUse.IsLinked);
    }

    // Display available microphones
    var enumerator = Recorder.PhotonMicrophoneEnumerator;
    if (enumerator.IsSupported)
    {
    for (int i = 0; i < enumerator.Count; i++)
    {
    Debug.LogFormat("PhotonMicrophone Index={0} ID={1} Name={2}", i, enumerator.IDAtIndex(i),
    enumerator.NameAtIndex(i));
    }
    }
    }
    }

    REMOTE AVATAR DEBUG
    public class RemoteVoiceDebug : MonoBehaviour
    {
    Recorder recorder;
    Speaker speaker;
    PhotonVoiceView photonVoiceView;
    PhotonView photonView;

    // Start is called before the first frame update
    void Start()
    {

    photonVoiceView = GetComponent<PhotonVoiceView>();
    //photonVoiceView.Init();
    speaker = GetComponent<Speaker>();
    photonView = GetComponent<PhotonView>();

    // if (recorder != null)
    // {
    // Debug.Log("Reinitialising microphone...");
    // recorder.MicrophoneType = Recorder.MicType.Photon;
    // recorder.RestartRecording();
    // }
    }

    // Update is called once per frame
    void Update()
    {
    Debug.Log("
    REMOTE AVATAR VOICE DEBUG
    ");
    // debug Photon View
    if (photonView != null)
    {
    Debug.Log("[Remote Voice Debug] Photon View - View ID:" + photonView.ViewID);
    }

    if (photonVoiceView != null)
    {

    Debug.Log("[Remote Voice Debug] Photon Voice View - photonVoiceView.IsSpeaker:" + photonVoiceView.IsSpeaker);
    }


    // debug Speaker status
    if (speaker != null)
    {
    Debug.Log("[Remote Voice Debug] Photon Voice View - photonVoiceView.SpeakerInUse.IsLinked:" + photonVoiceView.SpeakerInUse.IsLinked);
    }
    }
    }
  • BFXBFX
    edited May 6
    For the records, PhotonVoiceNetwork is not in the RemoteAvatar prefab but in another prefab which is fixed in the room that gets loaded when the clients connect to the room. SpeakerPrefab is NULL because I have already a speaker in the remoteAvatar prefab. Maybe this is the problem?
    Should I move everything to the RemoteAvatar prefab? I doubt it is because otherwise how could it work well in the other cases? Why do I need a speaker both in the RemoteAvatar prefab and in the PhotonVoiceNetwork game object?
    b- PhotonVoiceView GameObject has a Speaker in hierarchy
    c- PhotonVoiceNetwork.AutoCreateSpeakerIfNotFound true + PhotonVoiceNetwork.SpeakerPrefab set (has Speaker in hierarchy)

    Do I need to have two speakers in both game objects?
  • JohnTube wrote: »
    hi @gstevenson,

    It looks like you use an old Photon Voice version.
    Make sure to update Photon Voice 2 properly, sometimes Unity's assets cache mess things up.
    You may need to clear asset store cached files locally on your computer first.
    Check Photon Voice 2's changelog file at "Assets\Photon\PhotonVoice\changes-voice.txt".
    Photon Voice v2.11 (October 11th, 2019) and v2.10 (September 25th, 2019) had PUN 2.15.

    Yes you are right - its still got version 2.10!
  • BFXBFX
    edited May 6
    It's still happening, this time when I entered the room with the quest (where there was already the Desktop user waiting), both remote speakesr were not linked. I had to disconnect/reconnect to the room each client in order to get the speakers working.

    Indeed on both logs I could see:
    [RemoteSpeakerSetup.cs] the speaker is not linked, forcing initialisation
    

    which is produced by that emergency coroutine I've set in the remote prefab:
    public class RemoteSpeakSetup : MonoBehaviour
    {
    PhotonVoiceView photonVoiceView;

    // Start is called before the first frame update
    void Start()
    {
    photonVoiceView = GetComponent<PhotonVoiceView>();
    StartCoroutine(InitializeSpeaker());
    }

    // Update is called once per frame
    void Update()
    {

    }

    IEnumerator InitializeSpeaker()
    {
    yield return new WaitForSeconds(3);
    if (photonVoiceView != null) {
    if (photonVoiceView.SpeakerInUse.IsLinked == false) {
    Debug.Log("[RemoteSpeakerSetup.cs] the speaker is not linked, forcing initialisation");
    photonVoiceView.Init();
    } else {
    Debug.Log("[RemoteSpeakerSetup.cs] the speaker is linked!");
    }
    } else{
    Debug.Log("[RemoteSpeakerSetup.cs] photonVoiceView is NULL");
    }
    }
    }

    This stuff is driving us nuts...seriously. Hope you guys find a fix.

    PS. For the records, every single variable in your first post has been set, we'll post a new improved log as soon we can reproduce it (this time we disabled the logs by mistake)
  • BFXBFX
    edited May 6
    Ok we have the logs for when it's not working compared to when it's working.

    WORKING
    Scenario: Client 1(Unity Editor) can hear Client 2 (Oculus Quest) and viceversa

    Unity editor Logs
    https://ibb.co/q7FKNK6
    https://ibb.co/km76thB

    Oculus Quest logs

    VOICE DEBUG FOR OBJECT: LocalAvatar
    05-06 22:26:57.317 9175 9191 I Unity : UnityEngine.Logger:LogFormat(LogType, String, Object[])
    05-06 22:26:57.317 9175 9191 I Unity : UnityEngine.Debug:LogFormat(String, Object[])
    05-06 22:26:57.317 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : [Voice Debug] Photon View - View ID:2001
    05-06 22:26:57.317 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.317 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : [Voice Debug] Photon View - photonVoiceView.IsPhotonViewReady:True
    05-06 22:26:57.317 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.317 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : [Voice Debug] Photon Voice View - UsePrimaryRecorder:False
    05-06 22:26:57.317 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.317 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : [Voice Debug] Photon Voice View - IsSetup:False
    05-06 22:26:57.317 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.317 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.317 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.317 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : [Voice Debug] Photon Voice View - IsRecorder:True
    05-06 22:26:57.318 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.318 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : [Voice Debug] Photon Voice View - IsSpeaker:False
    05-06 22:26:57.318 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.318 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : [Remote Voice Debug] Photon Voice View - photonVoiceView.IsSpeaker:False
    05-06 22:26:57.318 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.318 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.SpeakerInUse:
    05-06 22:26:57.318 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.318 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.RecorderInUse.IsRecording:True
    05-06 22:26:57.318 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.318 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.318 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.318 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.RecorderInUse.TransmitEnabled:True
    05-06 22:26:57.319 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.319 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : [Voice Debug] Recorder - IsInitialized:True
    05-06 22:26:57.319 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.319 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : [Voice Debug] Recorder - IsRecording:True
    05-06 22:26:57.319 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.319 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : [Voice Debug] Recorder - TransmitEnabled:True
    05-06 22:26:57.319 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.319 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : [Voice Debug] Recorder - IsCurrentlyTransmitting:False
    05-06 22:26:57.319 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.319 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.319 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.319 9175 9191 I Unity :
    05-06 22:26:57.320 9175 9191 I Unity :
    END VOICE DEBUG
    05-06 22:26:57.320 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.320 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.320 9175 9191 I Unity :
    05-06 22:26:57.320 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.320 9175 9191 I Unity :
    05-06 22:26:57.320 9175 9191 I Unity :
    VOICE DEBUG FOR OBJECT: RemoteAvatar(Clone)
    05-06 22:26:57.320 9175 9191 I Unity : UnityEngine.Logger:LogFormat(LogType, String, Object[])
    05-06 22:26:57.320 9175 9191 I Unity : UnityEngine.Debug:LogFormat(String, Object[])
    05-06 22:26:57.320 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.320 9175 9191 I Unity :
    05-06 22:26:57.320 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.320 9175 9191 I Unity :
    05-06 22:26:57.320 9175 9191 I Unity : [Voice Debug] Photon View - View ID:1001
    05-06 22:26:57.320 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.320 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.320 9175 9191 I Unity :
    05-06 22:26:57.320 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.320 9175 9191 I Unity :
    05-06 22:26:57.320 9175 9191 I Unity : [Voice Debug] Photon View - photonVoiceView.IsPhotonViewReady:True
    05-06 22:26:57.320 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.320 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.320 9175 9191 I Unity :
    05-06 22:26:57.320 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.320 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : [Voice Debug] Photon Voice View - UsePrimaryRecorder:False
    05-06 22:26:57.321 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.321 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : [Voice Debug] Photon Voice View - IsSetup:False
    05-06 22:26:57.321 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.321 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : [Voice Debug] Photon Voice View - IsRecorder:False
    05-06 22:26:57.321 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.321 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : [Voice Debug] Photon Voice View - IsSpeaker:True
    05-06 22:26:57.321 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.321 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : [Remote Voice Debug] Photon Voice View - photonVoiceView.IsSpeaker:True
    05-06 22:26:57.321 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.321 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.SpeakerInUse:RemoteAvatar(Clone) (Photon.Voice.Unity.Speaker)
    05-06 22:26:57.321 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.321 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.321 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.321 9175 9191 I Unity :
    05-06 22:26:57.322 9175 9191 I Unity : [Voice Debug] Photon Voice View - IsSpeakerLinked:True
    05-06 22:26:57.322 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.322 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.322 9175 9191 I Unity :
    05-06 22:26:57.322 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.322 9175 9191 I Unity :
    05-06 22:26:57.322 9175 9191 W Unity : [RemoteAvatar(Clone).PhotonVoiceView] No need to set Recorder as the PhotonView does not belong to local player
    05-06 22:26:57.322 9175 9191 W Unity : UnityEngine.Logger:LogFormat(LogType, Object, String, Object[])
    05-06 22:26:57.322 9175 9191 W Unity : UnityEngine.Debug:LogWarningFormat(Object, String, Object[])
    05-06 22:26:57.322 9175 9191 W Unity : Photon.Voice.PUN.PhotonVoiceView:get_RecorderInUse()
    05-06 22:26:57.322 9175 9191 W Unity : VoiceDebug:Update()
    05-06 22:26:57.322 9175 9191 W Unity :
    05-06 22:26:57.322 9175 9191 W Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.322 9175 9191 W Unity :
    05-06 22:26:57.322 9175 9191 I Unity : Recorder not set!
    05-06 22:26:57.322 9175 9191 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 22:26:57.322 9175 9191 I Unity : VoiceDebug:Update()
    05-06 22:26:57.322 9175 9191 I Unity :
    05-06 22:26:57.322 9175 9191 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 22:26:57.322 9175 9191 I Unity :
    05-06 22:26:57.322 9175 9191 I Unity :
    END VOICE DEBUG


    NOT WORKING
    Scenario: Client 1(Unity Editor) can hear Client 2 (Oculus Quest) but NOT VICEVERSA

    Unity editor Logs
    https://ibb.co/Mf7NsFN
    https://ibb.co/sCprk9K

    Oculus Quest logs

    VOICE DEBUG FOR OBJECT: LocalAvatar
    05-06 23:08:40.007 13042 13058 I Unity : UnityEngine.Logger:LogFormat(LogType, String, Object[])
    05-06 23:08:40.007 13042 13058 I Unity : UnityEngine.Debug:LogFormat(String, Object[])
    05-06 23:08:40.007 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.007 13042 13058 I Unity :
    05-06 23:08:40.007 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.007 13042 13058 I Unity :
    05-06 23:08:40.007 13042 13058 I Unity : [Voice Debug] Photon View - View ID:2001
    05-06 23:08:40.007 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.007 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.007 13042 13058 I Unity :
    05-06 23:08:40.007 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.007 13042 13058 I Unity :
    05-06 23:08:40.007 13042 13058 I Unity : [Voice Debug] Photon View - photonVoiceView.IsPhotonViewReady:True
    05-06 23:08:40.007 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.007 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.007 13042 13058 I Unity :
    05-06 23:08:40.007 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.007 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : [Voice Debug] Photon Voice View - UsePrimaryRecorder:False
    05-06 23:08:40.008 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.008 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : [Voice Debug] Photon Voice View - IsSetup:False
    05-06 23:08:40.008 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.008 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : [Voice Debug] Photon Voice View - IsRecorder:True
    05-06 23:08:40.008 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.008 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : [Voice Debug] Photon Voice View - IsSpeaker:False
    05-06 23:08:40.008 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.008 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : [Remote Voice Debug] Photon Voice View - photonVoiceView.IsSpeaker:False
    05-06 23:08:40.008 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.008 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.SpeakerInUse:
    05-06 23:08:40.008 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.008 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.008 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.008 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.RecorderInUse.IsRecording:True
    05-06 23:08:40.009 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.009 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.RecorderInUse.TransmitEnabled:True
    05-06 23:08:40.009 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.009 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : [Voice Debug] Recorder - IsInitialized:True
    05-06 23:08:40.009 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.009 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : [Voice Debug] Recorder - IsRecording:True
    05-06 23:08:40.009 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.009 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : [Voice Debug] Recorder - TransmitEnabled:True
    05-06 23:08:40.009 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.009 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.009 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.009 13042 13058 I Unity :
    05-06 23:08:40.010 13042 13058 I Unity : [Voice Debug] Recorder - IsCurrentlyTransmitting:False
    05-06 23:08:40.010 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.010 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.010 13042 13058 I Unity :
    05-06 23:08:40.010 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.010 13042 13058 I Unity :
    05-06 23:08:40.010 13042 13058 I Unity :
    END VOICE DEBUG
    05-06 23:08:40.010 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.010 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.010 13042 13058 I Unity :
    05-06 23:08:40.010 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.010 13042 13058 I Unity :
    05-06 23:08:40.010 13042 13058 I Unity :
    VOICE DEBUG FOR OBJECT: RemoteAvatar(Clone)
    05-06 23:08:40.010 13042 13058 I Unity : UnityEngine.Logger:LogFormat(LogType, String, Object[])
    05-06 23:08:40.010 13042 13058 I Unity : UnityEngine.Debug:LogFormat(String, Object[])
    05-06 23:08:40.010 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.010 13042 13058 I Unity :
    05-06 23:08:40.010 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.010 13042 13058 I Unity :
    05-06 23:08:40.010 13042 13058 I Unity : [Voice Debug] Photon View - View ID:1001
    05-06 23:08:40.010 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.010 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.010 13042 13058 I Unity :
    05-06 23:08:40.010 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.010 13042 13058 I Unity :
    05-06 23:08:40.011 13042 13058 I Unity : [Voice Debug] Photon View - photonVoiceView.IsPhotonViewReady:True
    05-06 23:08:40.011 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.011 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.011 13042 13058 I Unity :
    05-06 23:08:40.011 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.011 13042 13058 I Unity :
    05-06 23:08:40.014 13042 13058 I Unity : [Voice Debug] Photon Voice View - UsePrimaryRecorder:False
    05-06 23:08:40.014 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.014 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.014 13042 13058 I Unity :
    05-06 23:08:40.014 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.014 13042 13058 I Unity :
    05-06 23:08:40.014 13042 13058 I Unity : [Voice Debug] Photon Voice View - IsSetup:False
    05-06 23:08:40.014 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.014 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.014 13042 13058 I Unity :
    05-06 23:08:40.014 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.014 13042 13058 I Unity :
    05-06 23:08:40.014 13042 13058 I Unity : [Voice Debug] Photon Voice View - IsRecorder:False
    05-06 23:08:40.014 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.014 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.014 13042 13058 I Unity :
    05-06 23:08:40.014 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.014 13042 13058 I Unity :
    05-06 23:08:40.015 13042 13058 I Unity : [Voice Debug] Photon Voice View - IsSpeaker:True
    05-06 23:08:40.015 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.015 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.015 13042 13058 I Unity :
    05-06 23:08:40.015 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.015 13042 13058 I Unity :
    05-06 23:08:40.015 13042 13058 I Unity : [Remote Voice Debug] Photon Voice View - photonVoiceView.IsSpeaker:True
    05-06 23:08:40.015 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.015 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.015 13042 13058 I Unity :
    05-06 23:08:40.015 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.015 13042 13058 I Unity :
    05-06 23:08:40.015 13042 13058 I Unity : [Voice Debug] Photon Voice View - photonVoiceView.SpeakerInUse:RemoteAvatar(Clone) (Photon.Voice.Unity.Speaker)
    05-06 23:08:40.015 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.015 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.015 13042 13058 I Unity :
    05-06 23:08:40.015 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.015 13042 13058 I Unity :
    05-06 23:08:40.015 13042 13058 I Unity : [Voice Debug] Photon Voice View - IsSpeakerLinked:False
    05-06 23:08:40.015 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.015 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.015 13042 13058 I Unity :
    05-06 23:08:40.015 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.015 13042 13058 I Unity :
    05-06 23:08:40.016 13042 13058 W Unity : [RemoteAvatar(Clone).PhotonVoiceView] No need to set Recorder as the PhotonView does not belong to local player
    05-06 23:08:40.016 13042 13058 W Unity : UnityEngine.Logger:LogFormat(LogType, Object, String, Object[])
    05-06 23:08:40.016 13042 13058 W Unity : UnityEngine.Debug:LogWarningFormat(Object, String, Object[])
    05-06 23:08:40.016 13042 13058 W Unity : Photon.Voice.PUN.PhotonVoiceView:get_RecorderInUse()
    05-06 23:08:40.016 13042 13058 W Unity : VoiceDebug:Update()
    05-06 23:08:40.016 13042 13058 W Unity :
    05-06 23:08:40.016 13042 13058 W Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.016 13042 13058 W Unity :
    05-06 23:08:40.016 13042 13058 I Unity : Recorder not set!
    05-06 23:08:40.016 13042 13058 I Unity : UnityEngine.Logger:Log(LogType, Object)
    05-06 23:08:40.016 13042 13058 I Unity : VoiceDebug:Update()
    05-06 23:08:40.016 13042 13058 I Unity :
    05-06 23:08:40.016 13042 13058 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
    05-06 23:08:40.016 13042 13058 I Unity :
    05-06 23:08:40.016 13042 13058 I Unity :
    END VOICE DEBUG

    THE ONLY SOLUTION IS, AS ALWAYS, TO DISCONNECT AND RECONNECT THE CLIENT WHOSE REMOTE AVATAR'S SPEAKER IS NOT LINKED.
  • Hey,

    Thanks @BFX.

    Do you load scenes on join?
    Do you have PhotonVoiceNetwork is in the scene, or in a prefab or neither?
    PhotonVoiceNetwork has DontDestroyOnLoad enabled?

    The disconnect workaround, means, you disconnect or leave room from PUN? or from Voice client?
    The avatars are destroyed and re created in this case?
    Do I need to have two speakers in both game objects?
    No, in Recorder or Speaker setup you need to choose one option at least to guarantee there is one Recorder for local avatar and one Speaker for remote one.

    If someone could send a minimal repro project that would help and make things faster.
  • Hi,

    For us updating to the latest Voice/PUn and installing the patch has made it work. I didn't try without installing the patch so can't be 100% sure exactly what fixed it.

    Thank you!
  • BFXBFX
    edited May 7
    Do you load scenes on join?

    Yes, we load the scene using:
    public override void OnJoinedRoom()
            {
                // The first player load the scene, otherwise we rely on `PhotonNetwork.AutomaticallySyncScene` to sync our instance scene
                if (PhotonNetwork.CurrentRoom.PlayerCount == 1)
                {
                    Debug.LogFormat("RoomService: First user loads the scene {0}", _currentRoom.scene);
                    PhotonNetwork.LoadLevel(_currentRoom.scene);
                }
            }
    

    ————————
    Do you have PhotonVoiceNetwork is in the scene, or in a prefab or neither?
    PhotonVoiceNetwork has DontDestroyOnLoad enabled?

    Each scene (except the initial Lobby) has a gameObject (prefab) in the hierarchy which contains PhotonVoiceNetwork component. DontDestroyOnLoad is FALSE because we don’t need that object when the user disconnects from the room and gets back to the Lobby.

    https://ibb.co/W5ZQd0n

    We tried removing PhotonVoiceNetwork from that prefab and moving it inside another object in our Lobby (called Services) with DontDestroyOnLoad set to TRUE so it would persist across room.

    For now, the error is not happening so IT might be it was one of the causes.

    ————————
    The disconnect workaround, means, you disconnect or leave room from PUN? or from Voice client?

    We disconnect using:
    PhotonNetwork.Disconnect();
    

    Not sure what do you mean by “disconnecting from Voice Client”

    ————————
    The avatars are destroyed and recreated in this case?
    Yes, the avatars get destroyed and re-created every time

    ————————
    Do I need to have two speakers in both game objects?
    No, in Recorder or Speaker setup you need to choose one option at least to guarantee there is one Recorder for local avatar and one Speaker for a remote one.

    We removed the prefab speaker in PhotonVoiceNetwork and disabled “Create speaker if not found” as the RemoteAvatar prefab already includes a PhotonVoiceView+Speaker

    —————————
    If someone could send a minimal repro project that would help and make things faster.

    Unfortunately, it would be hard due to company IP protection


    CURRENT SITUATION: We have tried 5 different scenarios and the error doesn't seem happening: it looks like the patch + moving PhotonVoiceNetwork made the trick for the Desktop<—>Oculus Quest testing HOWEVER we still need to test on 2 Oculus Quest devices so I will update you soon.

    Stay tuned! :)


  • BFXBFX
    After a very long testing session with two Oculus Quest I can confirm this is still happening. Specifically the first time we install the app is happening. After that, we can disconnect/reconnect to the room or kill the app and join the room and it will work fine. PhotonNetwork is in a permanent object with DontdestroyOnLoad active. We noticed an improvement after doing that but I still don't get why the first time the speaker doesn't link.
    To be more specific it seems like it's the guest client has a problem with the speaker, while the guest could hear the master client.
  • Hi,

    For us updating to the latest Voice/PUN and installing the patch has made it work. I didn't try without installing the patch so can't be 100% sure exactly what fixed it.

    Thank you!
  • hI @BFX,

    Try this new patch.
    First try the patch w/o any workarounds.
    If the issue persists after this, now there is an RPC method, if you can't hear a remote avatar locally call photonVoiceView.CantHearYou() and see the logs for error returned and see if it fixes the issue.
  • edited May 14
    Having an issue here, too - with Oculus Quest. In a debug, it's not finding the Oculus Quest microphone at all. Is there somewhere I need to set the application to request permission to use the Oculus Quest's microphone? -- When I do a debug, the microphone.devices list comes back with a count of 0.
  • mabomabo
    It looks like I am running into the issue as well. I have updated both PUN and Voice to latest and applied all patches above but I am still having issues. The patches improved the situation but I am still having issues every second or third time I connect with a Oculus Quest client.

    I don't know how to get logs from Unity. The log files stated in the documentation doesn't contain the logs from my run or no logs at all. But I'll try to summarize what I see in the console.

    Quest seems a bit slower to connect to the Voice servers than my editor. So when the prefab containing the Voice VIew is instantiated, the Voice connection is only in state 'ConnectingToNameserver'. I get this warning:
    AndroidPlayer([email protected]:34999) [Voice.PhotonVoiceNetwork] Cannot check late linking while not joined to a voice room, client state: ConnectingToNameServer
    

    This is really the only difference I see between my editor and quest when they connect to each other. But I get the warning every time I connect regardless if the voice from the editor is heard or not by the Quest player.

    It's hard to know If I have setup everything as I should. There are a lot of different speaker/recorder combinations you can configure and I have tried a lot of combinations without any success.

    Next, I'll will test by separating the Photon View and Voice View from the same prefab since I am getting the feeling that I get some race condition when combining them. Maybe Voice works better if it's more "standalone".
  • mabomabo
    Took 5 min to setup Voice without PUN and it worked the first time. Now I get voice every time I connect. I need to test more and with different clients but it looks very promising.

    So, my recommendation: Don't use Voice with PUN. It would have saved me hours, if not days, of testing and debugging.
  • Hi @dan_synthetaic,

    Thank you for choosing Photon!

    Interesting, this is new to us.
    Are you saying Unity's Microphones.devices is empty or Photon microphones enumerator does not yield any element?
    I prefer to discuss this on a separate forum discussion if you agree as it's a bit different from the issue here.

    Hi @mabo,

    Thank you for choosing Photon!
    This is really the only difference I see between my editor and quest when they connect to each other. But I get the warning every time I connect regardless if the voice from the editor is heard or not by the Quest player.
    We will remove that warning, it should not be logged every time.
    It's hard to know If I have setup everything as I should. There are a lot of different speaker/recorder combinations you can configure and I have tried a lot of combinations without any success.
    That is the price we pay when we want to give customers more options and flexibility. But the PUN Voice demo scene is what should be followed:

    - PhotonVoiceNetwork in the scene + DontDestroyOnLoad
    - one primary Recorder in the scene.
    - one PhotonVoiceView + one speaker per prefab.
  • edited May 15
    Hi @mabo - Definitely we can start a new thread on this. Do you want me to start a new thread, or do you want to?

    For more info:
    My setup is as the above comment:
    • One PhotonVoiceNetwork on a main game-object in the scene, along with one primary Recorder.
    • One PhotonVoiceView with one Speaker in the player prefabs that are instantiated by PUN.

    I set up a debug field in my Quest and pushed into it (in a Start() function):

    mainController.AddStatusMessage("Microphones Detected: " + Microphone.devices.Length);
    foreach (var device in Microphone.devices)
    {
    mainController.AddStatusMessage(" - Microphone Name: " + device.ToString());
    }


    (mainController has a function "AddStatusMessage()" that accepts a string and adds it to my status field so I can debug while running it on my Quest)

    It shows "Microphones Detected: 0"

    One other question that may resolve this as not a new Quest update issue: do I need to request permission for the microphone (Android) separately? I'm not doing this, and it only just occurred to me that maybe that's the issue? If the Android device doesn't give my app permission, Unity just wouldn't see any Microphones available?

    I'd only assumed the Voice add-on already does something like this - but someone from another forum suggested it may be that my app doesn't have permission to use the Microphone on the Android device (Quest).

    If this is the case, do you know if there is a setting I can check in the Unity Build, or is this something I need to do in code to get permission for the Microphone?
  • Hi @dan_synthetaic,

    Read about it here.
    We may add a UtilityScript that does this automatically.
  • AMROAMRO
    edited May 15
    thanks for your help!
  • Hi @JohnTube, we have also tried the second patch file and using the CantHearYou RPC and can see that most of the time when there is no sound the problem is caused by the Recorder is not Recording. I have now added some code check this and to make sure the Recorder is always recording. I wanted to ask whether this patch is going to be incorporated into the main product in future releases?
  • Hi @gstevenson,

    The patch will not be part of Photon Voice as is.
    The debug RPC CantHearYou won't be added to the package but you can easily use it by adding it to another script attached to the same GameObject as PhotonVoiceView.

    Expect a Photon Voice 2 update very soon.
    most of the time when there is no sound the problem is caused by the Recorder is not Recording
    hmm. is it a timing issue or you do not start recording at all? do you have recorder.AutoStart disabled & you do not call recorder.StartRecording?
    and in the other cases what was the issue?
  • Hi,

    The Recorder is set to AutoStart. I think it probably is a timing issue. I don't call recorder.StartRecording anywhere.

    Based on the code in the CantHearYou function I now regularly check whether photonVoiceView.RecorderInUse.IsRecording is true and if not set it to true. Occassionally it switches off again whilst in our app - I am not 100% sure of the cirumstances.

    This is the main issue I've had. None of the other fixes seem necessary such as turning off VAD. I once had a problem where none of the CantHearYou fixes worked including Debug Echo and eventually got the 'Should be working message'. Tried restarting the app and still had the problem. However a complete reboot fixed it so it does seem possible the Quest can get in a state where the microphone just doesn't work.

  • JohnTubeJohnTube mod
    edited May 29
    Hey everyone:

    Photon Voice 2.17 is out.
    It would be nice to check it out and see if it helps you solve the issue or identify the cause.
    I suggest you set LogLevel to WARNING at least if not INFO/ALL for all Voice components (PhotonVoiceNetwork, PhotonVoiceVIew, Speaker, Recorder).

    If you load scenes after joining rooms, this could be a cause, try restarting recording.

    @gstevenson

    here's a CantHearYou script you could use.
    EDIT: proper CantHearYou script.
    EDIT 2: putting an updated version here:
    namespace Photon.Voice.PUN.UtilityScripts
    {
        using Pun;
        using Unity;
        using Realtime;
        using UnityEngine;
    
        // created by Hamza Lazaar (JohnTube) 2020-05-30 for Photon Voice 2.17
        [RequireComponent(typeof(PhotonVoiceView))]
        public class VoiceDebugScript : MonoBehaviourPun
        {
            private PhotonVoiceView photonVoiceView;
    
            public bool ForceRecordingAndTransmission;
    
            public AudioClip testAudioClip;
    
            public bool TestUsingAudioClip;
    
            private void Awake()
            {
                this.photonVoiceView = this.GetComponent<PhotonVoiceView>();
            }
    
            private void Update()
            {
                if (this.photonVoiceView.IsRecorder)
                {
                    if (this.TestUsingAudioClip)
                    {
                        if (!this.testAudioClip || this.testAudioClip == null)
                        {
                            Debug.LogError("Set an AudioClip first");
                        }
                        else
                        {
                            this.photonVoiceView.RecorderInUse.SourceType = Recorder.InputSourceType.AudioClip;
                            this.photonVoiceView.RecorderInUse.AudioClip = this.testAudioClip;
                            this.photonVoiceView.RecorderInUse.LoopAudioClip = true;
                            if (this.photonVoiceView.RecorderInUse.RequiresRestart)
                            {
                                this.photonVoiceView.RecorderInUse.RestartRecording();
                            }
                            else
                            {
                                this.photonVoiceView.RecorderInUse.StartRecording();
                            }
                            this.photonVoiceView.RecorderInUse.TransmitEnabled = true;
                        }
                    }
                    if (this.ForceRecordingAndTransmission)
                    {
                        this.photonVoiceView.RecorderInUse.IsRecording = true;
                        this.photonVoiceView.RecorderInUse.TransmitEnabled = true;
                    }
                }
            }
    
            [ContextMenu("CantHearYou")]
            public void CantHearYou()
            {
                if (!PhotonVoiceNetwork.Instance.Client.InRoom)
                {
                    Debug.LogErrorFormat("local voice client is not joined to a voice room");
                }
                else if (!this.photonVoiceView.IsPhotonViewReady)
                {
                    Debug.LogError("PhotonView is not ready yet; maybe PUN client is not joined to a room yet or this PhotonView is not valid");
                }
                else if (!this.photonVoiceView.IsSpeaker)
                {
                    Debug.LogError("locally not speaker (yet?)");
                    this.photonVoiceView.Setup();
                }
                else
                {
                    if (!this.photonVoiceView.IsSpeakerLinked)
                    {
                        Debug.LogErrorFormat("locally speaker not linked, asking anyway");
                    }
                    this.photonView.RPC("CantHearYou", this.photonView.Owner, PhotonVoiceNetwork.Instance.Client.CurrentRoom.Name, PhotonVoiceNetwork.Instance.Client.LoadBalancingPeer.ServerIpAddress, PhotonVoiceNetwork.Instance.Client.AppVersion);
                }
            }
    
            [PunRPC]
            private void CantHearYou(string roomName, string serverIp, string appVersion, PhotonMessageInfo photonMessageInfo)
            {
                string why;
                if (!PhotonVoiceNetwork.Instance.Client.InRoom)
                {
                    why = "voice client not in a room";
                }
                else if (!PhotonVoiceNetwork.Instance.Client.CurrentRoom.Name.Equals(roomName))
                {
                    why = string.Format("voice client is on another room {0} != {1}",
                        PhotonVoiceNetwork.Instance.Client.CurrentRoom.Name, roomName);
                }
                else if (!PhotonVoiceNetwork.Instance.Client.LoadBalancingPeer.ServerIpAddress.Equals(serverIp))
                {
                    why = string.Format("voice client is on another server {0} != {1}",
                        PhotonVoiceNetwork.Instance.Client.LoadBalancingPeer.ServerIpAddress, serverIp);
                }
                else if (!PhotonVoiceNetwork.Instance.Client.AppVersion.Equals(appVersion))
                {
                    why = string.Format("voice client uses different AppVersion {0} != {1}",
                        PhotonVoiceNetwork.Instance.Client.AppVersion, appVersion);
                }
                else if (!this.photonVoiceView.IsRecorder)
                {
                    why = "recorder not setup (yet?)";
                    this.photonVoiceView.Setup();
                }
                else if (!this.photonVoiceView.RecorderInUse.IsRecording)
                {
                    why = "recorder is not recording";
                    this.photonVoiceView.RecorderInUse.IsRecording = true;
                }
                else if (!this.photonVoiceView.RecorderInUse.TransmitEnabled)
                {
                    why = "recorder is not transmitting";
                    this.photonVoiceView.RecorderInUse.TransmitEnabled = true;
                }
                else if (this.photonVoiceView.RecorderInUse.InterestGroup != 0)
                {
                    why = "recorder.InterestGroup is not zero? is this on purpose? switching it back to zero";
                    this.photonVoiceView.RecorderInUse.InterestGroup = 0;
                }
                else if (!(this.photonVoiceView.RecorderInUse.UserData is int) || (int)this.photonVoiceView.RecorderInUse.UserData != this.photonView.ViewID)
                {
                    why = string.Format("recorder.UserData ({0}) != photonView.ViewID ({1}), fixing it now", this.photonVoiceView.RecorderInUse.UserData, this.photonView.ViewID);
                    this.photonVoiceView.RecorderInUse.UserData = this.photonView.ViewID;
                    this.photonVoiceView.RecorderInUse.RestartRecording();
                }
                else if (this.photonVoiceView.RecorderInUse.VoiceDetection) // todo: check WebRtcAudioDsp.VAD
                {
                    why = "recorder vad is enabled, disable it for testing";
                    this.photonVoiceView.RecorderInUse.VoiceDetection = false;
                }
                else if (this.photonView.IsMine)
                {
                    if (this.photonVoiceView.IsSpeaker)
                    {
                        why = "no idea why!, should be working (1)";
                        this.RestartRecording(this.photonVoiceView.RecorderInUse);
                    }
                    else if (!this.photonVoiceView.SetupDebugSpeaker)
                    {
                        why = "setup debug speaker not enabled, enabling it now";
                        this.photonVoiceView.SetupDebugSpeaker = true;
                    }
                    else if (!this.photonVoiceView.RecorderInUse.DebugEchoMode)
                    {
                        why = "recorder debug echo mode not enabled, enabling it now";
                        this.photonVoiceView.RecorderInUse.DebugEchoMode = true;
                    }
                    else
                    {
                        why = "locally not speaker (yet?)";
                        this.photonVoiceView.Setup();
                    }
                }
                else
                {
                    why = "no idea why!, should be working (2)";
                    this.RestartRecording(this.photonVoiceView.RecorderInUse);
                }
                this.Reply(why, photonMessageInfo.Sender);
            }
    
            private void Reply(string why, Player player)
            {
                this.photonView.RPC("HeresWhy", player, why);
            }
    
            [PunRPC]
            private void HeresWhy(string why, PhotonMessageInfo photonMessageInfo)
            {
                Debug.LogErrorFormat("Player {0} replied to my CantHearYou message with {1}", photonMessageInfo.Sender, why);
            }
    
            private void RestartRecording(Recorder recorder)
            {
                recorder.StopRecording();
                recorder.StartRecording();
            }
        }
    }
    
  • Hello :smile:
    Have a nice day
    Thanks you
  • mabomabo
    Hi again,

    I had to make use of PUN again for the voice. (Wanted to get voice indication of my players to work but couldn't find a way to connect the speaker with my remote player prefab instance unless I created the speaker with the remote player.) Saw that 2.17 was out so I tried it again and it seems to be stable now.

    Not sure if I implemented my solution differently this time or if the update solved it. But it doesn't matter as long as it works. :smile: Thanks for the update!
  • Having a similair issue. Updated to 2.17 today but still happening. Oddly, my Unity editor and my personal Quest can hear each other 95% of the time. My bosses headset on the same build can connect and can hear me and my editor as well as both hear him.

    A co worker joins the room and has never been able to connect to voice on his headset. I've created scripts to log all the info locally so he can read it off to me and his data always matches mine.

    as an aside - IsSpeakerLinked always returns false for me but still works?

    Any help or ideas on how to resolve this would be MUCH appreciated!
  • Hi @acuitycraig,

    Thank you for choosing Photon!

    You can use the VoiceDebugScript from this post.
    Attach it to the same GameObject as PhotonVoiceView.
    Call CantHearYou method on the character/avatar that you cannot hear and check the logs.
  • as an aside - IsSpeakerLinked always returns false for me but still works?
    you are either checking earlier (before linking is done) OR you are checking the wrong Speaker.
  • The user that I can consistently not hear gets the "locally speaker not linked, asking anyway" when using the canthearyou command. He now has 2 headsets and both have the issue. I'm wondering if this is possibly a port or firewall issue at his home. We tested while he tethered to his phone and had the same issue. Any other suggestions based on the error?

    Also just to make 100% sure I am setting this up right -
    Each scene has a voice object in it at start, this is not instantiated or spawned by PUN, its just in the each "map" the user can select.
    The Voice object has a Photon Voice Network component, and a Recorder on it. Auto connect and join, auto leave and disconnect are true. Primary recorder is set to the recorder on the same object. Recorder has Transmit enabled and auto start true.

    The avatars which are spawned by a PhotonNetwork.Instantiate command when a user joins has a -
    PhotonView
    Photon Voice View
    Voice debug script
    A child object of the avatar (the head) has -
    Photon View
    Audio Source
    Speaker

    The Photon Voice view on the avatar has the Use Primary recorder set to true and the Speaker In Use is set to the speaker component on the avatar's Head child object.

    Is this correct? I based it on the demo example so I assume it is but want to be sure.

    Thank you!

Sign In or Register to comment.