Renoise api questions

I now use

for seqIndex = 1, #Song.sequencer.pattern_sequence do
  local patternIndex = Song.sequencer.pattern_sequence[seqIndex]
  ...
  for position, noteColumn in Song.pattern_iterator:note_columns_in_pattern(patternIndex) do
    ...
  end
end

It’s quite a bit slower, but now works properly, also note-offs caused by muted sequence slots work now.