[Speex-dev] Speex and DS

Thorvald Natvig speex at natvig.com
Thu Jun 23 04:16:15 PDT 2005

> What I really am focusing right now on is to get the same sound out that went 
> into the speex codec.

Are you calling speex_encoder_init() for each frame? If so, that's 
probably your problem as speex uses overlapping frames. If I understood 
the discussion earlier right, the first frame will actually be only half 
the size, so you'd get very choppy output (basically all frames would be 
only half full).

You need to call speex_encoder_init() (and likewise for decoder_init()) 
once, then use the same encoder/decoder state for all the frames.

BTW: You probably want to make frame_size a variable and call
to get the actual frame size. That way it's easier to change to wideband 
and ultrawideband later :)

More information about the Speex-dev mailing list