[SCM] jackd2 packaging branch, master, updated. debian/1.9.5.dfsg-13-23-gf46fc5b
adiknoth-guest at users.alioth.debian.org
adiknoth-guest at users.alioth.debian.org
Thu Jun 17 13:43:32 UTC 2010
The following commit has been merged in the master branch:
commit 5ca296918287986051b1453fbeafdf69e9a89040
Author: Adrian Knoth <adi at drcomp.erfurt.thur.de>
Date: Thu Jun 17 15:08:43 2010 +0200
Sync to upstream r4024
diff --git a/debian/patches/0000_sync_upstream_VCS.patch b/debian/patches/0000_sync_upstream_VCS.patch
index d4eccfd..f9f56ab 100644
--- a/debian/patches/0000_sync_upstream_VCS.patch
+++ b/debian/patches/0000_sync_upstream_VCS.patch
@@ -1,10 +1,10 @@
-Description: Sync with upstream SVN trunk revision 4008
+Description: Sync with upstream SVN trunk revision 4024
From: Jonas Smedegaard <dr at jones.dk>
Forwarded: yes
-Last-Update: 2010-05-07
+Last-Update: 2010-06-17
--- a/ChangeLog
+++ b/ChangeLog
-@@ -19,194 +19,243 @@
+@@ -19,194 +19,263 @@
Florian Faber
Michael Voigt
Torben Hohn
@@ -22,8 +22,35 @@ Last-Update: 2010-05-07
---------------------------
Jackdmp changes log
----------------------------
--
+---------------------------
+
+-2010-01-29 Gabriel M. Beddingfield <gabriel at teuton.org>
++2010-06-16 Stephane Letz <letz at grame.fr>
+
+- * Change JackEngineProfiling and JackAudioAdapterInterface gnuplot scripts to output SVG instead of PDF.
++ * David Garcia Garzon unused_pkt_buf_field_jack2 netone patch.
+
+-2009-12-15 Stephane Letz <letz at grame.fr>
++2010-06-13 Stephane Letz <letz at grame.fr>
+
+- * Shared memory manager was calling abort in case of fatal error, now return an error in caller.
++ * Fix JackPosixSemaphore::TimedWait : same behavior as JackPosixSemaphore::Wait regarding EINTR.
+
+-2009-12-13 Stephane Letz <letz at grame.fr>
++2010-05-31 Stephane Letz <letz at grame.fr>
+
+- * Mario Lang alsa_io time calculation overflow patch.
++ * Fix from Fernando Lopez-Lezcano for compilation on fc13.
+
+-2009-12-10 Stephane Letz <letz at grame.fr>
++2010-05-30 Stephane Letz <letz at grame.fr>
+
+- * Use a QUIT notification to properly quit the server channel, the server channel thread can then be 'stopped' instead of 'canceled'.
++ * David Garcia Garzon netone patch.
+
++2010-05-27 Stephane Letz <letz at grame.fr>
++
++ * In JackCoreAudioDriver, move code called in MeasureCallback to be called once in IO thread.
+
+2010-05-07 Stephane Letz <letz at grame.fr>
+
@@ -73,28 +100,20 @@ Last-Update: 2010-05-07
+
+ * Version 1.9.6 started.
+
- 2010-01-29 Gabriel M. Beddingfield <gabriel at teuton.org>
-
-- * Change JackEngineProfiling and JackAudioAdapterInterface gnuplot scripts to output SVG instead of PDF.
--
++2010-01-29 Gabriel M. Beddingfield <gabriel at teuton.org>
++
+ * Change JackEngineProfiling and JackAudioAdapterInterface gnuplot scripts to output SVG instead of PDF.
+
- 2009-12-15 Stephane Letz <letz at grame.fr>
-
-- * Shared memory manager was calling abort in case of fatal error, now return an error in caller.
--
++2009-12-15 Stephane Letz <letz at grame.fr>
++
+ * Shared memory manager was calling abort in case of fatal error, now return an error in caller.
+
- 2009-12-13 Stephane Letz <letz at grame.fr>
-
-- * Mario Lang alsa_io time calculation overflow patch.
--
++2009-12-13 Stephane Letz <letz at grame.fr>
++
+ * Mario Lang alsa_io time calculation overflow patch.
+
- 2009-12-10 Stephane Letz <letz at grame.fr>
-
-- * Use a QUIT notification to properly quit the server channel, the server channel thread can then be 'stopped' instead of 'canceled'.
--
++2009-12-10 Stephane Letz <letz at grame.fr>
++
+ * Use a QUIT notification to properly quit the server channel, the server channel thread can then be 'stopped' instead of 'canceled'.
+
2009-12-09 Stephane Letz <letz at grame.fr>
@@ -352,7 +371,7 @@ Last-Update: 2010-05-07
* Fix issues in JackNetDriver::DecodeTransportData and JackNetDriver::Initialize.
2009-08-28 Stephane Letz <letz at grame.fr>
-@@ -557,7 +606,7 @@
+@@ -557,7 +626,7 @@
2008-11-21 Stephane Letz <letz at grame.fr>
* Report ringbuffer.c fixes from JACK1.
@@ -507,6 +526,29 @@ Last-Update: 2010-05-07
#include <stdarg.h>
#include <stdio.h>
+@@ -27,17 +27,15 @@
+
+ using namespace Jack;
+
+-void change_thread_log_function(jack_log_function_t log_function)
++static bool change_thread_log_function(jack_log_function_t log_function)
+ {
+- if (!jack_tls_set(JackGlobals::fKeyLogFunction, (void*)log_function))
+- {
+- jack_error("failed to set thread log function");
+- }
++ return (jack_tls_get(JackGlobals::fKeyLogFunction) == NULL
++ && jack_tls_set(JackGlobals::fKeyLogFunction, (void*)log_function));
+ }
+
+-SERVER_EXPORT void set_threaded_log_function()
++SERVER_EXPORT int set_threaded_log_function()
+ {
+- change_thread_log_function(JackMessageBufferAdd);
++ return change_thread_log_function(JackMessageBufferAdd);
+ }
+
+ void jack_log_function(int level, const char *message)
--- a/common/JackError.h
+++ b/common/JackError.h
@@ -1,22 +1,21 @@
@@ -549,6 +591,18 @@ Last-Update: 2010-05-07
*/
+@@ -54,10 +53,9 @@
+
+ typedef void (* jack_log_function_t)(int level, const char *message);
+
+- void change_thread_log_function(jack_log_function_t log_function);
+ void jack_log_function(int level, const char *message);
+
+- SERVER_EXPORT void set_threaded_log_function();
++ SERVER_EXPORT int set_threaded_log_function();
+
+ #ifdef __cplusplus
+ }
--- a/common/JackGraphManager.cpp
+++ b/common/JackGraphManager.cpp
@@ -385,7 +385,7 @@
@@ -974,6 +1028,15 @@ Last-Update: 2010-05-07
semaphore_add (int value) {return 0;}
#else
+@@ -514,7 +512,7 @@
+
+ unlock:
+ jack_shm_unlock_registry ();
+- return 0;
++ return res;
+ }
+
+ /* release server_name registration */
@@ -534,7 +532,7 @@
}
}
@@ -985,37 +1048,57 @@ Last-Update: 2010-05-07
--- a/dbus/controller_iface_control.c
+++ b/dbus/controller_iface_control.c
-@@ -87,34 +87,31 @@
+@@ -1,6 +1,6 @@
+ /* -*- Mode: C ; c-basic-offset: 4 -*- */
+ /*
+- Copyright (C) 2007,2008 Nedko Arnaudov
++ Copyright (C) 2007,2008,2010 Nedko Arnaudov
+ Copyright (C) 2007-2008 Juuso Alasuutari
+
+ This program is free software; you can redistribute it and/or modify
+@@ -85,23 +85,37 @@
+ }
+ else if (strcmp (call->method_name, "StartServer") == 0)
{
- if (!jack_controller_start_server(controller_ptr, call))
+- if (!jack_controller_start_server(controller_ptr, call))
++ if (controller_ptr->started)
{
- jack_error ("Failed to start server");
-- }
-- else
-- {
-- jack_controller_control_send_signal_server_started();
-+ jack_dbus_error(call, JACK_DBUS_ERROR_GENERIC, "Failed to start server");
-+ return true;
++ jack_info("Ignoring JACK server start request because server is already started.");
}
+ else
+ {
++ if (!jack_controller_start_server(controller_ptr, call))
++ {
++ /* the reply is set by the failed function */
++ assert(call->reply != NULL);
++ return true;
++ }
+
-+ jack_controller_control_send_signal_server_started();
+ jack_controller_control_send_signal_server_started();
+ }
}
else if (strcmp (call->method_name, "StopServer") == 0)
{
- if (!jack_controller_stop_server(controller_ptr, call))
+- if (!jack_controller_stop_server(controller_ptr, call))
++ if (!controller_ptr->started)
{
- jack_error ("Failed to stop server");
-- }
-- else
-- {
-- jack_controller_control_send_signal_server_stopped();
-+ jack_dbus_error(call, JACK_DBUS_ERROR_GENERIC, "Failed to stop server");
-+ return true;
++ jack_info("Ignoring JACK server stop request because server is already stopped.");
}
+ else
+ {
++ if (!jack_controller_stop_server(controller_ptr, call))
++ {
++ /* the reply is set by the failed function */
++ assert(call->reply != NULL);
++ return true;
++ }
+
-+ jack_controller_control_send_signal_server_stopped();
+ jack_controller_control_send_signal_server_stopped();
+ }
}
- else if (strcmp (call->method_name, "SwitchMaster") == 0)
+@@ -109,12 +123,12 @@
{
if (!jack_controller_switch_master(controller_ptr, call))
{
@@ -1024,7 +1107,8 @@ Last-Update: 2010-05-07
- else
- {
- jack_controller_control_send_signal_server_stopped();
-+ jack_dbus_error(call, JACK_DBUS_ERROR_GENERIC, "Failed to switch master");
++ /* the reply is set by the failed function */
++ assert(call->reply != NULL);
+ return true;
}
+
@@ -1952,7 +2036,64 @@ Last-Update: 2010-05-07
--- a/macosx/coreaudio/JackCoreAudioDriver.cpp
+++ b/macosx/coreaudio/JackCoreAudioDriver.cpp
-@@ -922,7 +922,7 @@
+@@ -194,6 +194,22 @@
+ driver->fActionFags = ioActionFlags;
+ driver->fCurrentTime = (AudioTimeStamp *)inTimeStamp;
+ driver->fDriverOutputData = ioData;
++
++ // Setup threadded based log function once...
++ if (set_threaded_log_function()) {
++
++ jack_log("set_threaded_log_function");
++ JackMachThread::GetParams(pthread_self(), &driver->fEngineControl->fPeriod, &driver->fEngineControl->fComputation, &driver->fEngineControl->fConstraint);
++
++ if (driver->fComputationGrain > 0) {
++ jack_log("JackCoreAudioDriver::Render : RT thread computation setup to %d percent of period", int(driver->fComputationGrain * 100));
++ driver->fEngineControl->fComputation = driver->fEngineControl->fPeriod * driver->fComputationGrain;
++ }
++
++ // Signal waiting start function...
++ driver->fState = true;
++ }
++
+ driver->CycleTakeBeginTime();
+ return driver->Process();
+ }
+@@ -221,33 +237,6 @@
+ return 0;
+ }
+
+-// Will run only once
+-OSStatus JackCoreAudioDriver::MeasureCallback(AudioDeviceID inDevice,
+- const AudioTimeStamp* inNow,
+- const AudioBufferList* inInputData,
+- const AudioTimeStamp* inInputTime,
+- AudioBufferList* outOutputData,
+- const AudioTimeStamp* inOutputTime,
+- void* inClientData)
+-{
+- JackCoreAudioDriver* driver = (JackCoreAudioDriver*)inClientData;
+- AudioDeviceStop(driver->fDeviceID, MeasureCallback);
+-
+- jack_log("JackCoreAudioDriver::MeasureCallback called");
+- JackMachThread::GetParams(pthread_self(), &driver->fEngineControl->fPeriod, &driver->fEngineControl->fComputation, &driver->fEngineControl->fConstraint);
+-
+- if (driver->fComputationGrain > 0) {
+- jack_log("JackCoreAudioDriver::MeasureCallback : RT thread computation setup to %d percent of period", int(driver->fComputationGrain * 100));
+- driver->fEngineControl->fComputation = driver->fEngineControl->fPeriod * driver->fComputationGrain;
+- }
+-
+- // Signal waiting start function...
+- driver->fState = true;
+-
+- // Setup threadded based log function
+- set_threaded_log_function();
+- return noErr;
+-}
+
+ OSStatus JackCoreAudioDriver::SRNotificationCallback(AudioDeviceID inDevice,
+ UInt32 inChannel,
+@@ -922,7 +911,7 @@
if (GetDeviceIDFromUID(capture_driver_uid, &captureID) != noErr) {
jack_log("Will take default input");
if (GetDefaultInputDevice(&captureID) != noErr) {
@@ -1961,7 +2102,7 @@ Last-Update: 2010-05-07
return -1;
}
}
-@@ -930,7 +930,7 @@
+@@ -930,7 +919,7 @@
if (GetDeviceIDFromUID(playback_driver_uid, &playbackID) != noErr) {
jack_log("Will take default output");
if (GetDefaultOutputDevice(&playbackID) != noErr) {
@@ -1970,7 +2111,7 @@ Last-Update: 2010-05-07
return -1;
}
}
-@@ -945,7 +945,7 @@
+@@ -945,7 +934,7 @@
if (GetDeviceIDFromUID(capture_driver_uid, &fDeviceID) != noErr) {
jack_log("Will take default input");
if (GetDefaultInputDevice(&fDeviceID) != noErr) {
@@ -1979,7 +2120,7 @@ Last-Update: 2010-05-07
return -1;
}
}
-@@ -960,7 +960,7 @@
+@@ -960,7 +949,7 @@
if (GetDeviceIDFromUID(playback_driver_uid, &fDeviceID) != noErr) {
jack_log("Will take default output");
if (GetDefaultOutputDevice(&fDeviceID) != noErr) {
@@ -1988,7 +2129,7 @@ Last-Update: 2010-05-07
return -1;
}
}
-@@ -973,12 +973,29 @@
+@@ -973,12 +962,29 @@
} else {
jack_log("JackCoreAudioDriver::Open default driver");
if (GetDefaultDevice(&fDeviceID) != noErr) {
@@ -2024,7 +2165,52 @@ Last-Update: 2010-05-07
}
}
-@@ -1985,8 +2002,8 @@
+@@ -1665,27 +1671,10 @@
+ {
+ jack_log("JackCoreAudioDriver::Start");
+ JackAudioDriver::Start();
+-/*
+-#ifdef MAC_OS_X_VERSION_10_5
+- OSStatus err = AudioDeviceCreateIOProcID(fDeviceID, MeasureCallback, this, &fMesureCallbackID);
+-#else
+- OSStatus err = AudioDeviceAddIOProc(fDeviceID, MeasureCallback, this);
+-#endif
+-*/
+- OSStatus err = AudioDeviceAddIOProc(fDeviceID, MeasureCallback, this);
+-
+- if (err != noErr)
+- return -1;
+
+- err = AudioOutputUnitStart(fAUHAL);
++ OSStatus err = AudioOutputUnitStart(fAUHAL);
+ if (err != noErr)
+ return -1;
+-
+- if ((err = AudioDeviceStart(fDeviceID, MeasureCallback)) != noErr) {
+- jack_error("Cannot start MeasureCallback");
+- printError(err);
+- return -1;
+- }
+
+ // Waiting for Measure callback to be called (= driver has started)
+ fState = false;
+@@ -1707,15 +1696,6 @@
+ int JackCoreAudioDriver::Stop()
+ {
+ jack_log("JackCoreAudioDriver::Stop");
+- AudioDeviceStop(fDeviceID, MeasureCallback);
+-/*
+-#ifdef MAC_OS_X_VERSION_10_5
+- AudioDeviceDestroyIOProcID(fDeviceID, fMesureCallbackID);
+-#else
+- AudioDeviceRemoveIOProc(fDeviceID, MeasureCallback);
+-#endif
+-*/
+- AudioDeviceRemoveIOProc(fDeviceID, MeasureCallback);
+ return (AudioOutputUnitStop(fAUHAL) == noErr) ? 0 : -1;
+ }
+
+@@ -1985,8 +1965,8 @@
switch (param->character) {
case 'd':
@@ -2035,7 +2221,7 @@ Last-Update: 2010-05-07
break;
case 'D':
-@@ -2009,14 +2026,14 @@
+@@ -2009,14 +1989,14 @@
case 'C':
capture = true;
if (strcmp(param->value.str, "none") != 0) {
@@ -9393,7 +9579,15 @@ Last-Update: 2010-05-07
APPNAME='jack'
JACK_API_VERSION = '0.1.0'
-@@ -69,7 +69,10 @@
+@@ -62,6 +62,7 @@
+
+ opt.add_option('--libdir', type='string', help="Library directory [Default: <prefix>/lib]")
+ opt.add_option('--libdir32', type='string', help="32bit Library directory [Default: <prefix>/lib32]")
++ opt.add_option('--mandir', type='string', help="Manpage directory [Default: <prefix>/share/man/man1]")
+ opt.add_option('--dbus', action='store_true', default=False, help='Enable D-Bus JACK (jackdbus)')
+ opt.add_option('--classic', action='store_true', default=False, help='Force enable standard JACK (jackd) even if D-Bus JACK (jackdbus) is enabled too')
+ opt.add_option('--doxygen', action='store_true', default=False, help='Enable build of doxygen documentation')
+@@ -69,7 +70,10 @@
opt.add_option('--mixed', action='store_true', default=False, help='Build with 32/64 bits mixed mode')
opt.add_option('--clients', default=64, type="int", dest="clients", help='Maximum number of JACK clients')
opt.add_option('--ports-per-application', default=768, type="int", dest="application_ports", help='Maximum number of ports per application')
@@ -9405,7 +9599,7 @@ Last-Update: 2010-05-07
opt.sub_options('dbus')
def configure(conf):
-@@ -110,6 +113,15 @@
+@@ -110,6 +114,15 @@
conf.sub_config('common')
if conf.env['IS_LINUX']:
conf.sub_config('linux')
@@ -9421,6 +9615,35 @@ Last-Update: 2010-05-07
if Options.options.dbus:
conf.sub_config('dbus')
if conf.env['BUILD_JACKDBUS'] != True:
+@@ -151,6 +164,11 @@
+ else:
+ conf.env['LIBDIR'] = conf.env['PREFIX'] + '/lib'
+
++ if Options.options.libdir:
++ conf.env['MANDIR'] = conf.env['PREFIX'] + Options.options.mandir
++ else:
++ conf.env['MANDIR'] = conf.env['PREFIX'] + '/share/man/man1'
++
+ if conf.env['BUILD_DEBUG']:
+ conf.env.append_unique('CXXFLAGS', '-g')
+ conf.env.append_unique('CCFLAGS', '-g')
+@@ -230,6 +248,8 @@
+ print Logs.colors.NORMAL,
+ print
+
++ conf.env.append_unique('LINKFLAGS', '-lm -lstdc++')
++
+ if Options.options.mixed == True:
+ env_variant2 = conf.env.copy()
+ conf.set_env_name('lib32', env_variant2)
+@@ -255,6 +275,7 @@
+ bld.add_subdirs('linux')
+ bld.add_subdirs('example-clients')
+ bld.add_subdirs('tests')
++ bld.add_subdirs('man')
+ if bld.env['BUILD_JACKDBUS'] == True:
+ bld.add_subdirs('dbus')
+
--- a/common/JackDriverLoader.cpp
+++ b/common/JackDriverLoader.cpp
@@ -152,7 +152,7 @@
@@ -10544,7 +10767,7 @@ Last-Update: 2010-05-07
- fprintf (stderr, "could not load %s, status = 0x%2.0x\n",
- load_name, status);
+ fprintf (stderr, "could not load %s, intclient = %d status = 0x%2.0x\n",
-+ load_name, intclient, status);
++ load_name, (int)intclient, status);
return 2;
}
if (status & JackNameNotUnique) {
@@ -10657,3 +10880,1370 @@ Last-Update: 2010-05-07
/**
* try to register another one with the same name...
*
+--- a/common/Jackdmp.cpp
++++ b/common/Jackdmp.cpp
+@@ -85,7 +85,7 @@
+ {
+ fprintf(file, "jackdmp " VERSION "\n"
+ "Copyright 2001-2005 Paul Davis and others.\n"
+- "Copyright 2004-2009 Grame.\n"
++ "Copyright 2004-2010 Grame.\n"
+ "jackdmp comes with ABSOLUTELY NO WARRANTY\n"
+ "This is free software, and you are welcome to redistribute it\n"
+ "under certain conditions; see the file COPYING for details\n");
+--- a/common/JackPhysicalMidiInput.h
++++ b/common/JackPhysicalMidiInput.h
+@@ -120,7 +120,7 @@
+ public:
+
+ JackPhysicalMidiInput(size_t buffer_size=1024);
+- ~JackPhysicalMidiInput();
++ virtual ~JackPhysicalMidiInput();
+
+ /**
+ * Called to process MIDI data during a period.
+--- a/common/JackPhysicalMidiOutput.h
++++ b/common/JackPhysicalMidiOutput.h
+@@ -92,7 +92,7 @@
+
+ JackPhysicalMidiOutput(size_t non_rt_buffer_size=1024,
+ size_t rt_buffer_size=64);
+- ~JackPhysicalMidiOutput();
++ virtual ~JackPhysicalMidiOutput();
+
+ /**
+ * Called to process MIDI data during a period.
+--- a/common/netjack.c
++++ b/common/netjack.c
+@@ -564,6 +564,7 @@
+ netj->resample_factor = resample_factor;
+ netj->resample_factor_up = resample_factor_up;
+
++ netj->jitter_val = jitter_val;
+
+ return netj;
+ }
+@@ -734,7 +735,6 @@
+ }
+
+ netj->rx_bufsize = sizeof (jacknet_packet_header) + netj->net_period_down * netj->capture_channels * get_sample_size (netj->bitdepth);
+- netj->pkt_buf = malloc (netj->rx_bufsize);
+ global_packcache = packet_cache_new (netj->latency + 50, netj->rx_bufsize, netj->mtu);
+
+ netj->expected_framecnt_valid = 0;
+--- a/common/netjack.h
++++ b/common/netjack.h
+@@ -85,7 +85,6 @@
+ unsigned int handle_transport_sync;
+
+ unsigned int *rx_buf;
+- unsigned int *pkt_buf;
+ unsigned int rx_bufsize;
+ //unsigned int tx_bufsize;
+ unsigned int mtu;
+--- a/dbus/audio_reserve.c
++++ b/dbus/audio_reserve.c
+@@ -60,7 +60,7 @@
+ if (gConnection) {
+ dbus_connection_unref(gConnection);
+ gConnection = NULL;
+- jack_info("audio_reservation_finish");
++ jack_info("audio_reservation_finish");
+ }
+ return 0;
+ }
+--- a/dbus/controller.c
++++ b/dbus/controller.c
+@@ -1,6 +1,6 @@
+ /* -*- Mode: C ; c-basic-offset: 4 -*- */
+ /*
+- Copyright (C) 2007,2008 Nedko Arnaudov
++ Copyright (C) 2007,2008,2010 Nedko Arnaudov
+ Copyright (C) 2007-2008 Juuso Alasuutari
+
+ This program is free software; you can redistribute it and/or modify
+@@ -25,6 +25,7 @@
+ #include <stdint.h>
+ #include <string.h>
+ #include <dbus/dbus.h>
++#include <assert.h>
+
+ #include "controller.h"
+ #include "controller_internal.h"
+@@ -142,11 +143,7 @@
+
+ jack_info("Starting jack server...");
+
+- if (controller_ptr->started)
+- {
+- jack_info("Already started.");
+- return TRUE;
+- }
++ assert(!controller_ptr->started); /* should be ensured by caller */
+
+ if (controller_ptr->driver == NULL)
+ {
+@@ -171,7 +168,6 @@
+ if (controller_ptr->client == NULL)
+ {
+ jack_dbus_error(dbus_call_context_ptr, JACK_DBUS_ERROR_GENERIC, "failed to create dbusapi jack client");
+-
+ goto fail_stop_server;
+ }
+
+@@ -179,13 +175,12 @@
+ if (ret != 0)
+ {
+ jack_dbus_error(dbus_call_context_ptr, JACK_DBUS_ERROR_GENERIC, "failed to set xrun callback. error is %d", ret);
+-
+ goto fail_close_client;
+ }
+
+ if (!jack_controller_patchbay_init(controller_ptr))
+ {
+- jack_error("Failed to initialize patchbay district");
++ jack_dbus_error(dbus_call_context_ptr, JACK_DBUS_ERROR_GENERIC, "Failed to initialize patchbay district");
+ goto fail_close_client;
+ }
+
+@@ -193,7 +188,6 @@
+ if (ret != 0)
+ {
+ jack_dbus_error(dbus_call_context_ptr, JACK_DBUS_ERROR_GENERIC, "failed to activate dbusapi jack client. error is %d", ret);
+-
+ goto fail_patchbay_uninit;
+ }
+
+@@ -232,16 +226,12 @@
+
+ jack_info("Stopping jack server...");
+
+- if (!controller_ptr->started)
+- {
+- jack_info("Already stopped.");
+- return TRUE;
+- }
++ assert(controller_ptr->started); /* should be ensured by caller */
+
+ ret = jack_deactivate(controller_ptr->client);
+ if (ret != 0)
+ {
+- jack_dbus_error(dbus_call_context_ptr, JACK_DBUS_ERROR_GENERIC, "failed to deactivate dbusapi jack client. error is %d", ret);
++ jack_error("failed to deactivate dbusapi jack client. error is %d", ret);
+ }
+
+ jack_controller_patchbay_uninit(controller_ptr);
+@@ -256,6 +246,7 @@
+
+ if (!jackctl_server_stop(controller_ptr->server))
+ {
++ jack_dbus_error(dbus_call_context_ptr, JACK_DBUS_ERROR_GENERIC, "Failed to stop server");
+ return FALSE;
+ }
+
+--- a/macosx/coreaudio/JackCoreAudioDriver.h
++++ b/macosx/coreaudio/JackCoreAudioDriver.h
+@@ -96,14 +96,6 @@
+ UInt32 inNumberFrames,
+ AudioBufferList *ioData);
+
+- static OSStatus MeasureCallback(AudioDeviceID inDevice,
+- const AudioTimeStamp* inNow,
+- const AudioBufferList* inInputData,
+- const AudioTimeStamp* inInputTime,
+- AudioBufferList* outOutputData,
+- const AudioTimeStamp* inOutputTime,
+- void* inClientData);
+-
+ static OSStatus DeviceNotificationCallback(AudioDeviceID inDevice,
+ UInt32 inChannel,
+ Boolean isInput,
+--- /dev/null
++++ b/man/alsa_in.0
+@@ -0,0 +1,97 @@
++.TH ALSA_IO "1" "!DATE!" "!VERSION!"
++.SH NAME
++\fBalsa_in\fR, \fBalsa_out\fR \- Jack clients that perform I/O with an alternate audio interface
++.SH SYNOPSIS
++\fBalsa_in\fR [\fIoptions\fR]
++.br
++\fBalsa_out\fR [\fIoptions\fR]
++
++.SH DESCRIPTION
++A JACK client that opens a specified audio interface (different to the
++one used by the JACK server, if any) and moves audio data between its
++JACK ports and the interface. alsa_in will provide data from the
++interface (potentially for capture); alsa_out will deliver data to it
++(for playback).
++
++The audio interface used by alsa_in/alsa_out does not need to be
++synchronized with JACK backend (or the hardware it might be using).
++alsa_in/alsa_out tries to resample the output stream in an attempt to
++compensate for drift between the two clocks.
++
++As of jack-0.116.3 this works almost perfectly. It takes some time, to reach
++absolute resample-rate stability. So give it some minutes (its intended to be
++running permanently anyways)
++
++.SH OPTIONS
++.TP
++\fB\-j \fI jack_client_name\fR
++.br
++Set Client Name.
++.TP
++\fB\-d \fI alsa_device\fR
++.br
++Use this Soundcard.
++.TP
++\fB\-v\fR
++.br
++Verbose, prints out resample coefficient and other parameters useful for debugging, every 500ms.
++also reports soft xruns.
++.TP
++\fB\-i\fR
++.br
++Instrumentation. This logs the 4 important parameters of the samplerate control algorithm every 1ms.
++You can pipe this into a file, and plot it. Should only be necessary, if it does not work as
++expected, and we need to adjust some of the obscure parameters, to make it work.
++Find me on irc.freenode.org #jack in order to set this up correctly.
++.TP
++\fB\-c \fI channels\fR
++.br
++Set Number of channels.
++.TP
++\fB\-r \fI sample_rate\fR
++.br
++Set sample_rate. The program resamples as necessary.
++So you can connect a 44k1 jackd to a soundcard only supporting
++48k. (default is jack sample_rate)
++.TP
++\fB\-p \fI period_size\fR
++.br
++Set the period size. It is not related to the jackd period_size.
++Sometimes it affects the quality of the delay measurements.
++Setting this lower than the jackd period_size will only work, if you
++use a higher number of periods.
++.TP
++\fB\-n \fI num_period\fR
++.br
++Set number of periods. See note for period_size.
++.TP
++\fB\-q \fI quality\fR
++.br
++Set the quality of the resampler from 0 to 4. can significanly reduce cpu usage.
++.TP
++\fB\-m \fI max_diff\fR
++.br
++The value when a soft xrun occurs. Basically the window, in which
++the dma pointer may jitter. I don't think its necessary to play with this anymore.
++.TP
++\fB\-t \fI target_delay\fR
++.br
++The delay alsa_io should try to approach. Same as for max_diff. It will be setup based on \-p and \-n
++which is generally sufficient.
++.TP
++\fB\-s \fI smooth_array_size\fR
++.br
++This parameter controls the size of the array used for smoothing the delay measurement. Its default is 256.
++If you use a pretty low period size, you can lower the CPU usage a bit by decreasing this parameter.
++However most CPU time is spent in the resampling so this will not be much.
++.TP
++\fB\-C \fI P Control Clamp\fR
++.br
++If you have a PCI card, then the default value (15) of this parameter is too high for \-p64 \-n2... Setting it to 5 should fix that.
++Be aware that setting this parameter too low, lets the hf noise on the delay measurement come through onto the resamplerate, so this
++might degrade the quality of the output. (but its a threshold value, and it has been chosen, to mask the noise of a USB card,
++which has an amplitude which is 50 times higher than that of a PCI card, so 5 wont loose you any quality on a PCI card)
++
++.SH AUTHOR
++Torben Hohn
++
+--- /dev/null
++++ b/man/alsa_out.0
+@@ -0,0 +1 @@
++.so man1/alsa_in.1
+--- /dev/null
++++ b/man/fill_template
+@@ -0,0 +1,5 @@
++#!/bin/sh
++
++for i in *.0 ; do
++ sed -e "s/!VERSION!/${1}/g" -e "s/!DATE!/`date '+%B %Y'`/g" < ${i} > ${i%%0}1
++done
+--- /dev/null
++++ b/man/jack_bufsize.0
+@@ -0,0 +1,14 @@
++.TH JACK_BUFSIZE "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_bufsize \- JACK toolkit client to change the JACK buffer size
++.SH SYNOPSIS
++.B jack_bufsize bufsize
++.SH DESCRIPTION
++.B jack_bufsize
++jack_bufsize sets the size of the buffer (frames per period) used in JACK.
++This change happens on-line (the JACK server and its clients do not need to be
++restarted).
++.br
++When invoked without arguments, it prints the current bufsize, and exits.
++
++
+--- /dev/null
++++ b/man/jack_connect.0
+@@ -0,0 +1,11 @@
++.TH JACK_CONNECT "1" "!DATE!" "!VERSION!"
++.SH NAME
++\fBjack_connect\fR, \fBjack_disconnect\fR \- JACK toolkit clients for connecting & disconnecting ports
++.SH SYNOPSIS
++\fB jack_connect\fR [ \fI-s\fR | \fI--server servername\fR ] [\fI-h\fR | \fI--help\fR ] port1 port2
++\fB jack_disconnect\fR [ \fI-s\fR | \fI--server servername\fR ] [\fI-h\fR | \fI--help\fR ] port1 port2
++.SH DESCRIPTION
++\fBjack_connect\fR connects the two named ports. \fBjack_connect\fR disconnects the two named ports.
++.SH RETURNS
++The exit status is zero if successful, 1 otherwise
++
+--- /dev/null
++++ b/man/jackd.0
+@@ -0,0 +1,547 @@
++.TH "JACKD" "1" "!VERSION!" "!DATE!" ""
++.SH "NAME"
++jackd \- JACK Audio Connection Kit sound server
++.SH "SYNOPSIS"
++\fBjackd\fR [\fIoptions\fR] \fB\-d\fI backend \fR
++[\fIbackend\-parameters\fR]
++.br
++\fBjackd \-\-help\fR
++.SH "DESCRIPTION"
++\fBjackd\fR is the JACK audio server daemon, a low\-latency audio
++server. Originally written for the
++GNU/Linux operating system, it also supports Mac OS X and various Unix
++platforms. JACK can connect a number of different client applications
++to an audio device and also to each other. Most clients are external,
++running in their own processes as normal applications. JACK also
++supports internal clients, which run within the \fBjackd\fR process
++using a loadable "plugin" interface.
++
++JACK differs from other audio servers in being designed from the
++ground up for professional audio work. It focuses on two key areas:
++synchronous execution of all clients, and low latency operation.
++
++For the latest JACK information, please consult the web site,
++<\fBhttp://www.jackaudio.org\fR>.
++.SH "OPTIONS"
++.TP
++\fB\-d, \-\-driver \fIbackend\fR [\fIbackend\-parameters\fR ]
++.br
++Select the audio interface backend. The current list of supported
++backends is: \fBalsa\fR, \fBcoreaudio\fR, \fBdummy\fR, \fBfreebob\fR,
++\fBoss\fR \fBsun\fR and \fBportaudio\fR. They are not all available
++on all platforms. All \fIbackend\-parameters\fR are optional.
++
++.TP
++\fB\-h, \-\-help\fR
++.br
++Print a brief usage message describing the main \fBjackd\fR options.
++These do not include \fIbackend\-parameters\fR, which are listed using
++the \fB\-\-help\fR option for each specific backend. Examples below
++show how to list them.
++.TP
++\fB\-m, \-\-no\-mlock\fR
++Do not attempt to lock memory, even if \fB\-\-realtime\fR.
++.TP
++\fB\-n, \-\-name\fR \fIserver\-name\fR
++Name this \fBjackd\fR instance \fIserver\-name\fR. If unspecified,
++this name comes from the \fB$JACK_DEFAULT_SERVER\fR environment
++variable. It will be "default" if that is not defined.
++.TP
++\fB\-p, \-\-port\-max \fI n\fR
++Set the maximum number of ports the JACK server can manage.
++The default value is 256.
++.TP
++\fB\-\-replace-registry\fR
++.br
++Remove the shared memory registry used by all JACK server instances
++before startup. This should rarely be used, and is intended only
++for occasions when the structure of this registry changes in ways
++that are incompatible across JACK versions (which is rare).
++.TP
++\fB\-R, \-\-realtime\fR
++.br
++Use realtime scheduling (default = true). This is needed for reliable low\-latency
++performance. On many systems, it requires \fBjackd\fR to run with
++special scheduler and memory allocation privileges, which may be
++obtained in several ways.
++.TP
++\fB\-r, \-\-no-realtime\fR
++.br
++Do not use realtime scheduling.
++.TP
++\fB\-P, \-\-realtime\-priority \fIint\fR
++When running \fB\-\-realtime\fR, set the scheduler priority to
++\fIint\fR.
++.TP
++\fB\-\-silent\fR
++Silence any output during operation.
++.TP
++\fB\-T, \-\-temporary\fR
++Exit once all clients have closed their connections.
++.TP
++\fB\-t, \-\-timeout \fIint\fR
++.br
++Set client timeout limit in milliseconds. The default is 500 msec.
++In realtime mode the client timeout must be smaller than the watchdog timeout (5000 msec).
++.TP
++\fB\-Z, \-\-nozombies\fR
++.br
++Prevent JACK from ever kicking out clients because they were too slow.
++This cancels the effect any specified timeout value, but JACK and its clients are
++still subject to the supervision of the watchdog thread or its equivalent.
++.TP
++\fB\-u, \-\-unlock\fR
++.br
++Unlock libraries GTK+, QT, FLTK, Wine.
++.TP
++\fB\-v, \-\-verbose\fR
++Give verbose output.
++.TP
++\fB\-c, \-\-clocksource\fR (\fI c(ycle)\fR | \fI h(pet) \fR | \fI s(ystem) \fR)
++Select a specific wall clock (Cycle Counter, HPET timer, System timer).
++.TP
++\fB\-V, \-\-version\fR
++Print the current JACK version number and exit.
++.SS ALSA BACKEND OPTIONS
++.TP
++\fB\-C, \-\-capture\fR [ \fIname\fR ]
++Provide only capture ports, unless combined with \-D or \-P. Parameterally set
++capture device name.
++.TP
++\fB\-d, \-\-device \fIname\fR
++.br
++The ALSA pcm device \fIname\fR to use. If none is specified, JACK will
++use "hw:0", the first hardware card defined in \fB/etc/modules.conf\fR.
++.TP
++\fB\-z, \-\-dither [rectangular,triangular,shaped,none]
++Set dithering mode. If \fBnone\fR or unspecified, dithering is off.
++Only the first letter of the mode name is required.
++.TP
++\fB\-D, \-\-duplex\fR
++Provide both capture and playback ports. Defaults to on unless only one
++of \-P or \-C is specified.
++.TP
++\fB\-h, \-\-help\fR Print a brief usage message describing only the
++\fBalsa\fR backend parameters.
++.TP
++\fB\-M, \-\-hwmeter\fR
++.br
++Enable hardware metering for devices that support it. Otherwise, use
++software metering.
++.TP
++\fB\-H, \-\-hwmon\fR
++.br
++Enable hardware monitoring of capture ports. This is a method for
++obtaining "zero latency" monitoring of audio input. It requires
++support in hardware and from the underlying ALSA device driver.
++
++When enabled, requests to monitor capture ports will be satisfied by
++creating a direct signal path between audio interface input and output
++connectors, with no processing by the host computer at all. This
++offers the lowest possible latency for the monitored signal.
++
++Presently (March 2003), only the RME Hammerfall series and cards based
++on the ICE1712 chipset (M\-Audio Delta series, Terratec, and others)
++support \fB\-\-hwmon\fR. In the future, some consumer cards may also
++be supported by modifying their mixer settings.
++
++Without \fB\-\-hwmon\fR, port monitoring requires JACK to read audio
++into system memory, then copy it back out to the hardware again,
++imposing the basic JACK system latency determined by the
++\fB\-\-period\fR and \fB\-\-nperiods\fR parameters.
++.TP
++\fB\-i, \-\-inchannels \fIint\fR
++.br
++Number of capture channels. Default is maximum supported by hardware.
++.TP
++\fB\-n, \-\-nperiods \fIint\fR
++.br
++Specify the number of periods of playback latency. In seconds, this
++corresponds to \fB\-\-nperiods\fR times \fB\-\-period\fR divided by
++\fB\-\-rate\fR. The default is 2, the minimum allowable. For most
++devices, there is no need for any other value with the
++\fB\-\-realtime\fR option. Without realtime privileges or with boards
++providing unreliable interrupts (like ymfpci), a larger value may
++yield fewer xruns. This can also help if the system is not tuned for
++reliable realtime scheduling.
++
++For most ALSA devices, the hardware buffer has exactly
++\fB\-\-period\fR times \fB\-\-nperiods\fR frames. Some devices demand
++a larger buffer. If so, JACK will use the smallest possible buffer
++containing at least \fB\-\-nperiods\fR, but the playback latency does
++not increase.
++
++For USB audio devices it is recommended to use \fB\-n 3\fR. Firewire
++devices supported by FFADO (formerly Freebob) are configured with
++\fB\-n 3\fR by default.
++.TP
++\fB\-o, \-\-outchannels \fIint\fR
++.br
++Number of playback channels. Default is maximum supported by hardware.
++.TP
++\fB\-P, \-\-playback\fR [ \fIname\fR ]
++Provide only playback ports, unless combined with \-D or \-C. Optionally set
++playback device name.
++.TP
++\fB\-p, \-\-period \fIint\fR
++.br
++Specify the number of frames between JACK \fBprocess()\fR calls. This
++value must be a power of 2, and the default is 1024. If you need low
++latency, set \fB\-p\fR as low as you can go without seeing xruns. A larger
++period size yields higher latency, but makes xruns less likely. The JACK
++capture latency in seconds is \fB\-\-period\fR divided by \fB\-\-rate\fR.
++.TP
++\fB\-r, \-\-rate \fIint\fR
++Specify the sample rate. The default is 48000.
++.TP
++\fB\-S, \-\-shorts
++.br
++Try to configure card for 16\-bit samples first, only trying 32\-bits if
++unsuccessful. Default is to prefer 32\-bit samples.
++.TP
++\fB\-s, \-\-softmode\fR
++.br
++Ignore xruns reported by the ALSA driver. This makes JACK less likely
++to disconnect unresponsive ports when running without \fB\-\-realtime\fR.
++.TP
++\fB\-X, \-\-midi \fR[\fIseq\fR|\fIraw\fR]
++.br
++Specify which ALSA MIDI system to provide access to. Using \fBraw\fR
++will provide a set of JACK MIDI ports that correspond to each raw ALSA
++device on the machine. Using \fBseq\fR will provide a set of JACK MIDI
++ports that correspond to each ALSA "sequencer" client (which includes
++each hardware MIDI port on the machine). \fBraw\fR provides slightly
++better performance but does not permit JACK MIDI communication with
++software written to use the ALSA "sequencer" API.
++.SS COREAUDIO BACKEND PARAMETERS
++.TP
++\fB\-c \-\-channel\fR
++Maximum number of channels (default: 2)
++.TP
++\fB\-i \-\-channelin\fR
++Maximum number of input channels (default: 2)
++.TP
++\fB\-o \-\-channelout\fR
++Maximum number of output channels (default: 2)
++.TP
++\fB\-C \-\-capture\fR
++Whether or not to capture (default: true)
++.TP
++\fB\-P \-\-playback\fR
++Whether or not to playback (default: true)
++.TP
++\fB\-D \-\-duplex\fR
++Capture and playback (default: true)
++.TP
++\fB\-r \-\-rate\fR
++Sample rate (default: 44100)
++.TP
++\fB\-p \-\-period\fR
++Frames per period (default: 128). Must be a power of 2.
++.TP
++\fB\-n \-\-name\fR
++Driver name (default: none)
++.TP
++\fB\-I \-\-id\fR
++Audio Device ID (default: 0)
++.SS DUMMY BACKEND PARAMETERS
++.TP
++\fB\-C, \-\-capture \fIint\fR
++Specify number of capture ports. The default value is 2.
++.TP
++\fB\-P, \-\-playback \fIint\fR
++Specify number of playback ports. The default value is 2.
++.TP
++\fB\-r, \-\-rate \fIint\fR
++Specify sample rate. The default value is 48000.
++.TP
++\fB\-p, \-\-period \fIint\fR
++Specify the number of frames between JACK \fBprocess()\fR calls. This
++value must be a power of 2, and the default is 1024. If you need low
++latency, set \fB\-p\fR as low as you can go without seeing xruns. A larger
++period size yields higher latency, but makes xruns less likely. The JACK
++capture latency in seconds is \fB\-\-period\fR divided by \fB\-\-rate\fR.
++.TP
++\fB\-w, \-\-wait \fIint\fR
++Specify number of usecs to wait between engine processes.
++The default value is 21333.
++
++
++.SS NET BACKEND PARAMETERS
++
++.TP
++ \fB\-i, \-\-audio\-ins \fIint\fR
++Number of capture channels (default: 2)
++.TP
++ \fB\-o, \-\-audio\-outs \fIint\fR
++Number of playback channels (default: 2)
++.TP
++ \fB\-I, \-\-midi\-ins \fIint\fR
++Number of midi capture channels (default: 1)
++.TP
++\fB\-O, \-\-midi\-outs \fIint\fR
++Number of midi playback channels (default: 1)
++.TP
++ \fB\-r, \-\-rate \fIint\fR
++Sample rate (default: 48000)
++.TP
++\fB\-p, \-\-period \fIint\fR
++Frames per period (default: 1024)
++.TP
++\fB\-n, \-\-num\-periods \fIint\fR
++Network latency setting in no. of periods (default: 5)
++.TP
++\fB\-l, \-\-listen\-port \fIint\fR
++The socket port we are listening on for sync packets (default: 3000)
++.TP
++\fB\-f, \-\-factor \fIint\fR
++Factor for sample rate reduction (default: 1)
++.TP
++\fB\-u, \-\-upstream\-factor \fIint\fR
++Factor for sample rate reduction on the upstream (default: 0)
++.TP
++\fB\-c, \-\-celt \fIint\fR
++sets celt encoding and number of kbits per channel (default: 0)
++.TP
++\fB\-b, \-\-bit\-depth \fIint\fR
++Sample bit\-depth (0 for float, 8 for 8bit and 16 for 16bit) (default: 0)
++.TP
++\fB\-t, \-\-transport\-sync \fIint\fR
++Whether to slave the transport to the master transport (default: true)
++.TP
++\fB\-a, \-\-autoconf \fIint\fR
++Whether to use Autoconfig, or just start. (default: true)
++.TP
++\fB\-R, \-\-redundancy \fIint\fR
++Send packets N times (default: 1)
++.TP
++\fB\-e, \-\-native\-endian \fIint\fR
++Dont convert samples to network byte order. (default: false)
++.TP
++\fB\-J, \-\-jitterval \fIint\fR
++attempted jitterbuffer microseconds on master (default: 0)
++.TP
++\fB\-D, \-\-always\-deadline \fIint\fR
++always use deadline (default: false)
++
++
++.SS OSS BACKEND PARAMETERS
++.TP
++\fB\-r, \-\-rate \fIint\fR
++Specify the sample rate. The default is 48000.
++.TP
++\fB\-p, \-\-period \fIint\fR
++Specify the number of frames between JACK \fBprocess()\fR calls. This
++value must be a power of 2, and the default is 1024. If you need low
++latency, set \fB\-p\fR as low as you can go without seeing xruns. A larger
++period size yields higher latency, but makes xruns less likely. The JACK
++capture latency in seconds is \fB\-\-period\fR divided by \fB\-\-rate\fR.
++.TP
++\fB\-n, \-\-nperiods \fIint\fR
++Specify the number of periods in the hardware buffer. The default is
++2. The period size (\fB\-p\fR) times \fB\-\-nperiods\fR times four is
++the JACK buffer size in bytes. The JACK output latency in seconds is
++\fB\-\-nperiods\fR times \fB\-\-period\fR divided by \fB\-\-rate\fR.
++.TP
++\fB\-w, \-\-wordlength \fIint\fR
++Specify the sample size in bits. The default is 16.
++.TP
++\fB\-i, \-\-inchannels \fIint\fR
++Specify how many channels to capture (default: 2)
++.TP
++\fB\-o, \-\-outchannels \fIint\fR
++Specify number of playback channels (default: 2)
++.TP
++\fB\-C, \-\-capture \fIdevice_file\fR
++Specify input device for capture (default: /dev/dsp)
++.TP
++\fB\-P, \-\-playback \fIdevice_file\fR
++Specify output device for playback (default: /dev/dsp)
++.TP
++\fB\-b, \-\-ignorehwbuf \fIboolean\fR
++Specify, whether to ignore hardware period size (default: false)
++.SS SUN BACKEND PARAMETERS
++.TP
++\fB\-r, \-\-rate \fIint\fR
++Specify the sample rate. The default is 48000.
++.TP
++\fB\-p, \-\-period \fIint\fR
++Specify the number of frames between JACK \fBprocess()\fR calls. This
++value must be a power of 2, and the default is 1024. If you need low
++latency, set \fB\-p\fR as low as you can go without seeing xruns. A larger
++period size yields higher latency, but makes xruns less likely. The JACK
++capture latency in seconds is \fB\-\-period\fR divided by \fB\-\-rate\fR.
++.TP
++\fB\-n, \-\-nperiods \fIint\fR
++Specify the number of periods in the hardware buffer. The default is
++2. The period size (\fB\-p\fR) times \fB\-\-nperiods\fR times four
++(assuming 2 channels 16-bit samples) is the JACK buffer size in bytes.
++The JACK output latency in seconds is \fB\-\-nperiods\fR times
++\fB\-\-period\fR divided by \fB\-\-rate\fR.
++.TP
++\fB\-w, \-\-wordlength \fIint\fR
++Specify the sample size in bits. The default is 16.
++.TP
++\fB\-i, \-\-inchannels \fIint\fR
++Specify how many channels to capture (default: 2)
++.TP
++\fB\-o, \-\-outchannels \fIint\fR
++Specify number of playback channels (default: 2)
++.TP
++\fB\-C, \-\-capture \fIdevice_file\fR
++Specify input device for capture (default: /dev/audio)
++.TP
++\fB\-P, \-\-playback \fIdevice_file\fR
++Specify output device for playback (default: /dev/audio)
++.TP
++\fB\-b, \-\-ignorehwbuf \fIboolean\fR
++Specify, whether to ignore hardware period size (default: false)
++.SS PORTAUDIO BACKEND PARAMETERS
++.TP
++\fB\-c \-\-channel\fR
++Maximum number of channels (default: all available hardware channels)
++.TP
++\fB\-i \-\-channelin\fR
++Maximum number of input channels (default: all available hardware channels)
++.TP
++\fB\-o \-\-channelout\fR
++Maximum number of output channels (default: all available hardware channels)
++.TP
++\fB\-C \-\-capture\fR
++Whether or not to capture (default: true)
++.TP
++\fB\-P \-\-playback\fR
++Whether or not to playback (default: true)
++.TP
++\fB\-D \-\-duplex\fR
++Capture and playback (default: true)
++.TP
++\fB\-r \-\-rate\fR
++Sample rate (default: 48000)
++.TP
++\fB\-p \-\-period\fR
++Frames per period (default: 1024). Must be a power of 2.
++.TP
++\fB\-n \-\-name\fR
++Driver name (default: none)
++.TP
++\fB\-z \-\-dither\fR
++Dithering mode (default: none)
++.SH "EXAMPLES"
++.PP
++Print usage message for the parameters specific to each backend.
++.IP
++\fBjackd \-d alsa \-\-help\fR
++.br
++\fBjackd \-d coreaudio \-\-help\fR
++.br
++\fBjackd \-d net \-\-help\fR
++.br
++\fBjackd \-d dummy \-\-help\fR
++.br
++\fBjackd \-d firewire \-\-help\fR
++.br
++\fBjackd \-d freebob \-\-help\fR
++.br
++\fBjackd \-d oss \-\-help\fR
++.br
++\fBjackd \-d sun \-\-help\fR
++.br
++\fBjackd \-d portaudio \-\-help\fR
++.PP
++Run the JACK daemon with realtime priority using the first ALSA
++hardware card defined in \fB/etc/modules.conf\fR.
++.IP
++\fBjackstart \-\-realtime \-\-driver=alsa\fR
++.PP
++Run the JACK daemon with low latency giving verbose output, which can
++be helpful for trouble\-shooting system latency problems. A
++reasonably well\-tuned system with a good sound card and a
++low\-latency kernel can handle these values reliably. Some can do
++better. If you get xrun messages, try a larger buffer. Tuning a
++system for low latency can be challenging. The JACK FAQ,
++.I http://jackit.sourceforge.net/docs/faq.php\fR
++has some useful suggestions.
++.IP
++\fBjackstart \-Rv \-d alsa \-p 128 \-n 2 \-r 44100\fR
++.PP
++Run \fBjackd\fR with realtime priority using the "sblive" ALSA device
++defined in ~/.asoundrc. Apply shaped dithering to playback audio.
++.IP
++\fBjackd \-R \-d alsa \-d sblive \-\-dither=shaped\fR
++.PP
++Run \fBjackd\fR with no special privileges using the second ALSA
++hardware card defined in \fB/etc/modules.conf\fR. Any xruns reported
++by the ALSA backend will be ignored. The larger buffer helps reduce
++data loss. Rectangular dithering will be used for playback.
++.IP
++\fBjackd \-d alsa \-d hw:1 \-p2048 \-n3 \-\-softmode \-zr\fR
++.PP
++Run \fBjackd\fR in full\-duplex mode using the ALSA hw:0,0 device for
++playback and the hw:0,2 device for capture.
++.IP
++\fBjackd \-d alsa \-P hw:0,0 \-C hw:0,2\fR
++.PP
++Run \fBjackd\fR in playback\-only mode using the ALSA hw:0,0 device.
++.IP
++\fBjackd \-d alsa \-P hw:0,0\fR
++.SH "ENVIRONMENT"
++.br
++JACK is evolving a mechanism for automatically starting the server
++when needed. Any client started without a running JACK server will
++attempt to start one itself using the command line found in the first
++line of \fB$HOME/.jackdrc\fR if it exists, or \fB/etc/jackdrc\fR if it
++does not. If neither file exists, a built\-in default command will be
++used, including the \fB\-T\fR flag, which causes the server to shut
++down when all clients have exited.
++
++As a transition, this only happens when \fB$JACK_START_SERVER\fR is
++defined in the environment of the calling process. In the future this
++will become normal behavior. In either case, defining
++\fB$JACK_NO_START_SERVER\fR disables this feature.
++
++To change where JACK looks for the backend drivers, set
++\fB$JACK_DRIVER_DIR\fR.
++
++\fB$JACK_DEFAULT_SERVER\fR specifies the default server name. If not
++defined, the string "default" is used. If set in their respective
++environments, this affects \fBjackd\fR unless its \fB\-\-name\fR
++parameter is set, and all JACK clients unless they pass an explicit
++name to \fBjack_client_open()\fR.
++
++.SH "SEE ALSO:"
++.PP
++.I http://www.jackaudio.org
++.br
++The official JACK website with news, docs and a list of JACK clients.
++.PP
++.I http://jackaudio.org/email
++.br
++The JACK developers' mailing list. Subscribe, to take part in
++development of JACK or JACK clients. User questions are also welcome,
++there is no user-specific mailing list.
++.PP
++.I http://www.jackosx.com/
++.br
++Tools specific to the Mac OS X version of JACK.
++.PP
++.I http://www.alsa\-project.org
++.br
++The Advanced Linux Sound Architecture.
++.SH "BUGS"
++Please report bugs to
++.br
++.I http://trac.jackaudio.org/
++.SH "AUTHORS"
++Architect and original implementor: Paul Davis
++.PP
++Original design Group: Paul Davis, David Olofson, Kai Vehmanen, Benno Sennoner,
++Richard Guenther, and other members of the Linux Audio Developers group.
++.PP
++Programming: Paul Davis, Jack O'Quin, Taybin Rutkin, Stephane Letz, Fernando
++Pablo Lopez-Lezcano, Steve Harris, Jeremy Hall, Andy Wingo, Kai
++Vehmanen, Melanie Thielker, Jussi Laako, Tilman Linneweh, Johnny
++Petrantoni, Torben Hohn.
++.PP
++Manpage written by Stefan Schwandter, Jack O'Quin and Alexandre
++Prokoudine.
+--- /dev/null
++++ b/man/jack_disconnect.0
+@@ -0,0 +1 @@
++.so man1/jack_connect.1
+--- /dev/null
++++ b/man/jack_freewheel.0
+@@ -0,0 +1,16 @@
++.TH JACK_FREEWHEEL "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_freewheel \- JACK toolkit client to control freewheeling mode
++.SH SYNOPSIS
++.B jack_freewheel [y|n]
++.SH DESCRIPTION
++.B jack_freewheel
++Turns freewheeling mode on (y) or off (n). While in freewheeling mode,
++the JACK server does not wait in between process() calls, and does not
++read or write data from/to any audio interface. That results in the JACK graph
++processing data as fast as possible. Freewheeling makes fast exports to
++files possible.
++.PP
++There is no useful reason to use this tool other than testing. JACK
++clients that use freewheeling will turn it on and off themselves.
++
+--- /dev/null
++++ b/man/jack_impulse_grabber.0
+@@ -0,0 +1,11 @@
++.TH JACK_IMPULSE_GRABBER "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_impulse_grabber \- JACK toolkit client to grab an impulse (response)
++.SH SYNOPSIS
++\fBjack_impulse_grabber\fR \fB-d\fR \fIduration\fR [\fI-f\fR (C|gnuplot)]
++.SH DESCRIPTION
++\fBjack_impulse_grabber\fR is a JACK example client for collecting
++impulses recordings from JACK ports.
++
++
++
+--- /dev/null
++++ b/man/jack_load.0
+@@ -0,0 +1,28 @@
++.TH JACK_LOAD "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_load \- JACK toolkit client for loading in-process clients
++.SH SYNOPSIS
++\fBjack_load\fR [ \fI-i\fR initstring ] [ \fI-s\fR servername ] [\fI-w\fR ] client-name so-name [ initstring ]
++.SH DESCRIPTION
++\fBjack_load\fR is a JACK toolkit client. It loads the specified plugin and creates an in-process client.
++.SH ARGUMENTS
++.PP
++The client-name must be a currently unused client name.
++.PP
++The so-name is the name of file that client code is stored in (typically, \fIclientname.so\fR)
++.SH OPTIONS
++.TP
++\fB-i\fR, \fB--init\fR init-string
++.br
++initialization string passed to the in-process client. Note that this can also be specified as the last argument on the command line.
++.TP
++\fB-s\fR, \fB--server\fR servername
++.br
++Name of JACK server to connect to
++.TP
++\fB-w\fR, \fB--wait\fR
++Wait for a signal (eg. from Ctrl-c) and then unload the client.
++.SH AUTHOR
++Jeremy Hall
++
++
+--- /dev/null
++++ b/man/jack_lsp.0
+@@ -0,0 +1,47 @@
++.TH JACK_LSP "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_lsp \- JACK toolkit client to list informtion on ports
++.SH SYNOPSIS
++\fBjack_lsp\fR [ \fI-s\fR | \fI--server\fR servername ] [ \fI-AclLptvh\fR ]
++.SH DESCRIPTION
++\fBjack_lsp\fR lists all known ports associated with a JACK
++server. It can also optionally list various kinds of information about each port.
++.SH OPTIONS
++.TP
++\fB-s\fR, \fB--server\fR \fIservername\fR
++.br
++Connect to the jack server named \fIservername\fR
++.TP
++\fB-A\fR, \fB--aliases\fR
++.br
++List aliases for each port
++.TP
++\fB-c\fR, \fB--connections\fR
++.br
++List connections to/from each port
++.TP
++\fB-l\fR, \fB--latency\fR
++.br
++Display per-port latency in frames at each port
++.TP
++\fB-L\fR, \fI--latency\fR
++.br
++Display total latency in frames at each port
++.TP
++\fB-p\fR, \fB--properties\fR
++.br
++Display port properties. Output may include input|output, can-monitor, physical, terminal
++.TP
++\fB-t\fR, \fB--type\fR
++.br
++Display port type
++.TP
++\fB-h\fR, \fB--help\fR
++.br
++Display help/usage message
++.TP
++\fB-v\fR, \fB--version\fR
++.br
++Output version information and exit
++
++
+--- /dev/null
++++ b/man/jack_metro.0
+@@ -0,0 +1,40 @@
++.TH JACK_METRO "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_metro \- JACK toolkit metronome
++.SH SYNOPSIS
++\fBjack_metro\fR [ \fI-n\fR name ] [ \fI-f\fR hz ] [ \fI-D\fR msecs ] [\fI-a\fR % ] [ \fI-d\fR % ] \fI-b\fR bpm
++.SH DESCRIPTION
++\fBjack_metro\fR is a simple metronome for JACK. It generates a
++synthetic "tick" sound for every beat. Note that is does \fBnot\fR
++connect its output port by default - to hear the sound it makes you must
++connect them using some other tool.
++.SH OPTIONS
++.TP
++\fB-n\fR, \fB--name\fR
++.br
++Specify a name for this instance of the metronome.
++.TP
++\fB-f\fR, \fB--frequency\fR Hz
++.br
++Define the frequency of the "tick" in Hz.
++.TP
++\fB-D\fR, \fB--duration\fR msecs
++.br
++Define the duration of the "tick" in milliseconds.
++.TP
++\fB-a\fR, \fB--attack\fR %-age
++.br
++Define the duration of the attack phase of the "tick" as a percentage
++of the duration.
++.TP
++\fB-d\fR, \fB--decay\fR %-age
++.br
++Define the duration of the decay phase of the "tick" as a percentage
++of the duration.
++.TP
++\fB--b\fR, \fB--bpm\fR bpm
++.br
++Define the number of beats per minute.
++.SH AUTHOR
++Anthony Van Groningen
++
+--- /dev/null
++++ b/man/jack_monitor_client.0
+@@ -0,0 +1,18 @@
++.TH JACK_CONNECT "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_monitor_client \- The JACK Audio Connection Kit example client
++.SH SYNOPSIS
++.B jack_monitor_client
++client-name
++.PP
++The client-name must be the name of a existing client that monitoring is
++to be enabled for.
++.SH DESCRIPTION
++.B jack_monitor_client
++is an example client for the JACK Audio Connection Kit. It enables
++monitoring for the specified client.
++.SH AUTHOR
++Jeremy Hall
++.PP
++This manpage was written by Robert Jordens <jordens at debian.org> for Debian.
++
+--- /dev/null
++++ b/man/jack_netsource.0
+@@ -0,0 +1,109 @@
++.TH JACK_NETSOURCE "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_netsource \- Netjack Master client for one slave
++.SH SYNOPSIS
++\fBjack_netsource\fR [ \fI-H\fR hostname ] [ \fIoptions\fR ]
++
++.SH DESCRIPTION
++\fBjack_netsource\fR The Master side of a netjack connection. Represents the slave jackd -dnet in the master jack graph.
++Most connection parameters are configured via the netsource, and the slave will set itself up according to the commandline
++option given to jack_netsource.
++.br
++Netjack allows low latency audio connections over general IP networks. When using celt for compression, it is even possible
++to establish transatlantic links, with latencies not much over the actual ping time.
++.br
++But the main usecase is of course a LAN, where it can achieve one jack period of latency.
++
++.SH OPTIONS
++.TP
++\fB-h\fR this help text
++.TP
++\fB-H\fR \fIslave host\fR
++.br
++Host name of the slave JACK
++.TP
++\fB-o\fR \fInum channels\fR
++.br
++Number of audio playback channels
++.TP
++\fB-i\fR \fInum channels\fR
++.br
++Number of audio capture channels
++.TP
++\fB-O\fR \fInum channels\fR
++.br
++Number of midi playback channels
++.TP
++\fB-I\fR \fInum channels\fR
++.br
++Number of midi capture channels
++.TP
++\fB-n\fR \fIperiods\fR
++.br
++Network latency in JACK periods
++.TP
++\fB-p\fR \fIport\fR
++.br
++UDP port that the slave is listening on
++.TP
++\fB-r\fR \fIreply port\fR
++.br
++UDP port that we are listening on
++.TP
++\fB-B\fR \fIbind port\fR
++.br
++reply port, for use in NAT environments
++.TP
++\fB-b\fR \fIbitdepth\fR
++.br
++Set transport to use 16bit or 8bit
++.TP
++\fB-c\fR \fIbytes\fR
++.br
++Use CELT encoding with <bytes> per period and channel
++.TP
++\fB-m\fR \fImtu\fR
++.br
++Assume this mtu for the link
++.TP
++\fB-R\fR \fIN\fR
++.br
++Redundancy: send out packets N times.
++.TP
++\fB-e\fR
++.br
++skip host-to-network endianness conversion
++.TP
++\fB-N\fR \fIjack name\fR
++.br
++Reports a different client name to jack
++.TP
++.TP
++\fB-s\fR, \fB--server\fR \fIservername\fR
++.br
++Connect to the jack server named \fIservername\fR
++.TP
++\fB-h\fR, \fB--help\fR
++.br
++Display help/usage message
++.TP
++\fB-v\fR, \fB--version\fR
++.br
++Output version information and exit
++
++
++.SH EXAMPLES
++
++.PP
++run a 4 audio channel bidirectional link with one period of latency and no midi channels. Audio data is flowing uncompressed over the wire:
++.br
++On \fIhostA\fR:
++.IP
++\fBjackd \-d alsa \fR
++.br
++\fBjack_netsource \-H hostB -n1 -i4 -o4 -I0 -O0 \fR
++.PP
++On \fIhostB\fR:
++.IP
++\fBjackd \-d net \fR
++
+--- /dev/null
++++ b/man/jackrec.0
+@@ -0,0 +1,23 @@
++.TH JACKREC "1" "!DATE!" "!VERSION!"
++.SH NAME
++jackrec \- JACK toolkit client for recording audio
++.SH SYNOPSIS
++.B jackrec
++\-f filename \-d seconds [ \-b bitdepth ] port1 [ port2 ... ]
++.SH DESCRIPTION
++.B jackrec is a basic, but useful, audio recorder that will record
++audio from 1 or more JACK ports to a file on disk. The file format is
++always RIFF/WAV, with samples stored as signed integers. The sample
++bit depth can be selected using the \fI-b\fR option. The file will
++have as many channels as there are ports specified on the command line
++- each channel will contain the data recorded from one port. The user
++should generally specify the duration (in seconds) using the \fI-d\fR
++option. If not specified, jackrec will record until terminated by a
++signal (eg. from Ctrl-c).
++.PP
++This application is not intended to be a heavy duty audio recorder,
++and originated as an example client to show how to handle threading
++and disk I/O in a JACK client. However, it is a useful, simple
++recorder and is included in the JACK toolkit as a result.
++
++
+--- /dev/null
++++ b/man/jack_samplerate.0
+@@ -0,0 +1,9 @@
++.TH JACK_SAMPLERATE "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_samplerate \- JACK toolkit client to print current samplerate
++.SH SYNOPSIS
++.B jack_samplerate
++.SH DESCRIPTION
++.B jack_samplerate prints the current samplerate, and exits.
++
++
+--- /dev/null
++++ b/man/jack_showtime.0
+@@ -0,0 +1,13 @@
++.TH JACK_SHOWTIME "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_showtime \- The JACK Audio Connection Kit example client
++.SH SYNOPSIS
++.B jack_showtime
++.SH DESCRIPTION
++.B jack_showtime
++prints the current timebase information to stdout
++.SH AUTHOR
++Paul Davis
++.PP
++This manpage was written by Stefan Schwandter <swan at debian.org>
++
+--- /dev/null
++++ b/man/jack_simple_client.0
+@@ -0,0 +1,20 @@
++.TH JACK_CONNECT "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_simple_client \- The JACK Audio Connection Kit example client
++.SH SYNOPSYS
++.B jack_simple_client
++client-name
++.PP
++The client-name must be a yet unused client name.
++.SH DESCRIPTION
++.B jack_simple_client
++is an example client for the JACK Audio Connection Kit. It creates two
++ports (client-name:input and client-name:output) that pass the data
++unmodified.
++.SH EXAMPLE
++jack_simple_client in_process_test
++.SH AUTHOR
++Jeremy Hall
++.PP
++This manpage was written by Robert Jordens <jordens at debian.org> for Debian.
++
+--- /dev/null
++++ b/man/jack_transport.0
+@@ -0,0 +1,13 @@
++.TH JACK_TRANSPORT "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_transport \- JACK toolkit client for transport control
++.SH SYNOPSIS
++.B jack_transport
++.SH DESCRIPTION
++.B jack_transport
++is a toolkit client for the JACK Audio Connection Kit. It provides command-line
++control over the JACK transport system. Type help at jack_transport's
++command prompt to see the available commands.
++.SH AUTHOR
++Jeremy Hall
++
+--- /dev/null
++++ b/man/jack_unload.0
+@@ -0,0 +1,19 @@
++.TH JACK_UNLOAD "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_unload \- The JACK Audio Connection Kit example client
++.SH SYNOPSIS
++.B jack_unload
++client-name
++.PP
++The client-name must be the name of a loaded client that can be unloaded.
++.SH DESCRIPTION
++.B jack_unload
++is the counterpart to
++.B jack_load
++and unloads the specified client.
++.SH EXAMPLE
++.B jack_unload in_process_test
++.SH AUTHOR
++Jeremy Hall
++.PP
++This manpage was written by Robert Jordens <jordens at debian.org> for Debian.
+--- /dev/null
++++ b/man/jack_wait.0
+@@ -0,0 +1,41 @@
++.TH JACK_WAIT "1" "!DATE!" "!VERSION!"
++.SH NAME
++jack_wait \- JACK toolkit client to check and wait for existence/exit of jackd.
++.SH SYNOPSIS
++\fBjack_wait\fR [ \fI-s\fR | \fI--server\fR servername ] [ \fI-t\fR | \fI--timeout\fR timeout_seconds [ \fI-cqwhv\fR ]
++.SH DESCRIPTION
++\fBjack_wait\fR When invoked with \fI-c\fR it only checks for the existence of a jack server. When invoked with \fI-w\fR the
++program will wait for a jackd to be available.
++The \fI-q\fR makes it wait for the jackd to exit.
++
++.SH OPTIONS
++.TP
++\fB-w\fR, \fB--wait\fR
++.br
++Wait for jackd to be available.
++.TP
++\fB-q\fR, \fB--quit\fR
++.br
++Wait for jackd quit.
++.TP
++\fB-c\fR, \fB--check\fR
++.br
++Only check for existence of jackd, and exit.
++.TP
++\fB-s\fR, \fB--server\fR \fIservername\fR
++.br
++Connect to the jack server named \fIservername\fR
++.TP
++\fB-t\fR, \fB--timeout\fR \fItimeout_seconds\fR
++.br
++Only wait \fItimeout_seconds\fR.
++.TP
++\fB-h\fR, \fB--help\fR
++.br
++Display help/usage message
++.TP
++\fB-v\fR, \fB--version\fR
++.br
++Output version information and exit
++
++
+--- /dev/null
++++ b/man/wscript
+@@ -0,0 +1,13 @@
++#! /usr/bin/env python
++# encoding: utf-8
++
++import Build
++import re
++import os
++import misc
++
++
++def build(bld):
++ bld.exec_command("cd man ; sh fill_template %s" % bld.env['JACK_VERSION'])
++ bld.install_files(bld.env['MANDIR'], '*.1')
++
+--- a/posix/JackPosixSemaphore.cpp
++++ b/posix/JackPosixSemaphore.cpp
+@@ -118,10 +118,12 @@
+ time.tv_sec += tv_usec / 1000000;
+ time.tv_nsec = (tv_usec % 1000000) * 1000;
+
+- if ((res = sem_timedwait(fSemaphore, &time)) != 0) {
++ while ((res = sem_timedwait(fSemaphore, &time)) < 0) {
+ jack_error("JackPosixSemaphore::TimedWait err = %s", strerror(errno));
+ jack_log("now %ld %ld ", now.tv_sec, now.tv_usec);
+ jack_log("next %ld %ld ", time.tv_sec, time.tv_nsec/1000);
++ if (errno != EINTR)
++ break;
+ }
+ return (res == 0);
+ }
+@@ -184,9 +186,8 @@
+
+ bool JackPosixSemaphore::Disconnect()
+ {
+- jack_log("JackPosixSemaphore::Disconnect %s", fName);
+-
+ if (fSemaphore) {
++ jack_log("JackPosixSemaphore::Disconnect %s", fName);
+ if (sem_close(fSemaphore) != 0) {
+ jack_error("Disconnect: can't disconnect named semaphore name = %s err = %s", fName, strerror(errno));
+ return false;
--
jackd2 packaging
More information about the pkg-multimedia-commits
mailing list