Starting microphone failed
The whole answer can be found below.
Try Our
Documentation
Please check if you can find an answer in our extensive documentation on Voice.
Join Us
on Discord
Meet and talk to our staff and the entire Photon-Community via Discord.
Read More on
Stack Overflow
Find more information on Stack Overflow (for Circle members only).
Starting microphone failed: issue with photon voice
parul
2022-01-24 09:30:49
Sometimes in quest2 app with unity and i am Instantiate component with PhotonVoiceNetwork and recorder attached to it .I got errors related to starting microphone failed .Even android permission for microphone is also added .10 out 2-3 times error is coming
Unity Version :2018.4.7f1
Photon Voice :v2.15
Logs Related to this issue :
Unity: [Voice(Clone).Recorder] Setting recorder's source to Unity microphone device
Unity: [Voice(Clone).Recorder] [PV] MicWrapper: initializing microphone '', suggested frequency = 48000).
Unity: [Voice(Clone).Recorder] [PV] MicWrapper does not support suggested frequency 48000 (min: 16000, max: 16000). Setting to 16000
Unity: Starting microphone failed: "An error occured that wasn't supposed to. Contact support. " (33)
Photon.Voice.Unity.MicWrapper:.ctor(String, Int32, ILogger)
Photon.Voice.Unity.Recorder:CreateLocalVoiceAudioAndSource()
Unity: [Voice(Clone).Recorder] [PV] MicWrapper: System.NullReferenceException: Object reference not set to an instance of an object.
at Photon.Voice.Unity.MicWrapper..ctor (System.String device, System.Int32 suggestedFrequency, Photon.Voice.ILogger logger) [0x00000] in <00000000000000000000000000000000>:0
After that Recorder.isRecording = false
after room joining no one in room is not able to listen my voice .can you help me why i am getting this error.Is there something i miss .
Comments
Hi @parul,
Thank you for choosing Photon!
This is an exception thrown due to a Unity issue in Microphone API / class.
You can try and reproduce using Unity code without Photon code, simply try starting recording using Microphone.Start method and same device (default probably).
So we suggest to try Photon MicrophoneType from Recorder (native plugin) OR contact Unity or Oculus about this error 33. You can submit a bug report to Unity.
I am trying changing microphone type from Recorder to photon .can photon microphone type not depend on Unity Microphone API. How it works can you explain me ?After some testing with Photon microphone type will let you it works or not.
After changing microphone type to Photon type in recorder its working fine in quest .
Thanks for testing and confirming it works.
Photon microphone type uses a native plugin for the supported platforms.
Hi @parul,
I wanted to come back to this discussion and maybe add the issue to the documentation.
However, I'm curious, do you disable Recorder.UseMicrophoneTypeFallback
? as normally by default if Unity microphone type fails, Photon microphone type will be chosen and used.
@JohnTube we are currently using Photon Voice :v2.15 and Recorder.UseMicrophoneTypeFallback is not in that version .
Back to top