Skip to content

Commit

Permalink
Fixed back and forth sometimes going backwards (issue #94).
Browse files Browse the repository at this point in the history
  • Loading branch information
SamuelBeland committed Oct 2, 2020
1 parent d4f012a commit 99b5618
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
9 changes: 2 additions & 7 deletions Source/cg_TrajectoryManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -176,12 +176,6 @@ Point<float> TrajectoryManager::getCurrentTrajectoryPoint() const
}
}

//==============================================================================
void TrajectoryManager::setPrimarySourcePosition(Point<float> const & pos) const
{
mPrimarySource.setPosition(pos, Source::OriginOfChange::trajectory);
}

//==============================================================================
void TrajectoryManager::sourceMoved(Source & source)
{
Expand Down Expand Up @@ -220,7 +214,7 @@ void PositionTrajectoryManager::setTrajectoryType(PositionTrajectoryType const t
} else {
mTrajectory = Trajectory{ type, startPos };
}
// mPrimarySource.setPosition(startPos, Source::OriginOfChange::trajectory);
mBackAndForthDirection = Direction::forward;
}

//==============================================================================
Expand All @@ -246,6 +240,7 @@ void ElevationTrajectoryManager::setTrajectoryType(ElevationTrajectoryType const
} else {
mTrajectory.reset();
}
mBackAndForthDirection = Direction::forward;
}

//==============================================================================
Expand Down
1 change: 0 additions & 1 deletion Source/cg_TrajectoryManager.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ class TrajectoryManager

void setPositionDampeningCycles(int const value) { this->mDampeningCycles = value; }
void setDeviationPerCycle(Degrees const value) { this->mDegreeOfDeviationPerCycle = value; }
void setPrimarySourcePosition(Point<float> const & pos) const;
void addListener(Listener * l) { mListeners.add(l); }

void sourceMoved(Source & source);
Expand Down

0 comments on commit 99b5618

Please sign in to comment.