[Freeswitch-users] More codec playback issues

Brian Wood bwood-lists at jacosoft.com
Thu Nov 6 12:34:13 PST 2008


Brian West wrote:
> You turn on inbound late negotiation and make the decision in the  
> dialplan.
>   
But I'm trying to do this on outbound/originate sessions. So nothing's 
going through the dialplan. :) I'm initiating the script with originate 
commands, from the CLI or XML-RPC.

> We fixed the error in the GSM codec earlier this week.  Not sure that  
> sox will create the right file format for G722.  I might be wrong!
>
>   

I'm also not sure if SOX is producing a valid file. I also tried using 
the ITU's ansi-c encoder with the same result, but I'm not completely 
convinced it works either. I was trying to see if I could make 
FreeSWITCH record and play back in various codecs, so I would have a 
known/good file to try to decode with SOX and the ITU's code.


I also tried changing the filename in my script to /tmp/recording. I've 
seen the auto extension select work for playback. If I don't specify an 
extension when recording, it throws an error about the file format being 
invalid. If I record as /tmp/recoding.G722 and playback as 
/tmp/recording, it auto-selects the .G722 codec because that's what my 
phone is using, but the playback is garbled.


So, I guess the better question for me to ask... is specifying a 
extension to session.recordFile() the correct way to force recording in 
a specifc codec (if, for some reason you _really_ want to do this)? OR, 
is that just not supported and why I get garbled playback? .gsm and .wav 
seem to work, and a hexdump of the files looks sane, so why not the others?




More information about the FreeSWITCH-users mailing list