- Home /
How yo stream mic data to web using UnityWebRequest?
Hi. I want to stream mic input data from Unity to wit.ia web server.
According to Unity side, they say: "It also supports high-demand features such as chunked HTTP requests, streaming POST/PUT operations, and full control over HTTP headers and verbs." https://docs.unity3d.com/Manual/UnityWebRequest.html
And in wit.ia page docs they say: "Streaming audio We accept chunked data, which is a good way to reduce latency. In addition to the Content-type header, you must set a Transfer-encoding header to chunked Audio stream shouldn’t exceed 10s of audio time." https://wit.ai/docs/http/20160526#streaming-audio
Here is more details in the wit.ia side: Definition
POST https://api.wit.ai/speech Example request
$ curl -XPOST 'https://api.wit.ai/speech?v=20160526' \ -i -L \ -H "Authorization: Bearer $TOKEN" \ -H "Content-Type: audio/wav" \ --data-binary "@sample.wav"
I dont know how to handle this. Please, keep in mind that im asking for STREAMING. I already know how to do this without streaming (just sending a recorder wav file from disk).
Any ideas will be appreciated!
Answer by me_unity958 · Sep 22, 2017 at 07:14 PM
@KaOzz Any luck getting this sorted out? I'm about to tackle exactly the same thing.
Your answer
Follow this Question
Related Questions
does anyone know how to set load type to streaming? 0 Answers
Help Audio streaming from microphone to online url. Uploading only 4kb chunk at a time. 1 Answer
How to stop hearing in real time what i am recording with the microphone 0 Answers
Microphone start Blocking UI updates 1 Answer
How do I fill out the "Microphone Usage Description" for a Standalone macOS build? 0 Answers