From 25cca44b6b723fca88ed89d8801dbd904eba81fc Mon Sep 17 00:00:00 2001 From: Gwilym Kuiper Date: Sun, 3 Oct 2021 23:26:02 +0100 Subject: [PATCH] Cargo fmt --- agb/src/sound/mixer/sw_mixer.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/agb/src/sound/mixer/sw_mixer.rs b/agb/src/sound/mixer/sw_mixer.rs index ed58eb51..408eb230 100644 --- a/agb/src/sound/mixer/sw_mixer.rs +++ b/agb/src/sound/mixer/sw_mixer.rs @@ -136,7 +136,8 @@ impl MixerBuffer { let right_amount = ((channel.panning + 1) / 2) * channel.volume; let left_amount = ((-channel.panning + 1) / 2) * channel.volume; - if (channel.pos + channel.playback_speed * SOUND_BUFFER_SIZE).floor() >= channel.data.len() + if (channel.pos + channel.playback_speed * SOUND_BUFFER_SIZE).floor() + >= channel.data.len() { // TODO: This should probably play what's left rather than skip the last bit if channel.should_loop {