Ross Finlayson
2004-Aug-06 15:01 UTC
[speex-dev] Speex SIP support in the "Asterisk" PBX, FYI
FYI, the Asterisk software PBX <http://www.asterisk.org/> has now incorporated my recent patches to support dynamic RTP payload types. As a consequence, its SIP implementation now supports Speex, so if you have a Speex-compatible SIP client, you can use it to make calls using Asterisk. Some caveats: - Only narrowband (8 kHz) Speex is currently supported; not wideband. (Unfortunately, the assumption that audio sample rate == 8 kHz is riddled throughout the Asterisk code.) - Each outgoing RTP packet (from Asterisk) contains just a single Speex frame. Similarly, each incoming RTP packet (from a client) should contain just a single Speex frame. - Some existing clients (such as "linphone") will need to be modified to use the string "speex" rather than "speex-<version-number>" in their SDP "a=rtpmap:" line. Also, FYI, my command-line SIP client "playSIP" <http://www.live.com/playSIP/> can also record - into a file - the Speex audio from a SIP call. (Unfortunately, this output file will be raw Speex data, rather than an 'ogg' format file, so "speexdec" currently can't decode it.) Ross. --- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'speex-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
Jean-Marc Valin
2004-Aug-06 15:01 UTC
[speex-dev] Speex SIP support in the "Asterisk" PBX, FYI
> - Only narrowband (8 kHz) Speex is currently supported; not > wideband. (Unfortunately, the assumption that audio sample rate == 8 kHz > is riddled throughout the Asterisk code.)Perhaps it's still possible to send wideband, while telling Asterisk it's narrowband (the bit-stream is such that you can decode a wideband frame even if you think it's narrowband).> - Some existing clients (such as "linphone") will need to be modified to > use the string "speex" rather than "speex-<version-number>" in their SDP > "a=rtpmap:" line.The latest version of Linphone had been made up-to-date with the RTP spec, so this is no longer a problem.> Also, FYI, my command-line SIP client "playSIP" > <http://www.live.com/playSIP/> can also record - into a file - the Speex > audio from a SIP call. (Unfortunately, this output file will be raw Speex > data, rather than an 'ogg' format file, so "speexdec" currently can't > decode it.)I see a potential problem here. Because Speex has multiple bit-rate, you can't just dump frames to a file and try to decode them after. You need to either use Ogg or at least encode the size of each packet so the decoder knows how long it needs to read. Jean-Marc -- Jean-Marc Valin, M.Sc.A. LABORIUS (http://www.gel.usherb.ca/laborius) Université de Sherbrooke, Québec, Canada <p> -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 242 bytes Desc: signature.asc Url : http://lists.xiph.org/pipermail/speex-dev/attachments/20030311/c8eab276/signature.pgp
Ross Finlayson
2004-Aug-06 15:01 UTC
[speex-dev] Speex SIP support in the "Asterisk" PBX, FYI
At 07:55 PM 3/11/03, Jean-Marc Valin wrote:> > - Only narrowband (8 kHz) Speex is currently supported; not > > wideband. (Unfortunately, the assumption that audio sample rate == 8 kHz > > is riddled throughout the Asterisk code.) > >Perhaps it's still possible to send wideband, while telling Asterisk >it's narrowband (the bit-stream is such that you can decode a wideband >frame even if you think it's narrowband).Unfortunately, the sampling frequency is also the RTP timestamp frequency, so if Asterisk thinks that the stream is 8 kHz, but the Speex client thinks that it's 16 kHz, then each side will probably misinterpret the RTP timestamps sent by the other side.> > Also, FYI, my command-line SIP client "playSIP" > > <http://www.live.com/playSIP/> can also record - into a file - the Speex > > audio from a SIP call. (Unfortunately, this output file will be raw Speex > > data, rather than an 'ogg' format file, so "speexdec" currently can't > > decode it.) > >I see a potential problem here. Because Speex has multiple bit-rate, you >can't just dump frames to a file and try to decode them after. You need >to either use Ogg or at least encode the size of each packet so the >decoder knows how long it needs to read.I'll probably ending up adding an option to output the data as an 'ogg' format file (just as there's currently an option to output the data as a '.mov' file). Ross Finlayson LIVE.COM <http://www.live.com/> <p><p><p>> Jean-Marc> >-- >Jean-Marc Valin, M.Sc.A. >LABORIUS (http://www.gel.usherb.ca/laborius) >Université de Sherbrooke, Québec, Canada >--- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'speex-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.