03.05.2013 Views

ActionScript 2.0 Language Reference - Adobe Help and Support

ActionScript 2.0 Language Reference - Adobe Help and Support

ActionScript 2.0 Language Reference - Adobe Help and Support

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

this.onEnterFrame = function() {<br />

silenceLevel_pb.setProgress(active_mic.activityLevel, 100);<br />

};<br />

active_mic.onActivity = function(active:Boolean) {<br />

if (active) {<br />

silenceLevel_pb.indeterminate = false;<br />

silenceLevel_pb.setStyle("themeColor", "haloGreen");<br />

silenceLevel_pb.label = "Activity level: %3";<br />

} else {<br />

silenceLevel_pb.indeterminate = true;<br />

silenceLevel_pb.setStyle("themeColor", "0xFF0000");<br />

silenceLevel_pb.label = "Activity level: (inactive)";<br />

}<br />

};<br />

The MovieClip.getNextHighestDepth() method used in this example requires Flash Player<br />

7 or later. If your SWF file includes a version 2 component, use the version 2 components'<br />

DepthManager class instead of the MovieClip.getNextHighestDepth() method.<br />

See also<br />

setMotionLevel (Camera.setMotionLevel method), activityLevel<br />

(Microphone.activityLevel property), onActivity (Microphone.onActivity<br />

h<strong>and</strong>ler), setGain (Microphone.setGain method), silenceLevel<br />

(Microphone.silenceLevel property), silenceTimeOut<br />

(Microphone.silenceTimeOut property)<br />

setUseEchoSuppression<br />

(Microphone.setUseEchoSuppression method)<br />

public setUseEchoSuppression(useEchoSuppression:Boolean) : Void<br />

Specifies whether to use the echo suppression feature of the audio codec. The default value is<br />

false unless the user has selected Reduce Echo in the Flash Player Microphone Settings<br />

panel.<br />

Echo suppression is an effort to reduce the effects of audio feedback, which is caused when<br />

sound going out the speaker is picked up by the microphone on the same computer. (This is<br />

different from echo cancellation, which completely removes the feedback.)<br />

Generally, echo suppression is advisable when the sound being captured is played through<br />

speakers--instead of a headset--on the same computer. If your SWF file allows users to specify<br />

the sound output device, you may want to call<br />

Microphone.setUseEchoSuppression(true) if they indicate they are using speakers <strong>and</strong><br />

will be using the microphone as well.<br />

Users can also adjust these settings in the Flash Player Microphone Settings panel.<br />

Microphone 811

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!