13
0
livetrax/libs
Mads Kiilerich 80ffa58c81 temporal: introduce Temporal::reset() with TempoMap initialization
Ardour uses some global variables and singletons. These global variables
can be initialized with a value prior to program execution (especially
if they are const), but some of the static variables are modified, and
it is crucial that they always are reset when switching to another
session. To keep things simple and explicit and consistent, we thus
introduce Temporal::reset() to reset TempoMap (and later on also the
superclock rate). This is somewhat similar to Temporal::init(), which
usually only is invoked once (on program start) to initialize singletons
(such as the TempoMap).

9964f20c added TempoMap initialization to Session::create() ... but only
when not using a template. This create method is mainly preparing the
filesystem for a new session, and TempoMap initialization doesn't seem
like a perfect fit for it. It also seemed odd that it only initialized
TempoMap for clean new sessions, while existing sessions and templates
initialized it elsewhere.

Instead, invoke the TempoMap initialization early in the Session
creation process. This might introduce an extra and unnecessary TempoMap
initialization when loading an existing session or using a template, but
that will be cheap and do no harm, while providing a guarantee that we
always use the same default value.
2023-09-20 12:30:53 -06:00
..
appleutility
ardour temporal: introduce Temporal::reset() with TempoMap initialization 2023-09-20 12:30:53 -06:00
ardouralsautil wscript: drop unused path_prefix 2023-09-17 07:34:55 -06:00
audiographer wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
auscan wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
backends wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
canvas wscript: drop unused path_prefix 2023-09-17 07:34:55 -06:00
clearlooks-newer wscript: drop unused path_prefix 2023-09-17 07:34:55 -06:00
ctrl-interface wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
evoral wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
fluidsynth wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
fst wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
gtkmm2ext wscript: drop unused path_prefix 2023-09-17 07:34:55 -06:00
hidapi wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
libltc wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
lua wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
midi++2 wscript: drop unused path_prefix 2023-09-17 07:34:55 -06:00
panners wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
pbd wscript: drop unused path_prefix 2023-09-17 07:34:55 -06:00
plugins wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
ptformat wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
qm-dsp wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
surfaces Initialize uninitialized variable 2023-09-19 18:28:00 +02:00
temporal temporal: introduce Temporal::reset() with TempoMap initialization 2023-09-20 12:30:53 -06:00
vamp-plugins wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
vamp-pyin wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
vfork wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
vst3
waveview wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
widgets wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
zita-convolver wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00
zita-resampler wscript: drop unused "mandatory variables" 'top' and 'out' in libs 2023-09-17 07:34:55 -06:00