[speex-dev] Bitrate in encoder

Jean-Marc Valin jean-marc.valin at hermes.usherb.ca
Wed Nov 20 12:07:30 PST 2002


> speex_encoder_ctl(globals->enc_state,SPEEX_GET_BITRATE, &bitrate);
> 
> Seems to set bitrate to 24600 no matter what the qualitysetting is.. The
> functions used previous to this call is:

Did you make sure it really *sets* and not just return an incorrect
result?

> speex_bits_init(&globals->bits);
> globals->enc_state = speex_encoder_init(&speex_nb_mode);
> speex_encoder_ctl(globals->enc_state,SPEEX_SET_COMPLEXITY,..);
> speex_encoder_ctl(globals->enc_state,SPEEX_SET_QUALITY, ..);
> speex_encoder_ctl(globals->enc_state,SPEEX_GET_BITRATE, &bitrate);
> 
> The last line always sets the bitrate to 24600.. Why? In my previous
> installation of libspeex I had the same problem, but then bitrate was
> always set to 15000.. Is this a bug or am I doing something wrong?

Can you send the real code (without ".."). I don't see what the problem
may be so I suspect it might be a problem (in Speex or your code)
happening in other lines and which only appears at the line you mention.

        Jean-Marc


-- 
Jean-Marc Valin, M.Sc.A.
LABORIUS (http://www.gel.usherb.ca/laborius)
Université de Sherbrooke, Québec, Canada


-------------- 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/20021120/60dfe341/signature.pgp


More information about the Speex-dev mailing list