diff --git a/uisimulator/sdl/sound.c b/uisimulator/sdl/sound.c index ae9d5f9053..d23bcc8094 100644 --- a/uisimulator/sdl/sound.c +++ b/uisimulator/sdl/sound.c @@ -157,8 +157,8 @@ bool pcm_is_playing(void) void pcm_calculate_peaks(int *left, int *right) { - long samples = pcm_data_size / 4; - short *addr = pcm_data; + long samples = (long) pcm_data_size / 4; + short *addr = (short *) pcm_data; if (samples > PEAK_SAMPLES) samples = PEAK_SAMPLES; @@ -207,9 +207,6 @@ void pcm_calculate_peaks(int *left, int *right) } } -Uint8 overflow[8192]; -Uint32 overflow_amount = 0; - void sdl_audio_callback(void *udata, Uint8 *stream, int len) { Uint32 pcm_data_played, need_to_play;