search for: m_pbuffer

Displaying 2 results from an estimated 2 matches for "m_pbuffer".

2005 Oct 09
0
Fw: problem in encoder/decoder
..._ctl(enc_state, SPEEX_SET_BITRATE, &bitrate); int tmp=1; // speex_encoder_ctl(enc_state, SPEEX_SET_VAD, &tmp); while(pos<pMsg->m_nBufferSize && encoded_bytes<pMsg->m_nBufferSize) { if((pMsg->m_nBufferSize-pos)>frame_size) { CopyMemory(input_frame,pMsg->m_pBuffer+pos,frame_size); pos += frame_size; } else { CopyMemory(input_frame,pMsg->m_pBuffer+pos,pMsg->m_nBufferSize-pos); pos+=(pMsg->m_nBufferSize-pos); } //encode input frame speex_bits_reset(&bits); speex_encode(enc_state,input_frame,&bits); nbBytes = speex_bits_write(&...
2007 Nov 14
0
Audio glitches/Configuration problem !!?
...d below. What about the lookahead size ? how shouw we apply it in encoding stage ? thanks in advance bool SpeexEncoder::EncodeData(char * inBuffer, int inSize, char * outBuffer, int outMAXSize, int* outSize) { if(!m_Initialized) return false; // Copy data into the local buffer memcpy(m_pBuffer + m_BufferSize, inBuffer, inSize); m_BufferSize += inSize; // check if we have enougth data for the encoder, if(m_BufferSize < m_FrameSizeInBytes ) return false; // start processing short* input = (short*)m_pBuffer; char* output = outBuffer; *outSize = 0;...