Skip to content

Commit

Permalink
Added accessors for position and recording position
Browse files Browse the repository at this point in the history
Added accessors to get the current position as double.
  • Loading branch information
sieren committed Nov 10, 2015
1 parent fba2ae1 commit aa4af49
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
7 changes: 7 additions & 0 deletions maximilian.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1086,6 +1086,13 @@ void maxiSample::getLength() {
length=myDataSize*0.5;
}

double maxiSample::getPosition() {
return position;
}

double maxiSample::getRecordPosition() {
return recordPosition;
}
void maxiSample::setLength(unsigned long numSamples) {
cout << "Length: " << numSamples << endl;
short *newData = (short*) malloc(sizeof(short) * numSamples);
Expand Down
2 changes: 2 additions & 0 deletions maximilian.h
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,8 @@ class maxiSample {
int mySampleRate;
long length;
void getLength();
double getPosition();
double getRecordPosition();
void setLength(unsigned long numSamples);
short myBitsPerSample;

Expand Down

0 comments on commit aa4af49

Please sign in to comment.