User Guide
548 Chapter 7: ActionScript for Flash
var nstepListener:Object = new Object();
nstepListener.change = function(evt:Object) {
active_mic.setSilenceLevel(evt.target.value, active_mic.silenceTimeOut);
};
silenceLevel_nstep.addEventListener("change", nstepListener);
this.onEnterFrame = function() {
silenceLevel_pb.setProgress(active_mic.activityLevel, 100);
};
active_mic.onActivity = function(active:Boolean) {
if (active) {
silenceLevel_pb.indeterminate = false;
silenceLevel_pb.setStyle("themeColor", "haloGreen");
silenceLevel_pb.label = "Activity level: %3";
} else {
silenceLevel_pb.indeterminate = true;
silenceLevel_pb.setStyle("themeColor", "0xFF0000");
silenceLevel_pb.label = "Activity level: (inactive)";
}
};
For more information, see the example for Camera.setMotionLevel().
See also
Microphone.activityLevel, Microphone.onActivity, Microphone.setGain(),
Microphone.silenceLevel, Microphone.silenceTimeOut
Microphone.setUseEchoSuppression()
Availability
Flash Player 6.
Usage
active_mic.setUseEchoSuppression(suppress:Boolean) : Void
Parameters
suppress
A Boolean value indicating whether echo suppression should be used (true) or
not (
false).
Returns
Nothing.
Description
Method; specifies whether to use the echo suppression feature of the audio codec. The default
value is
false unless the user has selected Reduce Echo in the Flash Player Microphone
Settings panel.
Echo suppression is an effort to reduce the effects of audio feedback, which is caused when sound
going out the speaker is picked up by the microphone on the same computer. (This is different
from echo cancellation, which completely removes the feedback.)