From fdebcfb838964a7901a88c0753b3a09910d88faf Mon Sep 17 00:00:00 2001 From: David Robillard Date: Thu, 22 May 2008 20:00:54 +0000 Subject: [PATCH] Fix source/region length on MIDI import. git-svn-id: svn://localhost/ardour2/branches/3.0@3391 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/ardour/import.cc | 2 +- libs/ardour/smf_source.cc | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/libs/ardour/import.cc b/libs/ardour/import.cc index 4befd2ab00..c9d287c292 100644 --- a/libs/ardour/import.cc +++ b/libs/ardour/import.cc @@ -343,7 +343,7 @@ write_midi_data_to_new_files (SMFReader* source, Session::import_status& status, smfs->session().engine().frame_rate(), smfs->session().tempo_map().meter_at(timeline_position)); - smfs->update_length(0, (nframes_t) floor ((t * source->ppqn()) * frames_per_beat)); + smfs->update_length(0, (nframes_t) floor ((t / source->ppqn()) * frames_per_beat)); smfs->flush_header(); smfs->flush_footer(); diff --git a/libs/ardour/smf_source.cc b/libs/ardour/smf_source.cc index 6ec5f6cf46..e9a94b4f19 100644 --- a/libs/ardour/smf_source.cc +++ b/libs/ardour/smf_source.cc @@ -71,8 +71,6 @@ SMFSource::SMFSource (Session& s, std::string path, Flag flags) throw failed_constructor (); } - cerr << "SMF Source path: " << path << endl; - assert(_name.find("/") == string::npos); }