Speech to text and Photon Voice

In my multiplayer game, there is two separate feature I wanted to support.

1. Players across networks can hear each other's voice - For this, I am using photon voice

2. Chatbot functionality - Bot will recognize the player's speech and converts it into text - For this, I have created a plugin from Android native SpeechRecognizer class

I am using this STT plugin - https://github.com/j1mmyto9/Speech-And-Text-Unity-iOS-Android

My problem:

For IOS build all work good! I can speak with players and use STT together

BUT! For Android build, if i use Photon, STT don't work

Why?

Answers

  • JohnTube
    JohnTube ✭✭✭✭✭

    Hi @werven,

    Maybe this is because multiple plugins can't access the same microphone at the same time?

    did you try using Photon microphone type from Recorder?

  • i dont have :

    using Photon.Voice.Unity.Recorder

    аfter Unity i have Demos, Editor, UtilityScripts


    i know that i should use this https://doc.photonengine.com/en-us/voice/v1/getting-started/voice-for-pun

    but i dont have this namespace.....

  • JohnTube
    JohnTube ✭✭✭✭✭

    Hi, there is no Recorder in Photon Voice Classic or Photon Voice 1.

    It was named PhotonVoiceRecorder but please use Photon Voice 2 instead for the sake of you and me (us).

  • Same problem here... I've tried that already, it doesn't work with microphone type Photon or Unity... Any idea? I'm using Unity 2022 + Photon Voice 2 + Android native SpeechRecognizer class. I saw an article suggesting to create audio clip from microphone and then send it to Photon. Is it possible? How :)