mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-23 08:44:04 +02:00
Web: Fix an error where the buffer size is incorrectly calculated.
Public issue https://github.com/mackron/miniaudio/issues/773
This commit is contained in:
@@ -39823,6 +39823,10 @@ static ma_uint32 ma_calculate_period_size_in_frames_from_descriptor__webaudio(co
|
|||||||
*/
|
*/
|
||||||
ma_uint32 periodSizeInFrames;
|
ma_uint32 periodSizeInFrames;
|
||||||
|
|
||||||
|
if (nativeSampleRate == 0) {
|
||||||
|
nativeSampleRate = MA_DEFAULT_SAMPLE_RATE;
|
||||||
|
}
|
||||||
|
|
||||||
if (pDescriptor->periodSizeInFrames == 0) {
|
if (pDescriptor->periodSizeInFrames == 0) {
|
||||||
if (pDescriptor->periodSizeInMilliseconds == 0) {
|
if (pDescriptor->periodSizeInMilliseconds == 0) {
|
||||||
if (performanceProfile == ma_performance_profile_low_latency) {
|
if (performanceProfile == ma_performance_profile_low_latency) {
|
||||||
|
|||||||
Reference in New Issue
Block a user