ahdinosaur / read-audio

:microphone: Read raw audio input as a stream of ndsamples
http://livejs.github.io/read-audio/
10 stars 2 forks source link

take in MediaStream as `input`, stop using `getusermedia` #3

Closed ahdinosaur closed 9 years ago

ahdinosaur commented 9 years ago

so browser version is synchronous as well.

this will be a breaking change.

binarykitchen commented 9 years ago

how then can you convert the data getUserMedia produces to a MediaStream?

ahdinosaur commented 9 years ago

getUserMedia should return a MediaStream, which can then be converted to an MediaStreamAudioSourceNode with AudioContext.createMediaStreamSource(). the existing code does this, the plan now is to remove getUserMedia from this module so a read-audio consumer must get the media stream themselves and then read-audio can always synchronously return the ndsamples stream.

binarykitchen commented 9 years ago

have you already made any progress?

ahdinosaur commented 9 years ago

ahh, didn't realize you were waiting on me. done. :smiley_cat:

binarykitchen commented 9 years ago

cool, will check that out in the next days for my www.videomail.io project