Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-30 Thread Leo Burd

- thanks so much for all the feedback provided!

I believe now I've collected all (or most) of the pieces that I needed for 
my little system!


As for the sorenson format issue, I believe ffmpeg can take care of that... 
(hopefully)


Best,

Leo

- Original Message - 
From: Janis Radins [EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Wednesday, November 29, 2006 1:04 PM
Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?


btw, not long time ago i heard some person on efnet #actionscript 
complaning
that FMS and red5 are saving FLV's encoded with sorensen which he claimed 
is

unconvertable to any alternative format.

2006/11/29, Robert r. Sanders [EMAIL PROTECTED]:


Ah, ok, that makes things clearer.

First, look at RED5 - http://osflash.org/red5  You'd have to record to
FLV and then run a second program to parse out the audio, but it could
be done.

Second, the blog entry I was thinking of is
http://www.flashcodersbrighton.org/wordpress/?p=9  it might contain
useful code if you wanted to try and convert the audio inside of flash.


Leo Burd wrote:
 Hello Robert,

 Thanks so much for your message!

 My problem is creating an MP3 file out of a Sound object, not the
 other way around... do you have any suggestions on how to do that?

 Best,

 Leo

 - Original Message - From: Robert r. Sanders
 [EMAIL PROTECTED]
 To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
 Sent: Tuesday, November 28, 2006 9:36 PM
 Subject: Re: [Flashcoders] How to send Audio objects as MP3 via 
 XML-RPC?



 My understanding is that there is no way to create a Sound object
 other than by embedding it or using a streaming server (see Red5).

 However, some enterprising individuals have realized that in AS3 you
 can dynamically create objects (e.g. reflection) and thus if you
 really want to you could programmatically 'generate' sound.
 Depending on your use case it is probably much easier to use a
 streaming server.
 As an aside the use case I had for programmatic generation of a Sound
 object was the idea that the Speex algorithm (an open codec for human
 voice encoding) might be a possibility in AS3, alas it looks like it
 would be a major undertaking.


 Leo Burd wrote:
 Hello there,

 I am new to Flash and I am wondering what is the best way to send
 Audio objects via XML-RPC.  More specifically, I wonder if anyone
 could send me suggestions on:

 a) How to convert a Sound object to MP3 programatically?
 b) How to convert the resulting MP3 into a base64 string
 c) How to send the base64 string to my server via XML-RPC

 BTW, shall I use AS2 or AS3 for this?

 Thanks in advance,

 Leo

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com

--
Robert r. Sanders
Chief Technologist
iPOV
(334) 821-5412
www.ipov.net

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com



___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-30 Thread Martin Wood-Mitrovski



Leo Burd wrote:

- thanks so much for all the feedback provided!

I believe now I've collected all (or most) of the pieces that I needed 
for my little system!


As for the sorenson format issue, I believe ffmpeg can take care of 
that... (hopefully)


the video is sorenson, but the audio is nellymoser. Im pretty sure that there 
are currently no free converters for nellymoser.


If you want to record audio from flash via the mic and convert it into a 
'usable' format you'll have to pay nellymoser for their transcoder.


From what ive read (on the flashcomm list) its in the region of $8k

If you do find a way to convert .flv audio to something else for free, please 
let me know :)


thanks,

Martin

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-29 Thread Leo Burd

Dear John,

Thanks so much for your message!

As you said, ffmpeg is a command line solution. Is there any way to generate 
a .flv file programmatically with an embedded Sound object in it?


Thanks once again,

Leo

- Original Message - 
From: Jon Bradley [EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Tuesday, November 28, 2006 8:31 AM
Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?




On Nov 28, 2006, at 5:29 AM, Leo Burd wrote:


Hello there,

I am new to Flash and I am wondering what is the best way to send  Audio 
objects via XML-RPC.  More specifically, I wonder if anyone  could send 
me suggestions on:


a) How to convert a Sound object to MP3 programatically?


You need an MP3 encoding library. If you want a command line solution 
that you may be able to hack to work in a server environment, I'd  look 
into ffmpeg.



b) How to convert the resulting MP3 into a base64 string


PHP has a base64 library. Look there for starters. I believe you can  pass 
it an argument to encode a file (which would be the mp3 file on  your 
server).


To encode the MP3 into a base64 string dynamically is going to kill  your 
server CPU. You're better off running a chron job on your server  to 
execute PHP code to encode the file when placed in a certain  directory. 
If the base64 version is already encoded, don't do  anything, just send 
the stored encoded version.



c) How to send the base64 string to my server via XML-RPC


I don't know if XML-RPC is not going to handle that amount of data  very 
effectively. The base64 encoded version of the MP3 file will be  huge.



BTW, shall I use AS2 or AS3 for this?


I don't know if it will matter. Once you have the base64 encoded  string 
in Flash, what do you plan to do with it? I don't see how  you'll be able 
to attach it to a sound object. I never tried this  though, so the sound 
object should be able to take the raw mp3 data  and use it, but who 
know?


This whole process may be best done with a socket connection with AS3  and 
using binary data to send the result directly to a sound object.


good luck.

jon
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com



___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-29 Thread Leo Burd

Hello Robert,

Thanks so much for your message!

My problem is creating an MP3 file out of a Sound object, not the other way 
around... do you have any suggestions on how to do that?


Best,

Leo

- Original Message - 
From: Robert r. Sanders [EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Tuesday, November 28, 2006 9:36 PM
Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?


My understanding is that there is no way to create a Sound object other 
than by embedding it or using a streaming server (see Red5).


However, some enterprising individuals have realized that in AS3 you can 
dynamically create objects (e.g. reflection) and thus if you really want 
to you could programmatically 'generate' sound.
Depending on your use case it is probably much easier to use a streaming 
server.
As an aside the use case I had for programmatic generation of a Sound 
object was the idea that the Speex algorithm (an open codec for human 
voice encoding) might be a possibility in AS3, alas it looks like it would 
be a major undertaking.



Leo Burd wrote:

Hello there,

I am new to Flash and I am wondering what is the best way to send Audio 
objects via XML-RPC.  More specifically, I wonder if anyone could send me 
suggestions on:


a) How to convert a Sound object to MP3 programatically?
b) How to convert the resulting MP3 into a base64 string
c) How to send the base64 string to my server via XML-RPC

BTW, shall I use AS2 or AS3 for this?

Thanks in advance,

Leo

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com



___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-29 Thread Janis Radins

Where are you getting your sound object from?

2006/11/29, Leo Burd [EMAIL PROTECTED]:


Hello Robert,

Thanks so much for your message!

My problem is creating an MP3 file out of a Sound object, not the other
way
around... do you have any suggestions on how to do that?

Best,

Leo

- Original Message -
From: Robert r. Sanders [EMAIL PROTECTED]
To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Tuesday, November 28, 2006 9:36 PM
Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?


 My understanding is that there is no way to create a Sound object
other
 than by embedding it or using a streaming server (see Red5).

 However, some enterprising individuals have realized that in AS3 you can
 dynamically create objects (e.g. reflection) and thus if you really want
 to you could programmatically 'generate' sound.
 Depending on your use case it is probably much easier to use a streaming
 server.
 As an aside the use case I had for programmatic generation of a Sound
 object was the idea that the Speex algorithm (an open codec for human
 voice encoding) might be a possibility in AS3, alas it looks like it
would
 be a major undertaking.


 Leo Burd wrote:
 Hello there,

 I am new to Flash and I am wondering what is the best way to send Audio
 objects via XML-RPC.  More specifically, I wonder if anyone could send
me
 suggestions on:

 a) How to convert a Sound object to MP3 programatically?
 b) How to convert the resulting MP3 into a base64 string
 c) How to send the base64 string to my server via XML-RPC

 BTW, shall I use AS2 or AS3 for this?

 Thanks in advance,

 Leo

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com
 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-29 Thread Leo Burd

- From a microphone input...

.L.

- Original Message - 
From: Janis Radins [EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Wednesday, November 29, 2006 10:34 AM
Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?



Where are you getting your sound object from?

2006/11/29, Leo Burd [EMAIL PROTECTED]:


Hello Robert,

Thanks so much for your message!

My problem is creating an MP3 file out of a Sound object, not the other
way
around... do you have any suggestions on how to do that?

Best,

Leo

- Original Message -
From: Robert r. Sanders [EMAIL PROTECTED]
To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Tuesday, November 28, 2006 9:36 PM
Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?


 My understanding is that there is no way to create a Sound object
other
 than by embedding it or using a streaming server (see Red5).

 However, some enterprising individuals have realized that in AS3 you 
 can
 dynamically create objects (e.g. reflection) and thus if you really 
 want

 to you could programmatically 'generate' sound.
 Depending on your use case it is probably much easier to use a 
 streaming

 server.
 As an aside the use case I had for programmatic generation of a Sound
 object was the idea that the Speex algorithm (an open codec for human
 voice encoding) might be a possibility in AS3, alas it looks like it
would
 be a major undertaking.


 Leo Burd wrote:
 Hello there,

 I am new to Flash and I am wondering what is the best way to send 
 Audio

 objects via XML-RPC.  More specifically, I wonder if anyone could send
me
 suggestions on:

 a) How to convert a Sound object to MP3 programatically?
 b) How to convert the resulting MP3 into a base64 string
 c) How to send the base64 string to my server via XML-RPC

 BTW, shall I use AS2 or AS3 for this?

 Thanks in advance,

 Leo

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com
 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com



___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-29 Thread Janis Radins

in that case you got everything wrong, microphone attached to sound object
provides only playback of current sound.
no recording or anything like that.
only way imo is to use FMS or Red5 to send stream serverside and only then
encode it as you need.
thats the only alternative as far as i know.
though i'm not sure about AS3 maybe there are some new features that might
help to do this.
but still sending sound stream sounds a lot more efficient to me than
encoding sound into stream client side, then send string to serverside and
encode it back to sound there.

2006/11/29, Leo Burd [EMAIL PROTECTED]:


- From a microphone input...

.L.

- Original Message -
From: Janis Radins [EMAIL PROTECTED]
To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Wednesday, November 29, 2006 10:34 AM
Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?


 Where are you getting your sound object from?

 2006/11/29, Leo Burd [EMAIL PROTECTED]:

 Hello Robert,

 Thanks so much for your message!

 My problem is creating an MP3 file out of a Sound object, not the other
 way
 around... do you have any suggestions on how to do that?

 Best,

 Leo

 - Original Message -
 From: Robert r. Sanders [EMAIL PROTECTED]
 To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
 Sent: Tuesday, November 28, 2006 9:36 PM
 Subject: Re: [Flashcoders] How to send Audio objects as MP3 via
XML-RPC?


  My understanding is that there is no way to create a Sound object
 other
  than by embedding it or using a streaming server (see Red5).
 
  However, some enterprising individuals have realized that in AS3 you
  can
  dynamically create objects (e.g. reflection) and thus if you really
  want
  to you could programmatically 'generate' sound.
  Depending on your use case it is probably much easier to use a
  streaming
  server.
  As an aside the use case I had for programmatic generation of a Sound
  object was the idea that the Speex algorithm (an open codec for human
  voice encoding) might be a possibility in AS3, alas it looks like it
 would
  be a major undertaking.
 
 
  Leo Burd wrote:
  Hello there,
 
  I am new to Flash and I am wondering what is the best way to send
  Audio
  objects via XML-RPC.  More specifically, I wonder if anyone could
send
 me
  suggestions on:
 
  a) How to convert a Sound object to MP3 programatically?
  b) How to convert the resulting MP3 into a base64 string
  c) How to send the base64 string to my server via XML-RPC
 
  BTW, shall I use AS2 or AS3 for this?
 
  Thanks in advance,
 
  Leo
 
  ___
  Flashcoders@chattyfig.figleaf.com
  To change your subscription options or search the archive:
  http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
 
  Brought to you by Fig Leaf Software
  Premier Authorized Adobe Consulting and Training
  http://www.figleaf.com
  http://training.figleaf.com
  ___
  Flashcoders@chattyfig.figleaf.com
  To change your subscription options or search the archive:
  http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
 
  Brought to you by Fig Leaf Software
  Premier Authorized Adobe Consulting and Training
  http://www.figleaf.com
  http://training.figleaf.com
 

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-29 Thread Robert r. Sanders

Ah, ok, that makes things clearer.

First, look at RED5 - http://osflash.org/red5  You'd have to record to 
FLV and then run a second program to parse out the audio, but it could 
be done.


Second, the blog entry I was thinking of is 
http://www.flashcodersbrighton.org/wordpress/?p=9  it might contain 
useful code if you wanted to try and convert the audio inside of flash.



Leo Burd wrote:

Hello Robert,

Thanks so much for your message!

My problem is creating an MP3 file out of a Sound object, not the 
other way around... do you have any suggestions on how to do that?


Best,

Leo

- Original Message - From: Robert r. Sanders 
[EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Tuesday, November 28, 2006 9:36 PM
Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?


My understanding is that there is no way to create a Sound object 
other than by embedding it or using a streaming server (see Red5).


However, some enterprising individuals have realized that in AS3 you 
can dynamically create objects (e.g. reflection) and thus if you 
really want to you could programmatically 'generate' sound.
Depending on your use case it is probably much easier to use a 
streaming server.
As an aside the use case I had for programmatic generation of a Sound 
object was the idea that the Speex algorithm (an open codec for human 
voice encoding) might be a possibility in AS3, alas it looks like it 
would be a major undertaking.



Leo Burd wrote:

Hello there,

I am new to Flash and I am wondering what is the best way to send 
Audio objects via XML-RPC.  More specifically, I wonder if anyone 
could send me suggestions on:


a) How to convert a Sound object to MP3 programatically?
b) How to convert the resulting MP3 into a base64 string
c) How to send the base64 string to my server via XML-RPC

BTW, shall I use AS2 or AS3 for this?

Thanks in advance,

Leo

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com 


--
   Robert r. Sanders
   Chief Technologist
   iPOV
   (334) 821-5412
   www.ipov.net

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-29 Thread Janis Radins

btw, not long time ago i heard some person on efnet #actionscript complaning
that FMS and red5 are saving FLV's encoded with sorensen which he claimed is
unconvertable to any alternative format.

2006/11/29, Robert r. Sanders [EMAIL PROTECTED]:


Ah, ok, that makes things clearer.

First, look at RED5 - http://osflash.org/red5  You'd have to record to
FLV and then run a second program to parse out the audio, but it could
be done.

Second, the blog entry I was thinking of is
http://www.flashcodersbrighton.org/wordpress/?p=9  it might contain
useful code if you wanted to try and convert the audio inside of flash.


Leo Burd wrote:
 Hello Robert,

 Thanks so much for your message!

 My problem is creating an MP3 file out of a Sound object, not the
 other way around... do you have any suggestions on how to do that?

 Best,

 Leo

 - Original Message - From: Robert r. Sanders
 [EMAIL PROTECTED]
 To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
 Sent: Tuesday, November 28, 2006 9:36 PM
 Subject: Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?


 My understanding is that there is no way to create a Sound object
 other than by embedding it or using a streaming server (see Red5).

 However, some enterprising individuals have realized that in AS3 you
 can dynamically create objects (e.g. reflection) and thus if you
 really want to you could programmatically 'generate' sound.
 Depending on your use case it is probably much easier to use a
 streaming server.
 As an aside the use case I had for programmatic generation of a Sound
 object was the idea that the Speex algorithm (an open codec for human
 voice encoding) might be a possibility in AS3, alas it looks like it
 would be a major undertaking.


 Leo Burd wrote:
 Hello there,

 I am new to Flash and I am wondering what is the best way to send
 Audio objects via XML-RPC.  More specifically, I wonder if anyone
 could send me suggestions on:

 a) How to convert a Sound object to MP3 programatically?
 b) How to convert the resulting MP3 into a base64 string
 c) How to send the base64 string to my server via XML-RPC

 BTW, shall I use AS2 or AS3 for this?

 Thanks in advance,

 Leo

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com

--
Robert r. Sanders
Chief Technologist
iPOV
(334) 821-5412
www.ipov.net

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How to send Audio objects as MP3 via XML-RPC?

2006-11-28 Thread Jon Bradley


On Nov 28, 2006, at 5:29 AM, Leo Burd wrote:


Hello there,

I am new to Flash and I am wondering what is the best way to send  
Audio objects via XML-RPC.  More specifically, I wonder if anyone  
could send me suggestions on:


a) How to convert a Sound object to MP3 programatically?


You need an MP3 encoding library. If you want a command line solution  
that you may be able to hack to work in a server environment, I'd  
look into ffmpeg.



b) How to convert the resulting MP3 into a base64 string


PHP has a base64 library. Look there for starters. I believe you can  
pass it an argument to encode a file (which would be the mp3 file on  
your server).


To encode the MP3 into a base64 string dynamically is going to kill  
your server CPU. You're better off running a chron job on your server  
to execute PHP code to encode the file when placed in a certain  
directory. If the base64 version is already encoded, don't do  
anything, just send the stored encoded version.



c) How to send the base64 string to my server via XML-RPC


I don't know if XML-RPC is not going to handle that amount of data  
very effectively. The base64 encoded version of the MP3 file will be  
huge.



BTW, shall I use AS2 or AS3 for this?


I don't know if it will matter. Once you have the base64 encoded  
string in Flash, what do you plan to do with it? I don't see how  
you'll be able to attach it to a sound object. I never tried this  
though, so the sound object should be able to take the raw mp3 data  
and use it, but who know?


This whole process may be best done with a socket connection with AS3  
and using binary data to send the result directly to a sound object.


good luck.

jon
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com