[Clam-devel] SetHop / SetSize
dirk.griffioen at barcelonamedia.org
Fri Aug 28 08:26:31 PDT 2009
I have a small question regarding a Processing's SetHop / SetSize functions.
For the BufferDelayPrediction I set these according to what a user fills
in in the config menu (the default is '1024'), analog to
Internally this translates to:
unsigned bufSize = mConfig.GetBufferSize();
AudioInBuffer* inBuf = new AudioInBuffer( "Input", this );
inBuf->SetSize( bufSize );
inBuf->SetHop( bufSize );
Strangely enough, when bufSize is '1024', it takes forever for the
processing's Do() to get called, I think because the buffer is really
large: much larger than '1024'. If I change the buffersize to '1' things
really speed up ... and I get the impression Do() is called on the same
timing as the other Do()'s (which is what I want).
I do not understand: I could not find for instance that the value given
to SetSize is used as a factor (nor would I expect this).
Can someone help me here?
Btw AudioStream2Buffer has:
// _in.SetSize( _config.GetBufferSize() );
_in.SetSize( _hopSize );
so buffersize = hopsize - why would this be?
More information about the clam-devel