Fix ring buffer handling in pa_mac_core.c that caused many spurious paInputOverflow flags.
Fixed size bug when input underflow detected. Code was confused between bytes and elements. Zero out the beginning of a recording when detecting pops to prevent start of audio from looking like a pop in qa loopback test.
This commit is contained in:
parent
44bdc45b2a
commit
b4a22b91ff
4 changed files with 55 additions and 42 deletions
|
|
@ -514,9 +514,15 @@ void PaQa_FadeInRecording( PaQaRecording *recording, int startFrame, int count )
|
|||
|
||||
assert( startFrame >= 0 );
|
||||
assert( count > 0 );
|
||||
|
||||
for( is=0; is<count; is++ )
|
||||
|
||||
/* Zero out initial part of the recording. */
|
||||
for( is=0; is<startFrame; is++ )
|
||||
{
|
||||
recording->buffer[ is ] = 0.0f;
|
||||
}
|
||||
/* Fade in where signal begins. */
|
||||
for( is=0; is<count; is++ )
|
||||
{
|
||||
double c = cos( phase );
|
||||
double w = c * c;
|
||||
float x = recording->buffer[ is + startFrame ];
|
||||
|
|
|
|||
Loading…
Reference in a new issue