Skip to main content
Participant
February 2, 2011
Question

mic record and upload

  • February 2, 2011
  • 1 reply
  • 1585 views

Hi,

I have a major problem:

I have to build an app which will have to record the mic and then automatically save the record somehow in a temporary file and then upload this file to a server.

Is this possible without using media server?

This topic has been closed for replies.

1 reply

Inspiring
February 2, 2011

yes with Flash Player 10.1

This article talks about AIR but it also applies to FP 10.1

http://www.adobe.com/devnet/air/flex/articles/using_mic_api.html

-Art

Participant
February 2, 2011

can you please give me more details about how this is possible?

i need this to happen without user interaction. after he stops the recording and press the save button i don't want the save window to appear, i want the save and upload process in the background, and for the user to see only the uploading progress...

Inspiring
February 2, 2011

Check the article.

The new microphone api

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/media/Microphone.html

Allows you to save the sample data to a Byte Array

private function gotMicData(micData:SampleDataEvent):void

{

// micData.data contains a ByteArray with our sample.

}

How you chose to send that to your server depends on what server technology you wish to use.

For example you could mime encode the byte array and upload it to a php server in a POST.

Basically the answer depends on how you wish to send that ByteArray to the server.