#include <vector>
-#include "evoral/types.hpp"
+#include "evoral/Beats.hpp"
#include "ardour/ardour.h"
#include "ardour/region.h"
boost::shared_ptr<const MidiModel> model() const;
void fix_negative_start ();
-
+ Evoral::Beats start_beats () {return _start_beats.val(); }
+ Evoral::Beats length_beats () {return _length_beats.val(); }
protected:
virtual bool can_trim_start_before_source_start () const {
MidiRegion (const SourceList&);
MidiRegion (boost::shared_ptr<const MidiRegion>);
- MidiRegion (boost::shared_ptr<const MidiRegion>, frameoffset_t offset);
+ MidiRegion (boost::shared_ptr<const MidiRegion>, frameoffset_t offset, const int32_t sub_num = 0);
framecnt_t _read_at (const SourceList&, Evoral::EventSink<framepos_t>& dst,
framepos_t position,
void recompute_at_start ();
void recompute_at_end ();
- void set_position_internal (framepos_t pos, bool allow_bbt_recompute);
- void set_length_internal (framecnt_t len);
- void set_start_internal (framecnt_t);
- void update_length_beats ();
+ void set_position_internal (framepos_t pos, bool allow_bbt_recompute, const int32_t sub_num);
+ void set_length_internal (framecnt_t len, const int32_t sub_num);
+ void set_start_internal (framecnt_t, const int32_t sub_num);
+ void trim_to_internal (framepos_t position, framecnt_t length, const int32_t sub_num);
+ void update_length_beats (const int32_t sub_num);
void model_changed ();
void model_automation_state_changed (Evoral::Parameter const &);
void set_start_beats_from_start_frames ();
- void update_after_tempo_map_change ();
+ void update_after_tempo_map_change (bool send_change = true);
std::set<Evoral::Parameter> _filtered_parameters; ///< parameters that we ask our source not to return when reading
PBD::ScopedConnection _model_connection;