take reverse width into account when labelling signals in panner2d ; better way to draw the width arc
git-svn-id: svn://localhost/ardour2/branches/3.0@8956 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
@@ -119,7 +119,7 @@ LV2Plugin::init (LV2World& world, SLV2Plugin plugin, framecnt_t rate)
|
||||
|
||||
if (_instance == 0) {
|
||||
error << _("LV2: Failed to instantiate plugin ")
|
||||
<< slv2_plugin_get_uri(plugin) << endl;
|
||||
<< slv2_value_as_string (slv2_plugin_get_uri(plugin)) << endmsg;
|
||||
throw failed_constructor();
|
||||
}
|
||||
|
||||
@@ -130,7 +130,7 @@ LV2Plugin::init (LV2World& world, SLV2Plugin plugin, framecnt_t rate)
|
||||
if (slv2_plugin_has_feature(plugin, world.in_place_broken)) {
|
||||
error << string_compose(
|
||||
_("LV2: \"%1\" cannot be used, since it cannot do inplace processing"),
|
||||
slv2_value_as_string(_name));
|
||||
slv2_value_as_string(_name)) << endmsg;
|
||||
slv2_value_free(_name);
|
||||
slv2_value_free(_author);
|
||||
throw failed_constructor();
|
||||
|
||||
@@ -870,6 +870,8 @@ Route::add_processor (boost::shared_ptr<Processor> processor, ProcessorList::ite
|
||||
{
|
||||
assert (processor != _meter);
|
||||
assert (processor != _main_outs);
|
||||
|
||||
DEBUG_TRACE (DEBUG::Processors, string_compose ("%1 adding processor %2\n", name(), processor->name()));
|
||||
|
||||
ChanCount old_pms = processor_max_streams;
|
||||
|
||||
@@ -916,7 +918,6 @@ Route::add_processor (boost::shared_ptr<Processor> processor, ProcessorList::ite
|
||||
if (configure_processors_unlocked (err)) {
|
||||
pstate.restore ();
|
||||
configure_processors_unlocked (0); // it worked before we tried to add it ...
|
||||
cerr << "configure failed\n";
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -99,7 +99,8 @@ VBAPanner::update ()
|
||||
|
||||
/* panner width control is [-1.0 .. 1.0]; we ignore sign, and map to [0 .. 360] degrees
|
||||
so that a width of 1 corresponds to a signal equally present from all directions,
|
||||
and a width of zero corresponds to a point source from the "center" (above)
|
||||
and a width of zero corresponds to a point source from the "center" (above) point
|
||||
on the perimeter of the speaker array.
|
||||
*/
|
||||
|
||||
double w = fabs (_pannable->pan_width_control->get_value()) * 360.0;
|
||||
@@ -123,13 +124,24 @@ VBAPanner::update ()
|
||||
double degree_step_per_signal = (max_dir - min_dir) / (_signals.size() - 1);
|
||||
double signal_direction = min_dir;
|
||||
|
||||
for (vector<Signal*>::iterator s = _signals.begin(); s != _signals.end(); ++s) {
|
||||
if (w >= 0.0) {
|
||||
for (vector<Signal*>::iterator s = _signals.begin(); s != _signals.end(); ++s) {
|
||||
|
||||
Signal* signal = *s;
|
||||
Signal* signal = *s;
|
||||
|
||||
signal->direction = AngularVector (signal_direction, 0.0);
|
||||
compute_gains (signal->desired_gains, signal->desired_outputs, signal->direction.azi, signal->direction.ele);
|
||||
signal_direction += degree_step_per_signal;
|
||||
}
|
||||
} else {
|
||||
for (vector<Signal*>::reverse_iterator s = _signals.rbegin(); s != _signals.rend(); ++s) {
|
||||
|
||||
signal->direction = AngularVector (signal_direction, 0.0);
|
||||
compute_gains (signal->desired_gains, signal->desired_outputs, signal->direction.azi, signal->direction.ele);
|
||||
signal_direction += degree_step_per_signal;
|
||||
Signal* signal = *s;
|
||||
|
||||
signal->direction = AngularVector (signal_direction, 0.0);
|
||||
compute_gains (signal->desired_gains, signal->desired_outputs, signal->direction.azi, signal->direction.ele);
|
||||
signal_direction += degree_step_per_signal;
|
||||
}
|
||||
}
|
||||
|
||||
} else if (_signals.size() == 1) {
|
||||
|
||||
Reference in New Issue
Block a user