fix: restore program default 0 for MAIN track MIDI playback
Line 10283 defaulted to undefined when instrumentProgram undefined, breaking Play for MAIN tracks with MIDI items but no instrument. Restored: undefined ? instrumentProgram : 0. Section sub-track (line 10393) keeps undefined -> oscillator fallback to avoid loading MAIN SoundFont.
This commit is contained in:
@@ -10280,7 +10280,7 @@ const App = () => {
|
||||
const noteEndSec = noteStartSec + noteDurSec;
|
||||
if (offsetTime < noteEndSec) {
|
||||
const durationMs = noteDurSec * 1000;
|
||||
const program = track.instrumentProgram;
|
||||
const program = track.instrumentProgram !== undefined ? track.instrumentProgram : 0;
|
||||
if (offsetTime < noteStartSec) {
|
||||
const delay = noteStartSec - offsetTime;
|
||||
const startTime = context.currentTime + delay;
|
||||
|
||||
Reference in New Issue
Block a user