static float current_automation_version_number = 1.0;
-nframes_t IO::_automation_interval = 0;
const string IO::state_node_name = "IO";
bool IO::connecting_legal = false;
bool IO::ports_legal = false;
deferred_state = 0;
apply_gain_automation = false;
-
- last_automation_snapshot = 0;
-
+ _ignore_gain_on_deliver = false;
+
_gain_automation_state = Off;
_gain_automation_style = Absolute;
gain_t dg;
gain_t old_gain = _gain;
- if (apply_gain_automation) {
+ if (apply_gain_automation || _ignore_gain_on_deliver) {
/* gain has already been applied by automation code. do nothing here except
speed quietning.
_gain = dg;
}
- if (apply_gain_automation) {
+ if (apply_gain_automation || _ignore_gain_on_deliver) {
_gain = old_gain;
}
}
}
}
+#ifdef STATE_MANAGER
UndoAction
IO::get_memento() const
{
StateManager::State* state = new StateManager::State (why);
return state;
}
+#endif
/**
Update the peak meters.
}
}
+#ifdef STATE_MANAGER
_gain_automation_curve.save_state (_("loaded from disk"));
+#endif
return 0;
}
if (state != _gain_automation_curve.automation_state()) {
changed = true;
- last_automation_snapshot = 0;
_gain_automation_curve.set_automation_state (state);
if (state != Off) {
}
-void
-IO::automation_snapshot (nframes_t now)
-{
- if (last_automation_snapshot > now || (now - last_automation_snapshot) > _automation_interval) {
-
- if (gain_automation_recording()) {
- _gain_automation_curve.rt_add (now, gain());
- }
-
- _panner->snapshot (now);
-
- last_automation_snapshot = now;
- }
-}
-
void
IO::transport_stopped (nframes_t frame)
{
if (_gain_automation_curve.automation_state() != Off) {
+#ifdef STATE_MANAGER
if (gain_automation_recording()) {
_gain_automation_curve.save_state (_("automation write/touch"));
}
+#endif
/* the src=0 condition is a special signal to not propagate
automation gain changes into the mix group when locating.