Fix mixer bug when reaching end of source;
@@ -123,7 +123,8 @@ static void onPlayback(ma_device* device, void* out, const void* in, uint32_t co
} else {
source->offset = 0;
source->playing = false;
- memset(src + framesConverted * channels, 0, framesToConvert * channels * sizeof(float));
+ memset(aux + framesConverted * channels, 0, framesToConvert * channels * sizeof(float));
+ src = aux;
break;
}
}
