Displaying 1 result from an estimated 1 matches for "nbuffsiz".
Did you mean:
nbufsiz
2006 Sep 15
2
Constant noise in the background in realtime data
...Frame)
{
// Reset speex bits before frame encode
speex_bits_reset(&m_oBits);
int nFrameSize = 0;
speex_encoder_ctl(m_poSpeexCompressState, SPEEX_GET_FRAME_SIZE, &nFrameSize);
// Our samples are 2 bytes each so number of samples is actually
// have the buffer size
int nBuffSize = BUFFERSIZE / 2;
// Now copy the samples into the float array that we will encode
for(int i = 0; i < nBuffSize; i++)
input[i] = ( (pData[(i*2) + 1] << 8) | (pData[(i*2)] & 0xff) ) / 32768.0f;
// Provide speex with the float array pointer to compress
speex_encode...