summaryrefslogtreecommitdiff
path: root/libs/ardour/mtc_slave.cc
AgeCommit message (Collapse)Author
2012-10-12MTC: map between timecodesRobin Gareus
allow external timecode device to supply timecode with framerates other than ardour session's framerate. also fix latency overcompensation. The slave is supposed to provide transport time - and not audible frame time. git-svn-id: svn://localhost/ardour2/branches/3.0@13250 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-10-12move TimecodeFormat to libtimecodeRobin Gareus
provide a way to convert any TimecodeFormat to float frame-rate, not only the currently active timecode_foramt. git-svn-id: svn://localhost/ardour2/branches/3.0@13249 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-10-10add global config parameter timecode-sync-frame-rate to control behaviour ↵Paul Davis
when a timecode slave (MTC, LTC) has a different frame rate than an Ardour session git-svn-id: svn://localhost/ardour2/branches/3.0@13233 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-10-10MTC slave, don't touch position if no MTC was receivedRobin Gareus
git-svn-id: svn://localhost/ardour2/branches/3.0@13232 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-10-10MTC-slave: print error if framerate mismatchRobin Gareus
git-svn-id: svn://localhost/ardour2/branches/3.0@13231 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-10-10fix and improve MTC-slaveRobin Gareus
- MTC-speed average (MIDI thread) * base timing on quarter-frames * replace hann-window average with a DLL - MTC/engine alignment * replace 1st order PI-controller with 2nd order DLL The 2nd DLL is needed because the jack-process callback effectively quantizes the transport-speed to integer audio-frames (speed * nframes). This leaves a delta on every cycle because the remainder from previous cycles is not compensated for. Theoretically it is possible to merge the two DLLs into one. However, with callbacks coming from by two independent threads it is cleaner to track the MTC and JACK engine-alignment speeds independently. git-svn-id: svn://localhost/ardour2/branches/3.0@13226 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-10-04drop connections to incoming MIDI signals before deleting MTC Slave objectPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@13208 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-07-25convert from Glib:: to Glib::Threads for all thread-related APIPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@13084 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-05-24Remove over 500 unnecessary includes (including 54 of session.h).David Robillard
It's slightly possible that this causes trivial build failures on different configurations, but otherwise shouldn't cause any problems (i.e. no actual changes other than include/naming/namespace stuff). I deliberately avoided removing libardour-config.h since this can mysteriously break things, though a few of those do seem to be unnecessary. This commit only targets includes of ardour/*.h. There is also a very large number of unnecessary includes of stuff in gtk2_ardour; tackling that should also give a big improvement in build time when things are modified. git-svn-id: svn://localhost/ardour2/branches/3.0@12420 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-06-01Fix broken whitespace. I'd apologize for the compile times if it was my ↵David Robillard
fault :D git-svn-id: svn://localhost/ardour2/branches/3.0@9654 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-03-09add new concept for managing alignment style (AlignChoice); switch to using ↵Paul Davis
worst_playback_latency() just about everywhere we were using worst_output_latency() - the former includes plugin latency. answer appears to break earlier fixes to alignment, but is semantically right, so plan to investigate in another 8 hours or so git-svn-id: svn://localhost/ardour2/branches/3.0@9112 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-12-03Remove all use of nframes_t.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@8166 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-12-01Revert previous incorrect patch.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@8144 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-12-01Remove unused timecode offset stuff.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@8143 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-09-17megaopus patch #2 for today: remove nframes64_t and sframes_t from sourcePaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@7792 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-09-17megaopus commit: (1) add __STD_(LIMIT|FORMAT)_MACROS to command line flags ↵Paul Davis
for cc and c++ builds, remove them from source (2) add new Property::midi_data used by MidiRegion to signal that its (MIDI) contents have changed (3) massive switch from nframes_t to framepos_t/framecnt_t including removal of ARDOUR::max_frames (replaced by ARDOUR::max_frame{pos,cnt} (lots more to do but this set was driven by changes to the Diskstream API to use framepos_t git-svn-id: svn://localhost/ardour2/branches/3.0@7791 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-07-08Trim midi++ port code to either do in or out, but not both in the same object.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@7391 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-06-17new fade in/fade out colors from chrisgPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@7272 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-02-11tweak Stateful/StatefulDiffCommand changes so that SessionObject's actually ↵Paul Davis
get a name; make StatefulDiffCommand use a weak_ptr, not a raw ptr; use .val() rather than .get() to avoid confusion with boost:: smart ptr method of the same name git-svn-id: svn://localhost/ardour2/branches/3.0@6678 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-02-11some fixes/tweaks for MTC slaving, some untestedPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6676 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-28cleanup of mtc slave code from debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6581 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27something for chris g. to try when he gets up before mePaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6573 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6572 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6571 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6570 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6569 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6568 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6567 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6566 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6565 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-27more MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6564 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-21fully implement and deploy explicit x-thread signal connection syntax ↵Paul Davis
(testing comes next) git-svn-id: svn://localhost/ardour2/branches/3.0@6379 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-19use new syntax for connecting to backend signals that enforces explicit ↵Paul Davis
connection scope, plus a few other related matters git-svn-id: svn://localhost/ardour2/branches/3.0@6376 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-17switch to using boost::signals2 instead of sigc++, at least for libardour. ↵Paul Davis
not finished yet, but compiles, loads sessions, records and can close a session without a crash git-svn-id: svn://localhost/ardour2/branches/3.0@6372 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-12remove using namespace sigc everywhere to ensure clarity over which ↵Paul Davis
bind/mem_fun is being used; make Config::map_parameters take a boost::function rather than a sigc::slot ; continue debugging crash caused by regionviews not tracking their Region's lifetime git-svn-id: svn://localhost/ardour2/branches/3.0@6357 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-10drastic, deep and wide changes to make RouteGroup use ↵Paul Davis
boost::shared_ptr<Route> and boost::shared_ptr<RouteList> to better fit into emerging framework for "RT operations" ; torben's changes to MTC slaving code (sorry for bundling) git-svn-id: svn://localhost/ardour2/branches/3.0@6334 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-03more tweaks to MTC slave code (still not functional), including removing ↵Paul Davis
race conditions when resetting slave state; make Session catch on its own saved preferences, which has not been happening; make switching sync sources avoid race conditions git-svn-id: svn://localhost/ardour2/branches/3.0@6269 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-02more MTC stuff, including toggleable use of torben's PI controllerPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6265 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01adjust to use timestamped MTC messagesPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6255 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01continue with MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6251 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01continue with MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6250 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01continue with MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6248 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01continue with MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6247 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01more changes to try to improve MTC handling even in slightly pathological casesPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6245 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01continue with MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6236 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01continue with MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6235 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01continue with MTC debuggingPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6234 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-01rework MTC slave so that speed is computed in the MIDI I/O context, not ↵Paul Davis
process() context git-svn-id: svn://localhost/ardour2/branches/3.0@6233 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-11-30more debugging tweaksPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6223 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-11-30more debugging tweaksPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6222 d708f5d6-7413-0410-9779-e7cbd77b26cf