search for: writesamples

Displaying 4 results from an estimated 4 matches for "writesamples".

2010 Apr 10
2
Is Speex 1.0 and >=1.1 compatible?
...I am streaming multi frame Speex blocks over a TCP connection which works fine as long as the version of Speex is the same on both sides. When using a newer Speex (1.1.?) to encode and an older version to decode (1.0.5), it does not work. The encoder code look like this: int AudioEncoderSpeex::writeSamples(const float *samples, int count) { for (int i=0; i<count; ++i) { sample_buf[buf_len++] = samples[i] * 32767.0; if (buf_len == frame_size) { speex_encode(enc_state, sample_buf, &bits); buf_len = 0; if (++frame_cnt == 4) // Four frames per packet...
2010 Apr 11
2
Is Speex 1.0 and >=1.1 compatible?
...works > > fine as long as the version of Speex is the same on both sides. When > > using a newer Speex (1.1.?) to encode and an older version to decode > > (1.0.5), it does not work. > > > > The encoder code look like this: > > > > int AudioEncoderSpeex::writeSamples(const float *samples, int count) > > { > > > > for (int i=0; i<count; ++i) > > { > > > > sample_buf[buf_len++] = samples[i] * 32767.0; > > > > if (buf_len == frame_size) > > { > > > > s...
2010 Apr 10
0
Is Speex 1.0 and >=1.1 compatible?
...; Speex blocks over a TCP connection which works fine as long as the version of > Speex is the same on both sides. When using a newer Speex (1.1.?) to encode > and an older version to decode (1.0.5), it does not work. > > The encoder code look like this: > > int AudioEncoderSpeex::writeSamples(const float *samples, int count) > { > for (int i=0; i<count; ++i) > { > sample_buf[buf_len++] = samples[i] * 32767.0; > > if (buf_len == frame_size) > { > speex_encode(enc_state, sample_buf,&bits); > buf_len = 0; > >...
2010 Apr 11
0
Is Speex 1.0 and >=1.1 compatible?
...fine as long as the version of Speex is the same on both sides. When >>> using a newer Speex (1.1.?) to encode and an older version to decode >>> (1.0.5), it does not work. >>> >>> The encoder code look like this: >>> >>> int AudioEncoderSpeex::writeSamples(const float *samples, int count) >>> { >>> >>> for (int i=0; i<count; ++i) >>> { >>> >>> sample_buf[buf_len++] = samples[i] * 32767.0; >>> >>> if (buf_len == frame_size) >>> { >>>...