0 Replies Latest reply on Sep 5, 2008 3:58 AM by vokle

    How to get a SoundChannel from a NetStream

      I want to have a similar output to the example here: http://www.marcofolio.net/actionscript/visualize_audio_bars_by_using_amplitude_in_flash.ht ml

      but instead of the audio coming from an mp3 file via a URLRequest, I want the audio to come from a NetStream originating from a Flash Media Server.

      The ultimate goal is to have multiple netstreams coming in each with their own audio amplitude bar being displayed.

      This is being written in Flex 3 using Actionscript 3.

      The API docs for NetStream.play() (@ http://livedocs.adobe.com/flex/3/langref/flash/net/NetStream.html#play() ) says the following:

      "To control the audio associated with a video file, you can use the DisplayObjectContainer.addChild() method to route the audio to an object on the display list; you can then create a Sound object to control some aspects of the audio. For more information, see the DisplayObjectContainer.addChild() method."

      but the DisplayObjectContainer.addChild() method doesn't provide any further information and I cannot figure out how to use an AS3 Sound or SoundChannel object with a DisplayObjectContainer or a NetStream.