From ac6283f92b0579c0e820e13a83715389455d3171 Mon Sep 17 00:00:00 2001 From: Mitja Felicijan Date: Wed, 9 Oct 2024 18:32:27 +0200 Subject: Added preset to args --- synth.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'synth.c') diff --git a/synth.c b/synth.c index 05c3664..d65ba41 100644 --- a/synth.c +++ b/synth.c @@ -65,10 +65,10 @@ void *synth(void *arg) { SDL_LockMutex(g_Mutex); if (shared_data.state == 0) { - tsf_note_off(g_TinySoundFont, shared_data.preset, shared_data.note); + tsf_note_off(g_TinySoundFont, args->soundfont_preset, shared_data.note); } else { float normalized_velocity = (float)shared_data.velocity / 127.0f; - tsf_note_on(g_TinySoundFont, shared_data.preset, shared_data.note, normalized_velocity); + tsf_note_on(g_TinySoundFont, args->soundfont_preset, shared_data.note, normalized_velocity); } SDL_UnlockMutex(g_Mutex); -- cgit v1.2.3