Mercurial > hg > precise-onset-detection
view ofxPreciseOnsetDetectorOffline/PreciseOnsetVisualiser.h @ 6:eb29c6b6dff8
added pointer version of visualiser
author | Andrew N Robertson <andrew.robertson@eecs.qmul.ac.uk> |
---|---|
date | Sun, 19 Jan 2014 23:07:13 +0000 |
parents | 93b9a9471011 |
children | b1c13e8bec26 |
line wrap: on
line source
/* * PreciseOnsetVisualiser.h * ofxPreciseOnsetDetectionOffline * * Created by Andrew Robertson on 28/12/2013. * Copyright 2013 QMUL. All rights reserved. * */ #ifndef PRECISE_ONSET_VISUALISER #define PRECISE_ONSET_VISUALISER #include "PreciseOnsetDetectorOffline.h" #include "ofxWindowRegion.h" #include "ofxPlotFunction.h" class PreciseOnsetVisualiser{ public: PreciseOnsetVisualiser(); ~PreciseOnsetVisualiser(); void newFile(); void update(); void draw(); double positionSeconds(); double windowWidth(); void mousePressed(int& x, int& y); void togglePlay(); void stop(); void resetWindow(); void cropStart(); void cropEnd(); void cropStartSeconds(double& val); void cropEndSeconds(double& val); void zoomIn(); void zoomOut(); void scrollLeft(); void scrollRight(); void scrollRightSecs(double secs); void scrollLeftSecs(double secs); void checkPosition(); void setPositionSeconds(double secs); double lengthSeconds(); //vars PreciseOnsetDetectorOffline* pod; ofSoundPlayer soundPlay; bool paused; // void drawOnsets(DoubleVector& onsetTimesSeconds, ofxWindowregion& window, double startTime, double endTime); ofxWindowRegion window; ofxPlotFunction plotter; double windowStart, windowEnd, windowPress; double currentPlayPosition; }; #endif