diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2011-01-07 20:47:38 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2011-01-07 20:47:38 +0000 |
commit | adf9ac516db2456f0ec797a3bce93d5b4e49dfaf (patch) | |
tree | 6987c46e7aea7a95907240ac93cfbb274040dfd4 /gtk2_ardour/panner_ui.cc | |
parent | db79f711f8e05e9484deeed640f761d8ddd56f8c (diff) |
rip more useless junk out of PannerUI, and check that automation playback works for the mono panner
git-svn-id: svn://localhost/ardour2/branches/3.0@8477 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/panner_ui.cc')
-rw-r--r-- | gtk2_ardour/panner_ui.cc | 59 |
1 files changed, 8 insertions, 51 deletions
diff --git a/gtk2_ardour/panner_ui.cc b/gtk2_ardour/panner_ui.cc index 730b382d6b..390e47d096 100644 --- a/gtk2_ardour/panner_ui.cc +++ b/gtk2_ardour/panner_ui.cc @@ -608,58 +608,15 @@ PannerUI::pan_reset_all () void PannerUI::effective_pan_display () { - if (_panner->empty()) { - return; - } - - switch (_panner->nouts()) { - case 0: - case 1: - /* relax: no panning */ - break; - - case 2: - update_pan_bars (true); - break; - - default: - //panner->move_puck (pan_value (v, right), 0.5); - break; - } -} - -void -PannerUI::update_pan_bars (bool only_if_aplay) -{ - uint32_t n; - - in_pan_update = true; - -#if 0 - /* this runs during automation playback, and moves the bar controllers - and/or pucks around. - */ - - for (i = pan_bars.begin(), n = 0; i != pan_bars.end(); ++i, ++n) { - - if (only_if_aplay) { - boost::shared_ptr<AutomationList> alist (_panner->streampanner(n).pan_control()->alist()); - if (!alist->automation_playback()) { - continue; - } - } - - AngularVector model = _panner->streampanner(n).get_effective_position(); - double fract = (*i)->get_value(); - AngularVector view (BaseStereoPanner::lr_fract_to_azimuth (fract), 0.0); - - if (!Panner::equivalent (model, view)) { - (*i)->set_value (BaseStereoPanner::azimuth_to_lr_fract (model.azi)); - } + if (_stereo_panner) { + _stereo_panner->queue_draw (); + } else if (twod_panner) { + twod_panner->queue_draw (); + } else { + for (vector<MonoPanner*>::iterator i = pan_bars.begin(); i != pan_bars.end(); ++i) { + (*i)->queue_draw (); + } } -#endif - - in_pan_update = false; } void |