From 9da8df1b9f185960348dddc321e901ea74302e37 Mon Sep 17 00:00:00 2001 From: HeroesOfBalkan Date: Mon, 13 Jan 2025 12:43:06 +0100 Subject: [PATCH] Add explicit casts to suppress -Wfloat-conversion warnings --- miniaudio.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/miniaudio.h b/miniaudio.h index 02d5016a..92b17cd1 100644 --- a/miniaudio.h +++ b/miniaudio.h @@ -57826,7 +57826,7 @@ MA_API ma_result ma_data_source_seek_seconds(ma_data_source* pDataSource, float } /* We need PCM frames instead of seconds */ - frameCount = secondCount * sampleRate; + frameCount = (ma_uint64)(secondCount * sampleRate); result = ma_data_source_seek_pcm_frames(pDataSource, frameCount, &framesSeeked); @@ -57851,7 +57851,7 @@ MA_API ma_result ma_data_source_seek_to_second(ma_data_source* pDataSource, floa } /* We need PCM frames instead of seconds */ - frameIndex = secondIndex * sampleRate; + frameIndex = (ma_uint64)(secondIndex * sampleRate); return ma_data_source_seek_to_pcm_frame(pDataSource, frameIndex); } @@ -77470,7 +77470,7 @@ MA_API ma_result ma_sound_seek_to_second(ma_sound* pSound, float secondIndex) } /* We need PCM frames. We need to convert first */ - frameIndex = secondIndex * sampleRate; + frameIndex = (ma_uint64)(secondIndex * sampleRate); return ma_sound_seek_to_pcm_frame(pSound, frameIndex); }