Move all beats <-> frames time conversion into a single object that can be passed...
authorDavid Robillard <d@drobilla.net>
Mon, 16 Feb 2009 02:51:16 +0000 (02:51 +0000)
committerDavid Robillard <d@drobilla.net>
Mon, 16 Feb 2009 02:51:16 +0000 (02:51 +0000)
commit3963d2b0b224e79fdf8e852e39fc3a765fa1431b
tree0c6c8a9d519d46437ffe9cb96f09ca337f33faff
parentbeb3eea62bf217d0a7b2a86a96d5c375329df10a
Move all beats <-> frames time conversion into a single object that can be passed around.

This has 3 main benefits:
 - All conversion code is in one place (less duplication, potential bugs)
 - The conversion method can be passed to things that are ignorant
   of the actual time units involved, information required, etc.
   (In the future it would be nice to have user selectable tempo/frame time)
 - It should be relatively simple now to support tempo changes part-way
   through a MIDI region (at least architecturally speaking)

git-svn-id: svn://localhost/ardour2/branches/3.0@4594 d708f5d6-7413-0410-9779-e7cbd77b26cf
13 files changed:
gtk2_ardour/editor.h
gtk2_ardour/midi_region_view.cc
libs/ardour/SConscript
libs/ardour/ardour/beats_frames_converter.h [new file with mode: 0644]
libs/ardour/ardour/midi_source.h
libs/ardour/ardour/session.h
libs/ardour/audio_region_importer.cc
libs/ardour/beats_frames_converter.cc [new file with mode: 0644]
libs/ardour/import.cc
libs/ardour/midi_source.cc
libs/ardour/quantize.cc
libs/ardour/smf_source.cc
libs/evoral/evoral/TimeConverter.hpp [new file with mode: 0644]