mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-22 05:07:07 +01:00
Fix converter origins for computing region length.
git-svn-id: svn://localhost/ardour2/branches/3.0@8309 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
1fd105fbd4
commit
fe879145fe
1 changed files with 2 additions and 2 deletions
|
|
@ -141,7 +141,7 @@ MidiRegion::set_length_internal (framecnt_t len)
|
|||
void
|
||||
MidiRegion::update_length_beats ()
|
||||
{
|
||||
BeatsFramesConverter converter (_session.tempo_map(), _position - _start);
|
||||
BeatsFramesConverter converter (_session.tempo_map(), _position);
|
||||
_length_beats = converter.from (_length);
|
||||
}
|
||||
|
||||
|
|
@ -156,7 +156,7 @@ MidiRegion::set_position_internal (framepos_t pos, bool allow_bbt_recompute)
|
|||
/* leave _length_beats alone, and change _length to reflect the state of things
|
||||
at the new position (tempo map may dictate a different number of frames
|
||||
*/
|
||||
BeatsFramesConverter converter (_session.tempo_map(), _position - _start);
|
||||
BeatsFramesConverter converter (_session.tempo_map(), _position);
|
||||
Region::set_length_internal (converter.to (_length_beats));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue