annotate hackday/drawMidiNotes.h @ 52:13194a9dca77 tip

Added exporting of image and text data
author Andrew N Robertson <andrew.robertson@eecs.qmul.ac.uk>
date Tue, 17 Jul 2012 22:13:10 +0100
parents 49a5b023df1e
children
rev   line source
andrew@28 1 /*
andrew@28 2 * drawMidiNotes.h
andrew@28 3 * midiCannamReader
andrew@28 4 *
andrew@28 5 * Created by Andrew on 17/07/2011.
andrew@28 6 * Copyright 2011 QMUL. All rights reserved.
andrew@28 7 *
andrew@28 8 */
andrew@28 9
andrew@28 10
andrew@28 11 #include "ofMain.h"
andrew@28 12
andrew@28 13 class drawMidiNotes{
andrew@28 14 public:
andrew@28 15 drawMidiNotes();
andrew@28 16 void updatePlayPosition();
andrew@28 17
andrew@28 18 typedef std::vector<double> DoubleVector;
andrew@28 19 typedef std::vector<DoubleVector> DoubleMatrix;
andrew@28 20
andrew@28 21 DoubleMatrix beatPeriodMatrix;
andrew@28 22
andrew@28 23 typedef std::vector<int> IntVector;
andrew@28 24 typedef std::vector<IntVector> IntMatrix;
andrew@28 25
andrew@28 26 void drawFile(const IntMatrix& noteOnMatrix);
andrew@28 27 void reset();
andrew@28 28
andrew@28 29 int ticksPerScreen;
andrew@28 30 int tickLocation;
andrew@28 31 int noteArrayIndex;
andrew@28 32
andrew@28 33 int noteMinimum, noteMaximum;
andrew@28 34 int screenWidth, screenHeight;
andrew@28 35 float noteHeight;
andrew@28 36 float tempo;
andrew@28 37 double period;
andrew@28 38 int pulsesPerQuarternote;
andrew@28 39 double lastPeriodUpdateTime;
andrew@28 40
andrew@28 41
andrew@28 42 };