Mercurial > hg > multitrack-audio-matcher
view src/AccompanimentSynchroniser.h @ 50:93d21c20cfbc
Added Markers and the ability to switch to these points in the file when playing
author | Andrew N Robertson <andrew.robertson@eecs.qmul.ac.uk> |
---|---|
date | Thu, 14 Jun 2012 20:04:49 +0100 |
parents | f5de07b4d733 |
children | 5274e3b5479d |
line wrap: on
line source
/* * AccompanimentSynchroniser.h * MultipleAudioMathcher * * Created by Andrew on 06/02/2012. * Copyright 2012 QMUL. All rights reserved. * */ #ifndef ACCOMPANIMENT_SYNCHRONISER_H #define ACCOMPANIMENT_SYNCHRONISER_H #include "ofxOsc.h" #define HOST "localhost" #define SENDER_PORT 10875 #include "ofMain.h" class AccompanimentSynchroniser{ public: AccompanimentSynchroniser(); void reset(); void setPlayingRatio(const double& ratio, const double& timePlayed); void setRecordedPosition(); void updateRecordedPosition(const double& currentAlignmentPosition, const double& timeSent); void updateOutputSpeed(); int counter ; double fileLengthSamples; double playingPositionRatio; double playingPositionSamples; double playingPositionMillis; double playingPositionTimeSent; double recordedPositionMillis; double recordedPositionTimeSent; private: double speed; ofxOscSender sender; void sendSpeed(double const& val); }; #endif