[speex-dev] rgding VAD

Jean-Marc Valin jean-marc.valin at hermes.usherb.ca
Tue Apr 15 08:31:54 PDT 2003


>     How do i detect whether there is silence in media using speex?
>     Is there any API which decides that the audio data only contains 
> silence?
>     Basically i will have PCM linear data, I want to know whether it is 
> complete silence.

Well, the best way is probably to turn VAD *and* DTX on. Then when
there's silence, the speex_encode function will return zero, which means
you don't have to transmit the frame (normally, it returns 1).

>     Is it that during encoding speex_bits_write will return a lesser 
> number if the audio at byte_ptr contains silence?

You could do it that way but you may run into problems at low bit-rate
VBR modes, where the same mode can be used for silence or low-volume
speech.

        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: 190 bytes
Desc: Ceci est une partie de message numériquement signée
Url : http://lists.xiph.org/pipermail/speex-dev/attachments/20030415/ffbda525/signature.pgp


More information about the Speex-dev mailing list