ActionScript 2.0 :: Sound Object > To Play While Streaming?
Sep 30, 2010
I had a question. So now I am streaming an mo3 file using the sound object (loadSound function) ...So the mp3 is loading (and I have a progress bar showing the percentage loaded) and while it is loading it is being played. Now, when the playhead (the location being played) reaches the end of whatever has been download, it goes to the beginning (repeats). I am looking for a way to make the sound pause once it reaches the end, and then wait until a reasonable amount has been downlaoded, so that it may continue playing again. I hope I was clear.
View 5 Replies
Similar Posts:
Jun 14, 2004
I have a streaming sound that is loaded into my flash movie (will end up on CD) that is very distorted, it sounds like someone is slowing down the audio, the voice sounds deep and slow
View 1 Replies
Feb 25, 2004
Is it possible to control streaming sound object?
View 1 Replies
Mar 8, 2010
I've got a presentation that features an audio loop for background music and streaming audio on the timeline for the voice over.When I try to lower the volume of the background music (sound object), it also effects the voice over (streaming).I'm a total novice, so try to use laymen's terms.[code]And this is on the Frame that contains the movieclip with the voice over.I'm trying to fade the background music ONLY:[code]
View 10 Replies
Aug 9, 2004
I am new to actionscript. I have created a script that will play server side sound object and client side mp3 files alternately. Now, I would like to play the client side mp3 first then only play server side sound object alternately. However, I have no idea how can I do so. The following is the code that need to be swapped:
[Code].....
View 2 Replies
Jan 5, 2011
Trying to write a function that will play a sound through a small FX (sound) class I made. The sound that I want played is passed in through a variable. I don't want to write a different function for every sound, so I've named the sound linkage class the same name as the name of another object in an array. However, it looks like I'm trying to pass the name of something off as an object, which won't work and I'm getting this error:
TypeError: Error #1007: Instantiation attempted on a non-constructor.
Can I convert a 'name' into an object (of the same name)?
View 1 Replies
Apr 13, 2011
What I have are several items on a stage and when they are clicked I want to capture their names so I can use it to play a sound file that relates with the object clicked. For example: say I have a square, rectangle, and a square on the stage and when the user clicks on "triangle" it would play the sound "triangle_snd". This is what I have so far and the error I am getting from it.[code]...
View 2 Replies
Oct 20, 2011
I am using a flash app. I can send and receive streaming data to FMS by using this app, like the chart I attached. [URL] This app uses RTMP to access to FMS. I want to upgrade this app to display sound level of each client. Is it possible by using Actionscript and FMS? If so, which class should I use?
View 3 Replies
Apr 17, 2010
I am using Flash CS4. To illustrate, I created a new flash file and added a short tick sound to the library. I set the properties of the sound to export to Actionscript and named the class "overSound". I added a Movieclip object to the stage to represent a button and gave it an instance name of "overButton". On frame 1 of the main timeline I added the following code:
[Code]...
View 5 Replies
Oct 14, 2009
It's possible to play a sound file through AS, either by loading it from a folder or import it to flash. It's also possible to play a dynamic tone with flash.media.Sound + writeFloat.
But... is it possible to play a sound file with flash.media.Sound + writeFloat in some way? I want to play a sound file without having to deal with any files except the .swf!
View 9 Replies
Apr 30, 2009
I have CS4 but saving doc as CS3 so I hope I am in the right forum. I added a behavior as sound streaming mp3. I want to loop it.. Here is the action code that was generated. How would I change it to looping. I changed the true to false at the end of the code but that didn't work. here it is:
//Load Streaming mp3 behavior if(_global.Behaviors == null)_global.Behaviors = {}; if(_global.Behaviors.Sound == null)_global.Behaviors.Sound = {}; if(typeof this.createEmptyMovieClip == 'undefined'){ this._parent.createEmptyMovieClip('BS_figaro',new Date().getTime()-(Math.floor((new Date().getTime()) /10000)*10000) ); _global.Behaviors.Sound.figaro = new Sound(this._parent.BS_figaro);
[code]....
View 6 Replies
Apr 30, 2009
I added a behavior as sound streaming mp3. I want to loop it.. Here is the action code that was generated. How would I change it to looping. I changed the true to false at the end of the code but that didn't work.here it is:
//Load Streaming mp3 behavior
if(_global.Behaviors == null)_global.Behaviors = {};
if(_global.Behaviors.Sound == null)_global.Behaviors.Sound = {};
[code]......
View 3 Replies
Feb 18, 2010
I am trying to write an mp3 player. I have tried everything and am suck getting the duration of an mp3.[code]...
View 1 Replies
Mar 2, 2011
I used NetStream.play("invalid-live-stream-url") to play an invalid live stream. The other arguments are using default, e.g. start = -2, len = -1.
The menu says that when we use the default "start" and "len" to call "NetStream.play", "Plays the live stream until it is no longer available. If a live stream of the specified name is not found, Flash Player plays a recorded stream until it ends."
However, I do not have a recorded stream on the server that has the same name as the live stream, and I did not get the expected "NetStream.Play.StreamNotFound" error.
View 1 Replies
Feb 13, 2007
i want to make a single button to play a sound, and if pressed again, stop the sound. and if pressed again, play the sound, and so on...
i know it has to be made with a boolean variable, true/false, but i just can't figure out how.
View 13 Replies
Jun 6, 2008
I'm streaming an external SWF into another movieclip, the external SWF has a timeline animation and sound (voice speech) as well on the timeline, it also has a preloader on it which it's set up that when 30% loaded is completed to start playing the animation.But when I run the main movieclip the streaming of the external SWF works fine for the animation but the sound does not play until the preloader is 100% completed.
View 1 Replies
Jun 3, 2010
So I've been "doing research" for a couple of days now, found nothing on this subject, and let me get this straight:
Is there no way to pause/resume a sound whilst it's being streamed?
Because loadSound() will start playing it immediately; attachSound() can't stream; and start() will simply not work till it's fully downloaded, or am I missing some essential brain cells here?[code]...
View 2 Replies
Apr 18, 2011
I have few movieclip play one after another. For each movieclip, i put the streaming sound inside, and there is a button to turn off sound. I created this coding to turn off the streaming sound and it worked well.
SoundMixer.stopAll(); But, the problem is the new streaming sound will play again when it hit the frame that contain new streaming sound. How to overcome this problem? IS using EnterFrame event the only way to turn off the streaming sound forever??
View 3 Replies
Jan 2, 2008
I am having trouble with sounds from a streaming flv continuing to play even after the playhead navigates to a different place in the timeline. I know from looking through forums and Adobe's livedocs that the answer lies with the SoundMixer class, but I just can't seem to get it to work. I am building a site that houses all of the videos for my company, so basically I want the sound from the flv to stop playing when the user navigates away from the frame that contains the flv.
Here is a sample of the particular code I am trying to use to do this:
Code: Select allimport flash.media.SoundMixer;
var sControl:SoundMixer = new SoundMixer();
msfNavHeader_btn.addEventListener(MouseEvent.CLICK, msfHome)
[Code]....
I don't know if there is a way to build a function that stops sounds globally or if I have to target each instance of an FLVPlayback Component.
View 5 Replies
Oct 8, 2008
i have a little problem with a streaming load sound. this is the code:
[code]...
i don't understand because if i testing the swf i listen the sound super fastly and with IE6 too. FireFox and IE7 no. i have read that is the bitrate mp3 ... something like 128 kbs 44hz to run corectly but with i can't do the mp3 compression.
View 1 Replies
Jun 11, 2010
Is there a way to resume a streaming sound once it's been paused and whilst it's being preloaded in AS2?The issue being that start() won't work till the song is fully downloaded, loadSound() is only called initially and attachSound() can't stream.So first the sound is initiated with loadSound(), then I make it "pause" with stop() and what do I use for resuming? loadSound() with re-initiate it and start() won't work till the sound is fully preloaded, what the hell??Is there any other way of streaming external MP3s in AS2? Will simply switching to AS3 solve this?
View 1 Replies
Jun 14, 2009
I am trying to import a swf I made that contains streaming sound. When I place it on the time line and press cntr enter my animation plays but with no audio. I see the symbols from the swf and the swf inside my library. When I open the swf file inside my project it is broken down frame by frame with no audio. I can add audio back into my movie clip so I know that movie clips can support streaming audio. But I would rather not have to do this.
I'm very new to flash so I am hoping there is something big that I am missing.In addition to my previous question: I need to embed a lot of objects over and over in this project I am working on. Each object will have controls for play back of itself. Is there some reason I cannot do this?
View 6 Replies
May 3, 2011
I am pretty dense about flash, pretty new to the software so bare with me. So on the main .fla i have linked to a button to open the external swf mp3 player. That Mp3 player is streaming a song with the code var req:URLRequest = new URLRequest("mysong.mp3"); snd.load(req);
the mp3 is in a folder which is located in the same place as both the .fla and .swf mp3 player. Streaming the mp3 works when testing the swf. but there is no sound when testing the linked swf mp3 player in the main .fla. It's like the file path messes up but i dont know how to go about fixing it?
View 7 Replies
Nov 14, 2010
I'm struggling with a flash file that I want to play two different sound files when the appropriate buttons are pressed.I've gotten it to the point where it will load without any errors popping up, but instead of playing the second sound when I press the button for that sound, it plays the first sound again. Here's the code:
var sc1:SoundChannel = new SoundChannel();
var s1:Sound = new Sound();
s1.load(new URLRequest("http://www.website.com/wells.mp3"));
[code]....
View 1 Replies
Jan 28, 2012
I'm working on an app to stream audio from shoutcast. The streaming goes well on my computer and when debugging it with an Android-configuration. But when I deploy it to an APK-file and run it on a Samsung Galaxy S, the streaming doesn't work.
My code for streaming the audio:
var urlRequest:URLRequest = new URLRequest("http://.../;");
var soundContext:SoundLoaderContext = new SoundLoaderContext(2000, true);
soundChannel = new SoundChannel();
sound = new Sound(urlRequest, soundContext);
soundChannel = sound.play();
I've also tried an addEventListener(Event.COMPLETE), it seems my app doesn't get there when running on a Samsung Galaxy.
View 1 Replies
Jan 8, 2010
I'm new and I've got a problem I've been trying to fix for a couple days and haven't been able to.I am loading youtube videos in to movie clips with actionscript on a frame:
this.video_mc1.loadMovie ("http://www.youtube.com/v/URL");
this.video_mc2.loadMovie ("http://www.youtube.com/v/URL");
this.video_mc3.loadMovie ("http://www.youtube.com/v/URL");
[code]....
View 2 Replies
Sep 8, 2010
I'm picking up Flash and AS3 after working with AS1 a few years back. My first project is a mp3 player that is able to take an mp3 file, a start loop point, and an end loop point to loop the mp3 without any gaps or breaks in the sound.
blog.andre-michelle.com/2010/playback-mp3-loop-gapless
I found this page that got me started, and went off of that code. The resulting player works perfectly except for one fatal flaw. As far as I know, the mp3 file must be fully loaded to be able to use the Sound.extract method on it, this can take a while when the files are 3-4 MB, especially on slow connections. I want to be able to have the audio start playing as soon as the mp3 file begins loading.Is there any way to use the Sound.extract method on a streaming audio file that has not fully loaded yet?
View 6 Replies
Nov 20, 2010
I have a small application to play a stream from an Internet radio broadcast. When I play the .swf locally it has no problem at all, but once I put the swf on the browser, nothing plays. I don't know if is a security issue. The path to the stream file is in another domain of the page I am mounting it, for example, I put my html file on: w w w . myradio.com/index.html and the swf is calling [URL]
View 2 Replies
Apr 18, 2011
I'm streaming an external MP3 (around 3 mb file) with the following method:
ActionScript Code:
import flash.media.Sound;
import flash.media.SoundLoaderContext;
import flash.net.URLRequest;
[Code].....
With that i have no problem, where i am completely lost is the possibility of triggering an event after de 15 seconds (first parameter of SoundLoaderContext) are loaded, ie, adding an event listener or something like that.
View 2 Replies
May 11, 2009
I created a flash movie that has some words breaking a piece of glass. I have the effect working well but I wanted to add sound. I created the following sound class to play mp3 files:
Code: Select allpackage ascript
{
import flash.display.Sprite;
[code].....
View 1 Replies