I get the sound from the microphone using AudioGraph
. When working with an audiograph, audio frames are received every 10 ms. I convert the received data to 16 bit 16 kHz mono. Plus I add wav-header. And all these bytes I pound in InMemoryRandomAccessStream
and send
mediaElement.SetSource(memoryStream.AsRandomAccessStream(), "audio/x-wav");
And this sound is impossible to listen to, because this media element stops and starts every time, so only noise is heard. If I accumulate data up to 100 ms, then more or less, but the transition is still felt. What should I do?
Update
Or should I create a new audiograph and use it to reproduce sound?