<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div><div class="h5"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
</blockquote>
i don't know much about this, but is it ok to make an assumption like this?</blockquote></div></div></blockquote><div><br></div><div>Good point</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div><div class="h5"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> i mean we hardcode magic numbers that 24 pulses are 1 beat</blockquote></div></div></blockquote><div>
<br></div><div>That's safe, I think. The internal resolution of devices may of course be higher, and often is. 96 pulses per quarter note isn't uncommon.</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div><div class="h5"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> and 4 beats are 1 bar.<br><br></blockquote></div></div></blockquote><div><br></div><div>That's not safe; you can waltz, if you'd like, for example. Actually I don't think MIDI has anything to say about this. What does happen is MIDI periodically (say every 8 bars) sending a pulse to indicate the start of the pattern, grooveboxes and drum machines typically do this. I think the "clock start" message is used for that, from memory. This might need to be a global variable.</div>
<div><br></div><div>Sadly MIDI clock is more like a metronome in the room than like notes on sheet-music or netclock.</div><div><br></div><div>Yours,</div><div>Kas.</div></div>