Errors with IL2CPP Builds:

Options
[PrimaryVoiceRecorder.Recorder] [PV] WindowsAudioInPusher: System.NotSupportedException: IL2CPP does not support marshaling delegates that point to instance methods to native code. The method we're attempting to marshal is: Photon.Voice.Windows.WindowsAudioInPusher::push
at Photon.Voice.Windows.WindowsAudioInPusher..ctor (System.Int32 deviceID, Photon.Voice.ILogger logger) [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.Recorder.CreateLocalVoiceAudioAndSource () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.Recorder.Setup () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.Recorder.StartRecording () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.Recorder.Init (Photon.Voice.Unity.VoiceConnection voiceConnection) [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.VoiceConnection.TryInitializePrimaryRecorder () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.VoiceConnection.Awake () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.PUN.PhotonVoiceNetwork.Awake () [0x00000] in <00000000000000000000000000000000>:0
UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
UnityEngine.Logger:LogFormat(LogType, Object, String, Object[])
UnityEngine.Debug:LogErrorFormat(Object, String, Object[])
Photon.Voice.Unity.VoiceLogger:LogError(String, Object[])
Photon.Voice.Windows.WindowsAudioInPusher:.ctor(Int32, ILogger)
Photon.Voice.Unity.Recorder:CreateLocalVoiceAudioAndSource()
Photon.Voice.Unity.Recorder:Setup()
Photon.Voice.Unity.Recorder:StartRecording()
Photon.Voice.Unity.Recorder:Init(VoiceConnection)
Photon.Voice.Unity.VoiceConnection:TryInitializePrimaryRecorder()
Photon.Voice.Unity.VoiceConnection:Awake()
Photon.Voice.PUN.PhotonVoiceNetwork:Awake()

(Filename: C:\buildslave\unity\build\Runtime/Export/Debug/Debug.bindings.h Line: 35)

[PrimaryVoiceRecorder.Recorder] Photon microphone input source creation failure: System.NotSupportedException: IL2CPP does not support marshaling delegates that point to instance methods to native code. The method we're attempting to marshal is: Photon.Voice.Windows.WindowsAudioInPusher::push
at Photon.Voice.Windows.WindowsAudioInPusher..ctor (System.Int32 deviceID, Photon.Voice.ILogger logger) [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.Recorder.CreateLocalVoiceAudioAndSource () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.Recorder.Setup () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.Recorder.StartRecording () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.Recorder.Init (Photon.Voice.Unity.VoiceConnection voiceConnection) [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.VoiceConnection.TryInitializePrimaryRecorder () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.Unity.VoiceConnection.Awake () [0x00000] in <00000000000000000000000000000000>:0
at Photon.Voice.PUN.PhotonVoiceNetwork.Awake () [0x00000] in <00000000000000000000000000000000>:0 . Falling back to Unity microphone
UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
UnityEngine.Logger:LogFormat(LogType, Object, String, Object[])
UnityEngine.Debug:LogErrorFormat(Object, String, Object[])
Photon.Voice.Unity.VoiceLogger:LogError(String, Object[])
Photon.Voice.Unity.Recorder:CreateLocalVoiceAudioAndSource()
Photon.Voice.Unity.Recorder:Setup()
Photon.Voice.Unity.Recorder:StartRecording()
Photon.Voice.Unity.Recorder:Init(VoiceConnection)
Photon.Voice.Unity.VoiceConnection:TryInitializePrimaryRecorder()
Photon.Voice.Unity.VoiceConnection:Awake()
Photon.Voice.PUN.PhotonVoiceNetwork:Awake()

Comments

  • using 2019.3.0f3
    Photon Voice 2.12
  • vadim
    Options
    IL2CPP Windows export is not compatible with Photon type microphone currently. You need to switch to Unity microphone or change scripting backend.
  • Are there any plans to make it compatible as Unity Microphone is unreliable.
  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @SniperED007,

    We are working on making IL2CPP work with Photon MicrophoneType on Windows in the next update.
  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @SniperED007,

    I just submitted version 2.13.
    When possible, could you retry building for Windows / IL2CPP again?
    Thanks.
  • JohnTube wrote: »
    Hi @SniperED007,

    I just submitted version 2.13.
    When possible, could you retry building for Windows / IL2CPP again?
    Thanks.

    Thanks, tested it and it works.