home *** CD-ROM | disk | FTP | other *** search
- /*
- * Structure to hold the midi notes as we read
- * them in.
- */
- struct {
- short note[5000];
- long start[5000];
- long end[5000];
- short swhre;
- short ewhre;
- } track[16];
- /*
- * Structure to hold time sigs as we read them
- * in.
- */
- struct {
- long when;
- short num;
- short dnom;
- } tsig[100];
- /*
- * Keep track of how many new time sigs we have.
- */
- short twhre;
- /* measure number */
- short measure;
- /*
- * Some stuff we use for getting the notes out.
- */
- short tr[16];
- long ticks, endticks, h_ticks, lasttick;
- /*
- * Highest track number we've encountered. Notice
- * that if this contains int 16, that we have 16
- * tracks, just that we seen track 16. That may be
- * the *only* track we've seen. We go through some
- * other convolutions to make sure we don't try to
- * print tracks that don't exist.
- */
- short numtracks;
- /*
- * beamstyles from .midtomup file
- */
- struct {
- int bnum;
- int bdnom;
- char style[40];
- } bstyles[50];
- int bwhre;
- /*
- * translations from .midtomup file
- */
- struct {
- int in;
- int out;
- } tlate[16];
- int tlwhre;
- int tied[16];
- /*
- * Keeps current measure of notes. We'll user
- * this to avoid doing two accidentals on the
- * same note in the same measure.
- */
- int accnotes[32];
- int accwhre;
- /*
- * Similar to accnotes, but kept in seven note
- * format. Instead of midi number, we keep note
- * name (as 1-7), octave, and accidental.
- */
- int sccnotes[32][2];
- int sccwhre;
- /*
- * Hold key signatures offsets.
- */
- int key[16];
- int hkey[16];
- /*
- * tick and new key info
- */
- struct {
- long when;
- short nkey;
- } midikey[100];
- /*
- * What is the current key?
- */
- int mwhre;
- /*
- * Are we in a triplet?
- */
- int triplet;