Search code examples
actionscript-3

Mute micro phone run time in actionscript


Is there any API call which mutes the microphone in Action Script.If not please tell me how to mute the microphone in Action Script. I tried with the following ways

microphone = Microphone.getMicrophone();
microphone.setLoopBack(false); and
microphone.setSilenceLevel(100);

they don't make any difference to me.


Solution

  • I just found a post which is saying,if we assign gain to 0 then microphone can be muted like below and its working.

    microphone = Microphone.getMicrophone();
    microphone.gain=0;