mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-22 00:06:59 +02:00
Fix a bug with engine nodes.
This bug results in an audio glitch when mixing nodes in the node graph. It specifically happens when resampling is not being performed, in which case it was specifying an output frame count greater than the number of frames that are actually being output. Public issue https://github.com/mackron/miniaudio/issues/408
This commit is contained in:
+2
-2
@@ -70679,8 +70679,8 @@ static void ma_engine_node_process_pcm_frames__general(ma_engine_node* pEngineNo
|
|||||||
framesJustProcessedIn = (ma_uint32)resampleFrameCountIn;
|
framesJustProcessedIn = (ma_uint32)resampleFrameCountIn;
|
||||||
framesJustProcessedOut = (ma_uint32)resampleFrameCountOut;
|
framesJustProcessedOut = (ma_uint32)resampleFrameCountOut;
|
||||||
} else {
|
} else {
|
||||||
framesJustProcessedIn = framesAvailableIn;
|
framesJustProcessedIn = ma_min(framesAvailableIn, framesAvailableOut);
|
||||||
framesJustProcessedOut = framesAvailableOut;
|
framesJustProcessedOut = framesJustProcessedIn; /* When no resampling is being performed, the number of output frames is the same as input frames. */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Fading. */
|
/* Fading. */
|
||||||
|
|||||||
Reference in New Issue
Block a user