move auditioner output configuration params from session to global config vars
git-svn-id: svn://localhost/ardour2/branches/3.0@13414 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
5eeefbb3a5
commit
ca7e72db62
@ -152,6 +152,8 @@ CONFIG_VARIABLE (float, meter_falloff, "meter-falloff", 32.0f)
|
||||
|
||||
/* miscellany */
|
||||
|
||||
CONFIG_VARIABLE (std::string, auditioner_output_left, "auditioner-output-left", "default")
|
||||
CONFIG_VARIABLE (std::string, auditioner_output_right, "auditioner-output-right", "default")
|
||||
CONFIG_VARIABLE (bool, replicate_missing_region_channels, "replicate-missing-region-channels", false)
|
||||
CONFIG_VARIABLE (bool, hiding_groups_deactivates_groups, "hiding-groups-deactivates-groups", true)
|
||||
CONFIG_VARIABLE (bool, verify_remove_last_capture, "verify-remove-last-capture", true)
|
||||
|
@ -44,8 +44,6 @@ CONFIG_VARIABLE (Timecode::TimecodeFormat, timecode_format, "timecode-format", T
|
||||
CONFIG_VARIABLE_SPECIAL(std::string, raid_path, "raid-path", "", path_expand)
|
||||
CONFIG_VARIABLE_SPECIAL(std::string, audio_search_path, "audio-search-path", "", search_path_expand)
|
||||
CONFIG_VARIABLE_SPECIAL(std::string, midi_search_path, "midi-search-path", "", search_path_expand)
|
||||
CONFIG_VARIABLE (std::string, auditioner_output_left, "auditioner-output-left", "default")
|
||||
CONFIG_VARIABLE (std::string, auditioner_output_right, "auditioner-output-right", "default")
|
||||
CONFIG_VARIABLE (bool, jack_time_master, "jack-time-master", true)
|
||||
CONFIG_VARIABLE (bool, use_video_sync, "use-video-sync", false)
|
||||
CONFIG_VARIABLE (float, video_pullup, "video-pullup", 0.0f)
|
||||
|
@ -55,8 +55,8 @@ Auditioner::init ()
|
||||
return -1;
|
||||
}
|
||||
|
||||
string left = _session.config.get_auditioner_output_left();
|
||||
string right = _session.config.get_auditioner_output_right();
|
||||
string left = Config->get_auditioner_output_left();
|
||||
string right = Config->get_auditioner_output_right();
|
||||
|
||||
vector<string> outputs;
|
||||
_session.engine().get_physical_outputs (DataType::AUDIO, outputs);
|
||||
@ -83,24 +83,24 @@ Auditioner::init ()
|
||||
}
|
||||
}
|
||||
|
||||
if ((left.length() == 0) && (right.length() == 0)) {
|
||||
if (left.empty() && right.empty()) {
|
||||
warning << _("no outputs available for auditioner - manual connection required") << endmsg;
|
||||
return -1;
|
||||
} else {
|
||||
|
||||
_main_outs->defer_pan_reset ();
|
||||
|
||||
if (left.length()) {
|
||||
_output->add_port (left, this, DataType::AUDIO);
|
||||
}
|
||||
|
||||
if (right.length()) {
|
||||
_output->add_port (right, this, DataType::AUDIO);
|
||||
}
|
||||
|
||||
_main_outs->allow_pan_reset ();
|
||||
_main_outs->reset_panner ();
|
||||
}
|
||||
|
||||
_main_outs->defer_pan_reset ();
|
||||
|
||||
if (left.length()) {
|
||||
_output->add_port (left, this, DataType::AUDIO);
|
||||
}
|
||||
|
||||
if (right.length()) {
|
||||
_output->add_port (right, this, DataType::AUDIO);
|
||||
}
|
||||
|
||||
_main_outs->allow_pan_reset ();
|
||||
_main_outs->reset_panner ();
|
||||
|
||||
_output->changed.connect_same_thread (*this, boost::bind (&Auditioner::output_changed, this, _1, _2));
|
||||
|
||||
return 0;
|
||||
@ -226,12 +226,12 @@ Auditioner::output_changed (IOChange change, void* /*src*/)
|
||||
phys = outputs[0];
|
||||
}
|
||||
if (phys != connections[0]) {
|
||||
_session.config.set_auditioner_output_left (connections[0]);
|
||||
Config->set_auditioner_output_left (connections[0]);
|
||||
} else {
|
||||
_session.config.set_auditioner_output_left ("default");
|
||||
Config->set_auditioner_output_left ("default");
|
||||
}
|
||||
} else {
|
||||
_session.config.set_auditioner_output_left ("");
|
||||
Config->set_auditioner_output_left ("");
|
||||
}
|
||||
|
||||
connections.clear ();
|
||||
@ -241,12 +241,12 @@ Auditioner::output_changed (IOChange change, void* /*src*/)
|
||||
phys = outputs[1];
|
||||
}
|
||||
if (phys != connections[0]) {
|
||||
_session.config.set_auditioner_output_right (connections[0]);
|
||||
Config->set_auditioner_output_right (connections[0]);
|
||||
} else {
|
||||
_session.config.set_auditioner_output_right ("default");
|
||||
Config->set_auditioner_output_right ("default");
|
||||
}
|
||||
} else {
|
||||
_session.config.set_auditioner_output_right ("");
|
||||
Config->set_auditioner_output_right ("");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user