Skip to content
This repository was archived by the owner on May 30, 2022. It is now read-only.

rikner/microphonejs

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

About

This packages provides an interface to get microphone access via getUserMedia or Flash and use it with the web audio api.

Example

//create a web audio context in your application
var audioContext = new AudioContext();

//to access the microphone, pass the audio context and your callbacks functions
var mic = new Microphone({
    audioContext: audioContext, 
    onSuccess: onready, 
    onReject: onreject
});

//define your onready callback
var onready = function (){
    //connect the mic to your audio graph
    mic.webAudioNode.connect(myWebAudioNode);
    myWebAudioNode.connect(audioContext.destination);
    console.log("mic access permitted");
}

//define your onreject callback
var onreject = function (){
    console.log("mic access rejected");
}

Attention

This package is not completely finished yet, try it and feel free to contribute.

About

Cross Browser Microphone package for Meteor

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%