X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Fpanner_shell.cc;h=678b1a1357a69a812599f42c674a3a8b60196264;hb=6e94b1fb9f79c5bfcf22cd5b88619afa9bedb1b2;hp=75543433c5171b64dadb65b2cc19726369e84059;hpb=6acdfc69b785841ac10a324484ddd0208612a213;p=ardour.git diff --git a/libs/ardour/panner_shell.cc b/libs/ardour/panner_shell.cc index 75543433c5..678b1a1357 100644 --- a/libs/ardour/panner_shell.cc +++ b/libs/ardour/panner_shell.cc @@ -21,7 +21,6 @@ #include #include -#include #include #include #include @@ -119,8 +118,8 @@ PannerShell::configure_io (ChanCount in, ChanCount out) PannerInfo* pi = PannerManager::instance().select_panner (in, out, _user_selected_panner_uri); if (!pi) { - cerr << "No panner found: check that panners are being discovered correctly during startup.\n"; - assert (pi); + fatal << _("No panner found: check that panners are being discovered correctly during startup.") << endmsg; + abort(); /*NOTREACHED*/ } DEBUG_TRACE (DEBUG::Panning, string_compose (_("select panner: %1\n"), pi->descriptor.name.c_str())); @@ -172,7 +171,7 @@ PannerShell::set_state (const XMLNode& node, int version) XMLNodeList nlist = node.children (); XMLNodeConstIterator niter; const XMLProperty *prop; - LocaleGuard lg (X_("POSIX")); + LocaleGuard lg (X_("C")); if ((prop = node.property (X_("bypassed"))) != 0) { set_bypassed (string_is_affirmative (prop->value ())); @@ -187,7 +186,7 @@ PannerShell::set_state (const XMLNode& node, int version) } _panner.reset (); - + for (niter = nlist.begin(); niter != nlist.end(); ++niter) { if ((*niter)->name() == X_("Panner")) { @@ -233,6 +232,16 @@ PannerShell::set_state (const XMLNode& node, int version) _current_panner_uri = (*p)->descriptor.panner_uri; _panner_gui_uri = (*p)->descriptor.gui_uri; + if (_is_send) { + if (!_panlinked) { + _pannable_internal->set_panner(_panner); + } else { + _force_reselect = true; + } + } else { + _pannable_route->set_panner(_panner); + } + if (_panner->set_state (**niter, version) == 0) { return -1; } @@ -274,13 +283,13 @@ PannerShell::distribute_no_automation (BufferSet& inbufs, BufferSet& outbufs, pf AudioBuffer& dst = outbufs.get_audio(0); - if (gain_coeff == 0.0f) { + if (gain_coeff == GAIN_COEFF_ZERO) { /* gain was zero, so make it silent */ dst.silence (nframes); - } else if (gain_coeff == 1.0f){ + } else if (gain_coeff == GAIN_COEFF_UNITY){ /* mix all input buffers into the output */ @@ -375,14 +384,7 @@ PannerShell::run (BufferSet& inbufs, BufferSet& outbufs, framepos_t start_frame, if (!(as & Play || ((as & Touch) && !_panner->touching()))) { - // Speed quietning - gain_t gain_coeff = 1.0; - - if (fabsf(_session.transport_speed()) > 1.5f && Config->get_quieten_at_speed ()) { - gain_coeff = speed_quietning; - } - - distribute_no_automation (inbufs, outbufs, nframes, gain_coeff); + distribute_no_automation (inbufs, outbufs, nframes, 1.0); } else { @@ -403,7 +405,7 @@ PannerShell::set_bypassed (bool yn) if (yn == _bypassed) { return; } - + _bypassed = yn; _session.set_dirty (); Changed (); /* EMIT SIGNAL */