Photon Voice Error: voice audio frames are not of size: 5760 != 960

I'm getting this error using Photon Voice:
"[PlayerVoice.Speaker] 2021-05-22T15:50:40: UnityAudioOut audio frames are not of size: 5760 != 960"

I didn't change any of the default settings on PhotonVoice, sampling rates or anything. I also couldn't find another reference to this error.
It looks like the buffer received doesn't match the expected length, but I can't figure out why that would be. Any ideas?


  • JohnTube
    JohnTube ✭✭✭✭✭
    edited May 2021
    Hi @dave_mm0,

    Thank you for choosing Photon!

    What Photon Voice version do you use?
    What Unity version do you use?
    Does this happen in Unity Editor or in build?
    Which platform?
    How often does this happen? (not error spam but occurrence of issue itself)

    My guess is that it's either a Unity issue or a result of an audio configuration change in system level (hardware/device or software) or in Unity config.
  • Hey!
    I'm using Unity 2020.3.7f1
    It happens in both Editor and build. It's not quite a spam, but not a one-off either. The error appears a couple times a second, but not every frame, and not regularly.
  • JohnTube
    JohnTube ✭✭✭✭✭
    Hi @dave_mm0,

    Do you have recorder.ReactOnSystemChanges = true and recorder.SkipDeviceChangeChecks = true?
    Which target platform is this?
    Are you using Unity Editor on macOS or Windows or Linux?

    Photon Voice 2.25 was just submitted to the Unity Asset Store, please download it and try to reproduce as soon as it's available.
  • THanks for the reply! I'll update soon enough and let you know.
    For the two properties, I dont modify them, so they are at the default value. Here's my recorder's inspector
  • JohnTube
    JohnTube ✭✭✭✭✭
    Hi @dave_mm0,

    Any new regarding this?
    Does it still happen with newer versions as well?
  • JohnTube
    JohnTube ✭✭✭✭✭
    We have been investigating the weird 5760 value:

    To get 5760 (max) value, you need frame size/duration 60ms and sampling rate 48kHz + stereo:
    60000(60ms)*48000(48kHz)/1000000*2(channels) = 5760

    So do you by chance change frame duration to 60 ms and sampling rate to 48 kHz?
  • Hi @dave_mm0,

    Any update on this.

    Facing same issue with latest Photon voice version.

  • JohnTube
    JohnTube ✭✭✭✭✭

    Hi @yashmatange,

    How can we reproduce?