Tracktion engine omits MIDI notes

I’m trying to use the tracktion engine in a plugin, following the EngineInPluginDemo example.

I set up a MIDI clip on the first track and add notes to it in my prepareToPlay method, but notes at the beginning of the clip are left out:

auto midiClip = track->insertMIDIClip("Clip", {te::TimePosition::fromSeconds(0), te::TimeDuration::fromSeconds(36000000)} , nullptr); // 0 to 10,000 hours

midiClip->getSequence().addNote(63, te::BeatPosition::fromBeats(0), te::BeatDuration::fromBeats(0.5), 100, 0, nullptr);     // Does not play
midiClip->getSequence().addNote(64, te::BeatPosition::fromBeats(0.001), te::BeatDuration::fromBeats(0.5), 100, 0, nullptr); // Does not play
midiClip->getSequence().addNote(65, te::BeatPosition::fromBeats(0.01), te::BeatDuration::fromBeats(0.5), 100, 0, nullptr);  // Does not play
midiClip->getSequence().addNote(66, te::BeatPosition::fromBeats(0.1), te::BeatDuration::fromBeats(0.5), 100, 0, nullptr);   // Plays
midiClip->getSequence().addNote(67, te::BeatPosition::fromBeats(1), te::BeatDuration::fromBeats(0.5), 100, 0, nullptr);     // Plays

Am I missing something?

As far as I can tell that should work.
Does it not play when looped around either or just the first time?

Have you tried in any other DAWs or just Live?

It would be helpful if you could put a break point in MidiNode::processSection and see what the sectionEditRange is for the first time it’s called? I.e. does it start at 0 when playback is started or some offset?

Exactly same behaviour in Reaper. The notes also do not play when the DAW loops around.

@dave96 did you have a chance to look at this?

Sorry, I’ve been away for two weeks and been catching up since I’ve been back (also preparing for ADC in a couple of weeks).

As I’ve said before when things get tight I have to prioritise pairs tier customers I’m afraid. (If you are on a paid tier, PM me so I can add you to the list).