tags:

views:

23

answers:

1

This is not a specific question, instead I'm trying to get an idea of flashes capabilities.

I'm building a website that has an Mp3 upload component on it. Serverside I can use the command line audio tool "SOX" for most of my heavy lifting but I'd like to offload some of it onto a flash client. Essentially, client side, needs to be able to do the following:

  • User selects an mp3 file off their harddrive.
  • Render it as a waveform.
  • Display a scaled indication of 30 seconds of the waveform that the user can drag backwards and forwards. This will record a start time.
  • Upload either the full mp3 or just the selected start time plus 30 seconds.

I've never programmed anything in flash before so I'm not really sure what it's capable of.

+1  A: 

It is more than capable of doing what you need.

Also, if using player 10+ ( you should anyways - only if for the better performance), you can read the file's data from the user hardrive, process it and send whatever you need (part of it modified) to the server.

There are some good audio libs floating around now, you can hack this with very little code.

Arthur Debert
Excellent, thanks for the quick answer.
Samuel
Flash is definitely capable of all the audio stuff you have in mind, but the part where you process data off the user's drive and then upload it is going to be a problem. I don't think the whole process you describe can be done in Flash (or anything browser-based), without uploading the whole file once and then accessing from the server. (An AIR application would have no trouble, though.)
fenomas
Yeah, player 10+ can do it, more info:- The announcement http://www.mikechambers.com/blog/2008/08/20/reading-and-writing-local-files-in-flash-player-10/- Oficial docs : http://help.adobe.com/en_US/AS3LCR/Flash_10.0/flash/net/FileReference.html#load()
Arthur Debert
Ah, that slipped under my radar. Nice!
fenomas