fix: section sub-track MIDI default program 0 loads MAIN SoundFont
Line 10393 defaulted program to 0 when subTrack.instrumentProgram was undefined (section clone with no instrument). _playNoteFluid receives program=0, calls program_change(ch,0) on FluidSynth, which picks program 0 from whatever SoundFont is loaded (MAIN session's SF). Fix: pass undefined -> _playNoteFluid takes oscillator fallback, no SoundFont loading.
This commit is contained in:
@@ -10390,7 +10390,7 @@ const App = () => {
|
||||
// Only play if the note starts inside the Section item bounds and hasn't finished yet
|
||||
if (noteStartMain >= secStart && noteStartMain < secEnd && offsetTime < noteEndMain) {
|
||||
const notePlayEndMain = Math.min(noteEndMain, secEnd);
|
||||
const program = subTrack.instrumentProgram !== undefined ? subTrack.instrumentProgram : 0;
|
||||
const program = subTrack.instrumentProgram;
|
||||
var subCh = window.SonicPianoRoll ? window.SonicPianoRoll.getTrackMidiChannel(subTrack, secTracks) : (subTrack.midiChannel !== undefined ? subTrack.midiChannel : (subIdx % 16));
|
||||
|
||||
if (offsetTime < noteStartMain) {
|
||||
|
||||
Reference in New Issue
Block a user