[Speex-dev] Decoding multiple frames
yenda
yendovy.konference at seznam.cz
Thu Mar 4 10:18:58 PST 2010
Dne 27.2.2010 14:41, Peter Kirk napsal(a):
>> However, when I receive the encoded chunk at the decoder side, I don't know
>> how large the output buffer should be since the DTX and VAD is turned on
> I don't think either DTX or VAD should change the output size, only the input
> size (from the decoders perspective) will change. So, if you know you are
> sending 1/4 of a second of sound every time and you are using wide-band speex
> (16kHz) on 16bit sound data, that gives you 1/4 * 16000 * 2 = 8000 bytes of
> output data...
Hi Peter,
thanks for your reply and apologies for my delay. You are absolutely
right, from the perspective of decoder, the input is of a different size
and the output size is in multiples of frame size. The main problem is
that I have not the guarantee of constant length of input of the
decoder. It is about 250ms, but the size varies quite a lot. So, the
question is:
when I encode the whole input chunk of audio data to speex data,
is it possible on the decoder side, having only the encoded speex data,
to infer how large buffer shall I prepare for the decoder? Or is it
necessary to send the number of encoded frames together with the data?
Best regards,
Yenda
More information about the Speex-dev
mailing list