mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-07 07:14:56 +01:00
adapt JACK audiobackend to pay attention to new _start() API related to latency measurement
This commit is contained in:
parent
057f06703b
commit
589ef168c1
4 changed files with 9 additions and 9 deletions
|
|
@ -471,7 +471,7 @@ JACKAudioBackend::raw_buffer_size(DataType t)
|
|||
}
|
||||
|
||||
void
|
||||
JACKAudioBackend::setup_jack_startup_command ()
|
||||
JACKAudioBackend::setup_jack_startup_command (bool for_latency_measurement)
|
||||
{
|
||||
/* first we map the parameters that have been set onto a
|
||||
* JackCommandLineOptions object.
|
||||
|
|
@ -505,7 +505,7 @@ JACKAudioBackend::setup_jack_startup_command ()
|
|||
|
||||
string cmdline;
|
||||
|
||||
if (!get_jack_command_line_string (options, cmdline)) {
|
||||
if (!get_jack_command_line_string (options, cmdline, for_latency_measurement)) {
|
||||
/* error, somehow - we will still try to start JACK
|
||||
* automatically but it will be without our preferred options
|
||||
*/
|
||||
|
|
@ -520,7 +520,7 @@ JACKAudioBackend::setup_jack_startup_command ()
|
|||
/* ---- BASIC STATE CONTROL API: start/stop/pause/freewheel --- */
|
||||
|
||||
int
|
||||
JACKAudioBackend::start ()
|
||||
JACKAudioBackend::_start (bool for_latency_measurement)
|
||||
{
|
||||
if (!available()) {
|
||||
|
||||
|
|
@ -528,7 +528,7 @@ JACKAudioBackend::start ()
|
|||
/* we will be starting JACK, so set up the
|
||||
command that JACK will use when it (auto-)starts
|
||||
*/
|
||||
setup_jack_startup_command ();
|
||||
setup_jack_startup_command (for_latency_measurement);
|
||||
}
|
||||
|
||||
if (_jack_connection->open ()) {
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@ class JACKAudioBackend : public AudioBackend {
|
|||
std::string control_app_name () const;
|
||||
void launch_control_app ();
|
||||
|
||||
int start ();
|
||||
int _start (bool for_latency_measurement);
|
||||
int stop ();
|
||||
int pause ();
|
||||
int freewheel (bool);
|
||||
|
|
@ -225,7 +225,7 @@ class JACKAudioBackend : public AudioBackend {
|
|||
void* process_thread ();
|
||||
static void* _start_process_thread (void*);
|
||||
|
||||
void setup_jack_startup_command ();
|
||||
void setup_jack_startup_command (bool for_latency_measurement);
|
||||
|
||||
/* pffooo */
|
||||
|
||||
|
|
|
|||
|
|
@ -685,7 +685,7 @@ ARDOUR::JackCommandLineOptions::JackCommandLineOptions ()
|
|||
}
|
||||
|
||||
bool
|
||||
ARDOUR::get_jack_command_line_string (JackCommandLineOptions& options, string& command_line)
|
||||
ARDOUR::get_jack_command_line_string (JackCommandLineOptions& options, string& command_line, bool for_latency_measurement)
|
||||
{
|
||||
vector<string> args;
|
||||
|
||||
|
|
@ -821,7 +821,7 @@ ARDOUR::get_jack_command_line_string (JackCommandLineOptions& options, string& c
|
|||
args.push_back ("-p");
|
||||
args.push_back (to_string (options.period_size, std::dec));
|
||||
|
||||
if (get_jack_audio_driver_supports_latency_adjustment (options.driver)) {
|
||||
if (!for_latency_measurement && get_jack_audio_driver_supports_latency_adjustment (options.driver)) {
|
||||
if (options.input_latency) {
|
||||
args.push_back ("-I");
|
||||
args.push_back (to_string (options.input_latency, std::dec));
|
||||
|
|
|
|||
|
|
@ -236,5 +236,5 @@ namespace ARDOUR {
|
|||
/**
|
||||
* @return true if able to build a valid command line based on options
|
||||
*/
|
||||
bool get_jack_command_line_string (JackCommandLineOptions& options, std::string& command_line);
|
||||
bool get_jack_command_line_string (JackCommandLineOptions& options, std::string& command_line, bool for_latency_measurement);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue