PhotonVoiceRecorder - Microphone Type - Photon

If on the PhotonVoiceRecorder - Microphone Type I select Photon, then it doesn't matter what Microphone I set it to use like this:
PhotonVoiceNetwork.MicrophoneDevice = "Razer Mic";

As it always defaults to what Windows has as it's default.

Is there something else I need to do?

Comments

  • JohnTube
    JohnTube ✭✭✭✭✭
    edited April 2018
    Can you try "Assets\PUNVoice\TestVoice" scene?
    It gives you the option to choose which mic.

    btw what platform are you using?
    The "Microphone Type" is still undocumented, it means whether you use Unity's built-in audio input API or the native/"direct" access to device's input hardware for the four major platforms: Windows, macOS, Android and iOS as we build native plugins for each.
    Unity's Microphone may be limited in some ways like dynamic/runtime device switching and or echo/noise cancellation, etc.
  • I found a way around it, I set PhotonVoiceNetwork.PhotonMicrophoneDeviceID to switch microphones.

    I'm using Windows, macOS and Linux. Does that mean it's going to fail on Linux?

    Why is it undocumented, I'd also like to know what the "Type Convert" dropdown does too?
  • There also is a bug where the "Microphone Type" dropdown does not save its settings on a prefab (think it's caused after switching Target Platforms)

    Trying to enforce the Photon Microphone Type also caused a lot of issues for existing players that there Microphones stopped working.
    "Logitech G533 wireless headset" was one of them on Windows.
    and another had issues on the Mac with a different headset (don't have the name anymore as the post was deleted)
    I had to roll back to use Unity's Microphone.
  • I also had a problem where the Microphone Type change not getting saved. For now, I'm just hardcoding the type to Unity in the setup, but obviously that's not ideal. This seems like something that should be easy to fix.
  • JohnTube
    JohnTube ✭✭✭✭✭
    edited May 2019
    Hi @SniperED007,

    Sorry I missed this discussion.
    I had it bookmarked but hey can't blame me for getting married in April 2018 :smile:

    Why is it undocumented, I'd also like to know what the "Type Convert" dropdown does too?
    Microphone Type is now documented: Photon Voice 1, Photon Voice 2
    TypeConvert is going away in the next Photon Voice updates.
    Basically, it means to tell Photon Voice to convert audio frame buffer type from float to short to be used by some digital signal processor that expects and requires that type, e.g. WebRtcAudioDsp. In the future, this will be done in abstraction invisibly to the user.
    Trying to enforce the Photon Microphone Type also caused a lot of issues for existing players that there Microphones stopped working.
    I think we fixed this already, is it still happening? what do you mean with "enforce"?

    What we did regarding persisting microphone device name or ID either Unity or Photon's:
    - save it (SerializeField) only for the Unity Editor because in the build different machines can have different devices (number, names).
    - in the properties' getters and setters we only allow valid values by doing checks.
    - not all platforms support Photon Microphone enumeration (changing device ID)
    - Unity default microphone is null -> first array in Microphone.devices array if any
    - Photon default microphone is -1 -> first one if any

    hey @BuilderWorldVR,

    I will try to answer on both forum and by email