/*
Copyright (C) 2009 Paul Davis
- Author: Dave Robillard
+ Author: David Robillard
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
class TempoMap;
-/** Converter between beats and frames. Takes durations in beats or frames
- * and converts them using the tempo at the \a origin supplied to the constructor.
- * Note that this does not covert positions, only durations.
+/** Converter between beats and frames. Takes distances in beats or frames
+ * from some origin (supplied to the constructor in frames), and converts
+ * them to the opposite unit, taking tempo changes into account.
*/
class BeatsFramesConverter : public Evoral::TimeConverter<double,framepos_t> {
public:
- BeatsFramesConverter (const TempoMap& tempo_map, framepos_t origin)
+ BeatsFramesConverter (TempoMap& tempo_map, framepos_t origin)
: Evoral::TimeConverter<double, framepos_t> (origin)
, _tempo_map(tempo_map)
{}
double from (framepos_t frames) const;
private:
- const TempoMap& _tempo_map;
+ TempoMap& _tempo_map;
};
} /* namespace ARDOUR */