Skip to content

How to connect to microphone using the Web Renderer #32

Answered by nick-thompson
rajangdavis asked this question in Q&A
Discussion options

You must be logged in to vote

Hey @rajangdavis, you're so close!

node.connect(inputSignal.context.destination);

Right here you basically would want something like:

inputSignal.connect(node);
node.connect(inputSignal.context.destination);

So the inputSignal which is your MediaStreamSourceNode connects to the AudioNode returned from WebRenderer.initialize, which then connects to the destination. Once you have that wired up, you can reference the input signals in your elementary graph using el.in({channel: 0}). For example,

core.render(
  el.in({channel: 0}),
  el.in({channel: 1}),
)

This would render a stereo pass-through graph from input to output. In order for stereo in to work, you have to make sure you configure e…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@rajangdavis
Comment options

@nick-thompson
Comment options

@rajangdavis
Comment options

Answer selected by rajangdavis
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants