[asterisk-users] .GSM -> .WAV (or ,MP3) Conversion

Arjan Kroon | Mobillion Arjan.Kroon at mobillion.nl
Tue Apr 14 07:35:14 CDT 2009


Hey,

I record the message in ULAW
exten => s,1,Record(${A_record}:ulaw,0,60)

After that I call sox with this command:
/usr/bin/sox -c 1 -1 -t ul -r 8000 $in_fl -t wav -2 -r 8000 -c 1
$wav_fl

Regards,

Arjan Kroon
Mobillion BV

-----Oorspronkelijk bericht-----
Van: asterisk-users-bounces at lists.digium.com
[mailto:asterisk-users-bounces at lists.digium.com] Namens Tim Dobson
Verzonden: 14-04-2009 13:39
Aan: asterisk-users at lists.digium.com
Onderwerp: [asterisk-users] .GSM -> .WAV (or ,MP3) Conversion

Hey there,

I'm trying to convert some call recordings from asterisk we have in .gsm

format to something I can pipe through ffmpeg - wav would be good, mp3 
would be amazing!

I've been trying playing with sox but I don't seem to be getting too far

with
1239101491.30.gsm -ql -r 64000 -t wav 1239101491.30.conv.wav resample
as ffmpeg borks at it:

tim at freee-meee:~/dmc/call recordings$ ffmpeg -i 1239101491.30.conv.wav 
1239101491.30.conv.mp3
FFmpeg version r11872+debian_3:0.svn20080206-12ubuntu3.1, Copyright (c) 
2000-2008 Fabrice Bellard, et al.
   configuration: --enable-gpl --enable-pp --enable-swscaler 
--enable-x11grab --prefix=/usr --enable-libgsm --enable-libtheora 
--enable-libvorbis --enable-pthreads --disable-strip --enable-libfaad 
--enable-libfaadbin --enable-liba52 --enable-liba52bin 
--enable-libdc1394 --disable-armv5te --disable-armv6 --disable-altivec 
--disable-vis --enable-shared --disable-static
   libavutil version: 49.6.0
   libavcodec version: 51.50.0
   libavformat version: 52.7.0
   libavdevice version: 52.0.0
   built on Mar 13 2009 17:48:10, gcc: 4.3.2
Input #0, wav, from '1239101491.30.conv.wav':
   Duration: 00:00:06.7, bitrate: 1040 kb/s
     Stream #0.0: Audio: libgsm_ms, 640000 Hz, mono, 1040 kb/s
File '1239101491.30.conv.mp3' already exists. Overwrite ? [y/N] y
Output #0, mp2, to '1239101491.30.conv.mp3':
     Stream #0.0: Audio: mp2, 640000 Hz, mono, 64 kb/s
Stream mapping:
   Stream #0.0 -> #0.0
[mp2 @ 0xb7d352f0]Sampling rate 640000 is not allowed in mp2
Error while opening codec for output stream #0.0 - maybe incorrect 
parameters such as bit_rate, rate, width or height
tim at freee-meee:~/dmc/call recordings$

Has anyone got any suggestions based on previous experience?


www.tdobson.net
----
If each of us have one object, and we exchange them, then each of us
still has one object.
If each of us have one idea, and we exchange them, then each of us now
has two ideas.   -  George Bernard Shaw

_______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users



More information about the asterisk-users mailing list