Actionscript 3 :: Flash: Generate/display Sound Waveform For Uploaded Sound?

Mar 14, 2011

I have a project that requires me to display the waveform for a uploaded sound. The sound is always an MP3, most of the time 22.05 kHz mono, with speech only. The project are written with Flex/ActionScript 3. It's meant to run in the browser, but might also consider converting to AIR if that can help.

All examples I've found and looked at for generating a wave, are either doing some visualization in real time as the sound is playing, or, the most promising, as3soundeditorlib, keeps the wave already generated, but does it very slowly, seemingly using as long time as playing through the audio would've taken.Is there any way to generate the wave faster than real time?

View 2 Replies


Similar Posts:


Actionscript 3 :: Play A Generated Waveform As A Sound In Flash?

Jan 17, 2011

If I have a sound waveform stored as a ByteArray in actionscript 3, how would I go about converting this into a Sound object that can be played?

Note that the array is full of sound samples - a complete generated waveform. It isn't an array containing an mp3 or other compressed data.

View 2 Replies

AS3 :: Flash - Sound.extract() - Create A Visual Waveform For An MP3

May 29, 2011

I'm trying to create a visual waveform for an MP3. The code I've included is called on successful load of the MP3. I intend to extract just a few important samples from the sound to create the waveform, rather than extract the entire sound into a bytearray. Even on a good machine, extracting an entire song can cause flash to freeze up for 3-5 seconds (or longer!). For my purposes, this isn't feasible.

Unfortunately, the code I've got below is failing to produce any numbers. If I extract the entire song it functions, but extraction of just the key points is giving me nothing. Does performing an extract make the remainder of the sound object invalid for future extracts? If so, is there some way around this that won't freeze flash for an extended period of time during the extract? Some important variables from the rest of the code:

[Code]...

View 2 Replies

ActionScript 3.0 :: Generating A Simple Waveform Of A Sound Object?

May 28, 2011

How do I go about generating a simple waveform of a sound object.

View 5 Replies

ActionScript 3.0 :: Grab A Sound And Make A Realtime Waveform Graph?

Mar 7, 2012

I found on Adobe website this cool as3 code to grab a sound and make a realtime waveform graph (I cannot post the link..The problem, to me, is that I cannot create in the same stage 2 graph from 2 input: the mic and an mp3.In my purpose, I'd like a stage with just 2 waveform graph. the upper one with the realtime voice from the mic input.the second one (just below the previous one) with a similar waveform graph but drawn by an MP3 file (or wav).

At the beginning I tried to use 2 inputs ".microphone" but I can always see just 1 graph. It's like the resources cannot be shared (al least not so simply).

View 3 Replies

Actionscript 3 :: Sound Latency - Set It For Any Silence Before The Actual Sound By Calling The Sound

Apr 16, 2011

I am triggering short sounds dynamically from the library for a game (Specifically Air for Android). When the user clicks a button the sound can take up to 600ms to actually play. I have set it for any silence before the actual sound by calling the sound like so:

[Code]...

All return the same results. I know there are threads here that talk about this but none have offered a real solution that I can find. Is there no way to cache the sound or store it in a buffer?

View 1 Replies

Flash :: Dynamically Create New Sound Objects Based On Raw WAV / DATA Or Other Sound Object?

Jan 31, 2012

Is there any AS3 library or code-snippet that can create altered versions of a Sound object on-the-fly (at runtime)? Either based on:

An existing Sound object; A ByteArray object;

For example, say you have a "dry" sound of a gun-shot. You could:

[Code]...

View 1 Replies

ActionScript 3.0 :: Sound Class Type - Cannot Convert C$ To Flash.media.Sound

Oct 25, 2009

I have some sounds in my library. They are all exported and have been given class names like C, D, E etc. I have another class that represents a button. This class stores a reference to one of the Sound in my library. I set the type for this variable to Sound. When I try to set it I get the error: cannot convert C$ to flash.media.Sound I try as Sound, for example key.note = note_array[p] as Sound; The value ends up as null.

View 2 Replies

Flash :: Synchronizing Sound - Sound Gets Terrible As Time Passes?

Jan 31, 2010

It appears my sound is off sync and the longer I play the movieclip, the farther off sync it goes. Its nothing too complicated, just some basic shooting sounds that fire every time I hit the space bar. My code is below:

package com.objects{

import flash.display.MovieClip;
import flash.media.Sound;
import flash.media.SoundChannel;[code]....

The Attack() method gets called from another class that handles all keyboard controls.when it gets called the sound then plays.firesound and firesound2 are almost the same. firesound2 sounds a little off pitch to make it sound more realistic.At first the sound sounds pretty good, not great. but then it gets terrible as time passes.

I made a new .fla project. and I attached the following class to it by it self. so the following is the only code in the entire .fla project and the issue still occurs. I press the spacebar and the sound starts a day late.

package {
import flash.display.MovieClip;
import flash.events.*;[code]......

View 2 Replies

Flash :: Playing Sound From Data Acquired From Sound.extract()?

Aug 1, 2011

I'm trying to play a sound using a technique found here (play the sound by sampling raw sound data gathered from the original with extract()), with the difference that the mp3 sound is embedded in the swf, not loaded externally. This is my code:

var soundBytes:ByteArray = new ByteArray();
var mp3sound:Sound = Sound(new Sound1_design()); // this is the embedded sound
mp3sound.extract(soundBytes, int.MAX_VALUE);

[Code]....

This works, in a way, except that the resulting sound is distorted (it has a kind of a metallic ring).

View 1 Replies

Flash - Take Two Sound Objects And Combine Them Into One Sound Object

Nov 15, 2010

Is it possible to take two Sound objects and combine them into one Sound object so that one Sound plays, and then the second plays right after it? I can just play the first Sound and then the next right after it, but it would be much cleaner to combine them before playing the audio.

View 1 Replies

ActionScript 3.0 :: How To Display Sound Bar On Top

Dec 7, 2009

I have a nested movie clip which has the code written in one frame on a single layer.I want to incorporate a Slider to control the volume.Created a layer on top of the action script and pulled the slider on that layer at the stage.Added the code etc to the instance name of the slider but when the movie clips start playing( it is a dynamic slide show) they conceal the sliderHow do I make the slider visible on top of the images.Or shall I reverse the process i.e. build the slider on the main timeline. But then how do I assess the instance name from the Main TimeLine in the nested movie clip.

View 4 Replies

ActionScript 2.0 :: Play Sound Like "stop All Sound" Option In Flash?

May 17, 2003

I want to use a sound loop in my flash movie. The movie has many scenes. And the problem is that when I go to next scene or different scene I hear the sound repeating twice. I mean sound does not stop from first scene and begins from the different scenes.Is there any way to play sound like "stop all sound" option in Flash.

View 6 Replies

Loading With Sound Only Played Once But Keeping Hover Over Menu Item Sound Intack?

May 21, 2010

I have a flash header that was never completed because the guy I hired took people's money and ran. So now I even wonder if what he said could work with my flash header is true or not. But, usually there is always a way to make it work.

I have a flash header that does two important things: 1) Upon entering the site, it loads and plays an audio track 2) Makes an animal noise when you hover over each animal menu item. (not sure if I'm able to give a link to it or not on here. If I able to and someone would like to see it let me know)

I want to know if my flash header can support the following additional functionality/changes:

1) Currently, it loads everytime a page is selected. I only want it to load the one time of entering the site because the audio gets annoying. Set a cookie maybe?

2) But, I do not want to turn the audio off completely because I still want the hover over each menu item sound.

3) Have a link on it to allow them to select to turn on / off the sound completely. It currently has that, but only for the current page. Once you select another page, the audio is back to on.

4) Lastlly, is there a way for it to detect that someone doesn't support flash and to display an html version of it? And can flash create a html version from my fla file?

I don't know much about flash (but am learning) so I'm not sure if I'll be able to do this myself. However, I want to find out if my flash header will even work this way before I invest the time learning it just for these changes. I know it will be pretty deep with script code, but I'm hoping I could find base code already available for these features. Not sure I can afford help now because of being laid off and two different scammers taking advantage of me. So I'm going to try to do myself and see if there is any suggestions/support on here that can help. I have Flash CS4.

View 2 Replies

ActionScript 1/2 :: Make Button On Rollover Starts Sound And Rolloff Stops Sound?

Jul 28, 2009

I have several buttons in a movie and I want to be able to rollover an individual button and play the sound for that button and when I rolloff I want the sound for that button to stop.

View 6 Replies

IDE :: Loading With Sound Only Played Once But Keeping Hover Over Menu Item Sound Intact?

May 21, 2010

I have a flash header that was never completed because the guy I hired took people's money and ran. So now I even wonder if what he said could work with my flash header is true or not. But, usually there is always a way to make it work.I have a flash header that does two important things: 1) Upon entering the site, it loads and plays an audio track 2) Makes an animal noise when you hover over each animal menu item. I want to know if my flash header can support the following additional functionality/changes:

1) Currently, it loads everytime a page is selected. I only want it to load the one time of entering the site because the audio gets annoying. Set a cookie maybe?

2) But, I do not want to turn the audio off completely because I still want the hover over each menu item sound.

3) Have a link on it to allow them to select to turn on / off the sound completely. It currently has that, but only for the current page. Once you select another page, the audio is back to on.

4) Lastlly, is there a way for it to detect that someone doesn't support flash and to display an html version of it? And can flash create a html version from my fla file?

I don't know much about flash (but am learning) so I'm not sure if I'll be able to do this myself. However, I want to find out if my flash header will even work this way before I invest the time learning it just for these changes. I know it will be pretty deep with script code, but I'm hoping I could find base code already available for these features. Not sure I can afford help now because of being laid off and two different scammers taking advantage of me. So I'm going to try to do myself and see if there is any suggestions/support on here that can help. I have Flash CS4.

View 4 Replies

Media Server :: Get Sound Level Of Each Clients Who Are Streaming Video And Sound?

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

Actionscript 3 :: Sound.extract Method Empties Sound Object Data

May 20, 2011

I am using the following to extract the byte info from a sound object - however if I go back to the same sound object and run this again, The byteArray has no bytes available.

var data:ByteArray = new ByteArray;
sound.extract(data,sound.length*44.1);
data.position = 0;
return data;

Is this the correct behavior? Is there not a way to do this multiple times on the same sound object?

View 3 Replies

ActionScript 2.0 :: Add Mute Sound And Unmute Sound Script In A Single Button?

Sep 21, 2011

how to add mute sound and unmute sound script in a single button?

View 2 Replies

ActionScript 2.0 :: Global - Attach A Sound To The Main Timeline (rollover Sound)

Jun 28, 2004

I want to attach a sound to the main timeline (rollover sound) that i can call from on(rollover) button events. I will be attaching the same sound to several buttons.

View 1 Replies

ActionScript 2.0 :: Movie And Sound - Make The Sound Fade Away When The Mouse Is Rolled Away?

May 18, 2007

I use Flash MX 6.0

1) I have a button and when I put cursor over it, it must start looping a sound. When I drag away, the sound must stop. I would be even cooler if it was possible to make the sound fade away when the mouse is rolled away. I have no problem creating another sound file that fades my current sound away.

2) I have a button which represents a knife, that should stab something (a panel) once pressed. So fist the knife must be clean. but after one or more presses, the blood should remain as a movie clip (as I want to animate the dripping blood)

3) once rolled over a button, the sound must start looping (as I wrote in 1.) AND the knife should slowly go backwards (MC). BUT when I roll mouse away, the sound fades away (as in 1. again) PLUS the knife should slowly move back to its place in stead of just jump from one place to another.

View 1 Replies

ActionScript 3.0 :: WAV File - New Sound.extract() Function To Get Two Seconds Of A Sound Into A ByteArray

Nov 11, 2009

I'm having some trouble getting the following code to work - trying to use the new Sound.extract() function to get two seconds of a Sound into a ByteArray, and then create a new bytearray with a WAV header, and then output the file. The resulting 'test.wav' file sounds very wrong although slightly recognisable? I think I may have some of the WAV header settings may be wrong but I'm not quite sure what's the matter and after a long time scratching

[Code]...

View 5 Replies

ActionScript 2.0 :: Sound Visualizations - Dynamically Read The Sound Levels Of A Loaded MP3

Jan 14, 2005

Does anyone know of a way to dynamically read the sound levels of a loaded MP3 to help produce dynamic sound visualization in Flash?

View 5 Replies

ActionScript 1/2 :: Sound Control Adding Text Into The Linkage Field But Still Sound Doesn't Work

Jan 21, 2010

How to import sound with AS? Cuz i have tried it and my sound just wount play. Can you explain me where my sound should be and what is the as code for importing cuz i use

mysound = new Sound();
mysound.attachSound("SoundOn");
mysound.start();

and this SoundON from where i get it, i try to add linkage to the sound file but in CS4 i cant find the option;. I do it from the library, adding text into the linkage field but still my sound doesn't want to play?

View 15 Replies

Professional :: Loading With Sound Only Played Once But Keeping Hover Over Menu Item Sound Intack?

May 21, 2010

I have a flash header that was never completed because the guy I hired took people's money and ran. So now I even wonder if what he said could work with my flash header is true or not. But, usually there is always a way to make it work.I have a flash header that does two important things: 1) Upon entering the site, it loads and plays an audio track 2) Makes an animal noise when you hover over each animal menu item. (not sure if I'm able to give a link to it or not on here. If I able to and someone would like to see it let me know)I want to know if my flash header can support the following addionalunctionality/changes:1) Currently, it loads everytime a page is selected.  I only want it to load the one time of entering the site because the audio gets annoying.  Set a cookie maybe?2) But, I do not want to turn the audio off completely because I still want the hover over each menu item sound.

3) Have a link on it to allow them to select to turn on / off the sound completely. It currently has that, but only for the current page. Once you select another page, the audio is back to on.4) Lastlly, is there a way for it to detect that someone doesn't support flash and to display an html version of it? And can flash create a html version from my fla file?I don't know much about flash (but am learning) so I'm not sure if I'll be able to do this myself. However, I want to find out if my flash header will even work this way before I invest the time learning it just for these changes. I know it will be pretty deep with script code, but I'm hoping I could find base code already available for these features.

View 2 Replies

Actionscript 3 :: HTML: Start Sound Playback From URL Mid-file Without Buffering All Sound Data To That Point?

Nov 21, 2010

I have a long mp3 file hosted on a standard apache server (30 minutes long so far, but I would like it to work with longer sounds too).I'd like to start playback of this audio within at a specified point. When attempting to use Flash Actionscript 3, my basic tests show that ALL the audio from the start to the position I choose is buffered before playback (Sound.bytesLoaded was my friend here). If I start one second in, it takes about 3 seconds to start playback, 30 seconds in, takes about 25 secondsObviously with a really long mp3, like skipping playback to the middle of a 3-hour audiobook, this isn't going to be practical.Here's the ActionScript 3.0 code I'm using:

button.addEventListener(MouseEvent.MOUSE_DOWN, function():void {
var s:Sound = new Sound();
var req:URLRequest = new URLRequest("http://example.com/audio.mp3");

[code].....

View 1 Replies

ActionScript 2.0 :: F8 - Attach Sound Object To A Separate Mc To Control Independently From All Other Sound / Root Volumes

Mar 15, 2008

I have been at this for about 19 hours straight! I am going to go to bed immediately after this post, but for crying out loud, I have NEVER had this problem before today! Before anyone reads ahead and says 'you have to attach your sound object to a completely separate mc to be able to control it independently from all other sound/root volumes.' see if the following code accomplishes just that:

[Code]...

View 2 Replies

Media Server :: Send Sound With Stream (both Sound And Mic Audio)?

Oct 6, 2011

I have a broadcasting project that I've got where the host of the show can have multiple sound effects they can use on their show.I'm wondering if the only way to go about this is for all the clients listening to the show need to download the mp3 of that sound effect or if the sound effect could come from the host ...like combining his mic (for his voice) but also straight audio (the sound effect) into the stream.

View 1 Replies

Actionscript 3 :: Mute The Sound And Still Get Sound Data From SoundMixer.computeSpectrum?

Jun 25, 2011

I wrote something to capture sound from my microphone. I can visualise the sound data with SoundMixer.computeSpectrum.is there a way to mute the sound and still get sound data from SoundMixer.computeSpectrum?Now I have this:

sc=son.play();
var t:SoundTransform = new SoundTransform(0, 0);
sc.soundTransform = t;

but I do not get any data. if I pump up the volume, data comes through again(I need to mute it because it will echo otherwise).

View 1 Replies

ActionScript 3.0 :: Create Dynamic Sound To Play Sound-file?

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







Copyrights 2005-15 www.BigResource.com, All rights reserved