JACK-AUDIO-CONNECTION-KIT 0.124.1

- Main Page
- Related Pages
- Modules
- Data Structures
- Files

- File List
- Globals

types.h
Go to the documentation of this file.
1 /*
2 Copyright (C) 2001 Paul Davis
3 Copyright (C) 2004 Jack O'Quin
4
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU Lesser General Public License as published by
7 the Free Software Foundation; either version 2.1 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18
19 */
20
21 #ifndef __jack_types_h__
22 #define __jack_types_h__
23
24 #include <inttypes.h>
25 #include <pthread.h>
26 #include <uuid/uuid.h>
27
28 typedef uint64_t jack_uuid_t;
29
30 typedef int32_t jack_shmsize_t;
31
35 typedef uint32_t jack_nframes_t;
36
40 #define JACK_MAX_FRAMES (4294967295U) /* This should be UINT32_MAX, but
41 C++ has a problem with that. */
42
47 typedef uint64_t jack_time_t;
48
53 #define JACK_LOAD_INIT_LIMIT 1024
54
60 typedef jack_uuid_t jack_intclient_t;
61
66 typedef struct _jack_port jack_port_t;
67
72 typedef struct _jack_client jack_client_t;
73
78 typedef uint32_t jack_port_id_t;
79
85 typedef pthread_t jack_native_thread_t;
86
90 enum JackOptions {
91
95 JackNullOption = 0x00,
96
103 JackNoStartServer = 0x01,
104
109 JackUseExactName = 0x02,
110
114 JackServerName = 0x04,
115
120 JackLoadName = 0x08,
121
126 JackLoadInit = 0x10,
127
131 JackSessionID = 0x20
132 };
133
135 #define JackOpenOptions (JackSessionID|JackServerName|JackNoStartServer|JackUseExactName)
136
138 #define JackLoadOptions (JackLoadInit|JackLoadName|JackUseExactName)
139
144 typedef enum JackOptions jack_options_t;
145
149 enum JackStatus {
150
154 JackFailure = 0x01,
155
159 JackInvalidOption = 0x02,
160
170 JackNameNotUnique = 0x04,
171
178 JackServerStarted = 0x08,
179
183 JackServerFailed = 0x10,
184
188 JackServerError = 0x20,
189
193 JackNoSuchClient = 0x40,
194
198 JackLoadFailure = 0x80,
199
203 JackInitFailure = 0x100,
204
208 JackShmFailure = 0x200,
209
213 JackVersionError = 0x400,
214
215 /*
216 * BackendError
217 */
218 JackBackendError = 0x800,
219
220 /*
221 * Client is being shutdown against its will
222 */
223 JackClientZombie = 0x1000
224 };
225
230 typedef enum JackStatus jack_status_t;
231
235 enum JackLatencyCallbackMode {
236
242 JackCaptureLatency,
243
249 JackPlaybackLatency
250
251 };
252
256 typedef enum JackLatencyCallbackMode jack_latency_callback_mode_t;
257
267 typedef void (*JackLatencyCallback)(jack_latency_callback_mode_t mode, void *arg);
268
272 struct _jack_latency_range
273 {
277 jack_nframes_t min;
281 jack_nframes_t max;
282 };
283
284 typedef struct _jack_latency_range jack_latency_range_t;
285
298 typedef int (*JackProcessCallback)(jack_nframes_t nframes, void *arg);
299
312 typedef void (*JackThreadInitCallback)(void *arg);
313
322 typedef int (*JackGraphOrderCallback)(void *arg);
323
334 typedef int (*JackXRunCallback)(void *arg);
335
350 typedef int (*JackBufferSizeCallback)(jack_nframes_t nframes, void *arg);
351
361 typedef int (*JackSampleRateCallback)(jack_nframes_t nframes, void *arg);
362
372 typedef void (*JackPortRegistrationCallback)(jack_port_id_t port, int register, void *arg);
373
383 typedef void (*JackPortRenameCallback)(jack_port_id_t port, const char* old_name, const char* new_name, void* arg);
384
394 typedef void (*JackClientRegistrationCallback)(const char* name, int register, void *arg);
395
406 typedef void (*JackPortConnectCallback)(jack_port_id_t a, jack_port_id_t b, int connect, void* arg);
407
415 typedef void (*JackFreewheelCallback)(int starting, void *arg);
416
417 typedef void *(*JackThreadCallback)(void* arg);
418
430 typedef void (*JackShutdownCallback)(void *arg);
431
445 typedef void (*JackInfoShutdownCallback)(jack_status_t code, const char* reason, void *arg);
446
451 #define JACK_DEFAULT_AUDIO_TYPE "32 bit float mono audio"
452 #define JACK_DEFAULT_MIDI_TYPE "8 bit raw midi"
453
459 typedef float jack_default_audio_sample_t;
460
467 enum JackPortFlags {
468
473 JackPortIsInput = 0x1,
474
479 JackPortIsOutput = 0x2,
480
485 JackPortIsPhysical = 0x4,
486
500 JackPortCanMonitor = 0x8,
501
516 JackPortIsTerminal = 0x10
517 };
518
519
520 #endif /* __jack_types_h__ */
jack_client_t
struct _jack_client jack_client_t
Definition: types.h:72
JackNameNotUnique
Definition: types.h:170
JackClientZombie
Definition: types.h:223
JackPortIsInput
Definition: types.h:473
JackStatus
JackStatus
Definition: types.h:149
jack_shmsize_t
int32_t jack_shmsize_t
Definition: types.h:30
JackNoStartServer
Definition: types.h:103
jack_options_t
enum JackOptions jack_options_t
Definition: types.h:144
JackNullOption
Definition: types.h:95
JackPortFlags
JackPortFlags
Definition: types.h:467
JackInvalidOption
Definition: types.h:159
JackShmFailure
Definition: types.h:208
JackInfoShutdownCallback
void(* JackInfoShutdownCallback)(jack_status_t code, const char *reason, void *arg)
Definition: types.h:445
JackLoadInit
Definition: types.h:126
JackServerName
Definition: types.h:114
_jack_latency_range::min
jack_nframes_t min
Definition: types.h:277
JackOptions
JackOptions
Definition: types.h:90
JackLoadFailure
Definition: types.h:198
JackClientRegistrationCallback
void(* JackClientRegistrationCallback)(const char *name, int register, void *arg)
Definition: types.h:394
JackUseExactName
Definition: types.h:109
jack_status_t
enum JackStatus jack_status_t
Definition: types.h:230
_jack_latency_range
Definition: types.h:272
JackSessionID
Definition: types.h:131
JackShutdownCallback
void(* JackShutdownCallback)(void *arg)
Definition: types.h:430
_jack_latency_range::max
jack_nframes_t max
Definition: types.h:281
JackPortRenameCallback
void(* JackPortRenameCallback)(jack_port_id_t port, const char *old_name, const char *new_name, void *arg)
Definition: types.h:383
JackServerFailed
Definition: types.h:183
JackGraphOrderCallback
int(* JackGraphOrderCallback)(void *arg)
Definition: types.h:322
JackPortIsPhysical
Definition: types.h:485
JackPortCanMonitor
Definition: types.h:500
jack_time_t
uint64_t jack_time_t
Definition: types.h:47
JackFreewheelCallback
void(* JackFreewheelCallback)(int starting, void *arg)
Definition: types.h:415
JackPortIsTerminal
Definition: types.h:516
JackXRunCallback
int(* JackXRunCallback)(void *arg)
Definition: types.h:334
jack_default_audio_sample_t
float jack_default_audio_sample_t
Definition: types.h:459
jack_intclient_t
jack_uuid_t jack_intclient_t
Definition: types.h:60
JackServerError
Definition: types.h:188
JackLatencyCallback
void(* JackLatencyCallback)(jack_latency_callback_mode_t mode, void *arg)
Definition: types.h:267
JackSampleRateCallback
int(* JackSampleRateCallback)(jack_nframes_t nframes, void *arg)
Definition: types.h:361
jack_nframes_t
uint32_t jack_nframes_t
Definition: types.h:35
JackLoadName
Definition: types.h:120
jack_port_id_t
uint32_t jack_port_id_t
Definition: types.h:78
JackBufferSizeCallback
int(* JackBufferSizeCallback)(jack_nframes_t nframes, void *arg)
Definition: types.h:350
JackPortConnectCallback
void(* JackPortConnectCallback)(jack_port_id_t a, jack_port_id_t b, int connect, void *arg)
Definition: types.h:406
jack_native_thread_t
pthread_t jack_native_thread_t
Definition: types.h:85
JackFailure
Definition: types.h:154
JackVersionError
Definition: types.h:213
JackThreadInitCallback
void(* JackThreadInitCallback)(void *arg)
Definition: types.h:312
JackServerStarted
Definition: types.h:178
JackInitFailure
Definition: types.h:203
jack_latency_callback_mode_t
enum JackLatencyCallbackMode jack_latency_callback_mode_t
Definition: types.h:256
JackLatencyCallbackMode
JackLatencyCallbackMode
Definition: types.h:235
jack_uuid_t
uint64_t jack_uuid_t
Definition: types.h:28
JackPlaybackLatency
Definition: types.h:249
JackProcessCallback
int(* JackProcessCallback)(jack_nframes_t nframes, void *arg)
Definition: types.h:298
JackBackendError
Definition: types.h:218
JackNoSuchClient
Definition: types.h:193
JackPortRegistrationCallback
void(* JackPortRegistrationCallback)(jack_port_id_t port, int register, void *arg)
Definition: types.h:372
jack_port_t
struct _jack_port jack_port_t
Definition: types.h:66
JackPortIsOutput
Definition: types.h:479
JackCaptureLatency
Definition: types.h:242