[Speex-dev] SpeexBits Questions

Matt DeMoss mdemoss at uark.edu
Mon Jun 6 12:14:55 PDT 2005


Thanks, it makes more sense to me now. Does speex_bit_read_from also 
append in that manner?

Jean-Marc Valin wrote:

> speex_bits_reset is before encoding, not decoding. If you don't call it,
> then everything you encode will be appended so it will grow without end.
> As for the point of the SpeexBits struct, it's there as a sort of "array
> of bits" to it's easy to pack and unpack bits.
>
>     Jean-Marc
>
> Le lundi 06 juin 2005 à 13:54 -0500, Matt DeMoss a écrit :
>  
>
>> The example in the documentation demonstrates using speex_bits_reset 
>> before encoding and decoding each frame.
>>
>> "
>> speex_bits_reset(&bits);
>>
>> speex_encode(enc_state, input_frame, &bits);
>>
>> nbBytes = speex_bits_write(&bits, byte_ptr, MAX_NB_BYTES);
>> "
>>
>> What happens if this is not done? I think I'm missing the point of 
>> having a SpeexBits object.
>>
>>
>> _______________________________________________
>> Speex-dev mailing list
>> Speex-dev at xiph.org
>> http://lists.xiph.org/mailman/listinfo/speex-dev
>>   
>
>
>  
>




More information about the Speex-dev mailing list