summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
Diffstat (limited to 'libs')
-rw-r--r--libs/ardour/midi_region.cc8
1 files changed, 3 insertions, 5 deletions
diff --git a/libs/ardour/midi_region.cc b/libs/ardour/midi_region.cc
index 05037d4af3..5d952824ea 100644
--- a/libs/ardour/midi_region.cc
+++ b/libs/ardour/midi_region.cc
@@ -91,9 +91,9 @@ MidiRegion::MidiRegion (const SourceList& srcs)
MidiRegion::MidiRegion (boost::shared_ptr<const MidiRegion> other)
: Region (other)
, _start_beats (Properties::start_beats, other->_start_beats)
- , _length_beats (Properties::length_beats, Evoral::Beats())
+ , _length_beats (Properties::length_beats, other->_length_beats)
{
- update_length_beats ();
+ //update_length_beats ();
register_properties ();
assert(_name.val().find("/") == string::npos);
@@ -105,14 +105,12 @@ MidiRegion::MidiRegion (boost::shared_ptr<const MidiRegion> other)
MidiRegion::MidiRegion (boost::shared_ptr<const MidiRegion> other, frameoffset_t offset)
: Region (other, offset)
, _start_beats (Properties::start_beats, Evoral::Beats())
- , _length_beats (Properties::length_beats, Evoral::Beats())
+ , _length_beats (Properties::length_beats, other->_length_beats)
{
BeatsFramesConverter bfc (_session.tempo_map(), other->_position);
Evoral::Beats const offset_beats = bfc.from (offset);
_start_beats = other->_start_beats.val() + offset_beats;
- _length_beats = Evoral::Beats (_session.tempo_map().beat_at_frame (other->length() - offset));
-
register_properties ();
assert(_name.val().find("/") == string::npos);