diff --git a/agb/src/sound/mixer/sw_mixer.rs b/agb/src/sound/mixer/sw_mixer.rs index f44026bc..333c4550 100644 --- a/agb/src/sound/mixer/sw_mixer.rs +++ b/agb/src/sound/mixer/sw_mixer.rs @@ -146,7 +146,7 @@ impl MixerBuffer { unsafe { agb_rs__mixer_add( - channel.data.as_ptr().offset(channel.pos.floor() as isize), + channel.data.as_ptr().add(channel.pos.floor()), buffer.as_mut_ptr(), channel.playback_speed, left_amount,