* ControlGroup::set_group_values().
*/
- const float desired_gain = user_double();
+ const float desired_gain = get_value ();
if (fabsf (desired_gain) < GAIN_COEFF_SMALL) {
// really?! what's the idea here?
}
}
+void
+GainControl::post_add_master (boost::shared_ptr<AutomationControl> m)
+{
+ if (m->get_value() == 0) {
+ /* master is at -inf, which forces this ctrl to -inf on assignment */
+ Changed (false, Controllable::NoGroup); /* EMIT SIGNAL */
+ }
+}
+
bool
GainControl::get_masters_curve_locked (framepos_t start, framepos_t end, float* vec, framecnt_t veclen) const
{
+ if (_masters.empty()) {
+ return list()->curve().rt_safe_get_vector (start, end, vec, veclen);
+ }
+ for (framecnt_t i = 0; i < veclen; ++i) {
+ vec[i] = 1.f;
+ }
return SlavableAutomationControl::masters_curve_multiply (start, end, vec, veclen);
}