Annotation of src/usr.bin/aucat/conf.h, Revision 1.16
1.16 ! ratchov 1: /* $OpenBSD: conf.h,v 1.15 2010/04/06 20:07:01 ratchov Exp $ */
1.1 ratchov 2: /*
3: * Copyright (c) 2008 Alexandre Ratchov <alex@caoua.org>
4: *
5: * Permission to use, copy, modify, and distribute this software for any
6: * purpose with or without fee is hereby granted, provided that the above
7: * copyright notice and this permission notice appear in all copies.
8: *
9: * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10: * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11: * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12: * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13: * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14: * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15: * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16: */
1.3 ratchov 17: #ifndef CONF_H
18: #define CONF_H
1.1 ratchov 19:
1.12 ratchov 20: #ifdef DEBUG
21: /*
22: * Debug trace levels:
23: *
24: * 0 - fatal errors: bugs, asserts, internal errors.
25: * 1 - warnings: bugs in clients, failed allocations, non-fatal errors.
26: * 2 - misc information (hardware parameters, incoming clients)
27: * 3 - structural changes (new aproc structures and files stream params changes)
28: * 4 - data blocks and messages
29: */
30: extern int debug_level;
31: #endif
1.14 ratchov 32:
33: /*
1.9 ratchov 34: * socket and option names
35: */
1.7 ratchov 36: #define DEFAULT_MIDITHRU "midithru"
37: #define DEFAULT_SOFTAUDIO "softaudio"
38: #define DEFAULT_OPT "default"
1.9 ratchov 39:
40: /*
41: * MIDI buffer size
42: */
1.10 ratchov 43: #define MIDI_BUFSZ 3125 /* 1 second at 31.25kbit/s */
1.11 ratchov 44:
45: /*
46: * units used for MTC clock.
47: */
48: #define MTC_SEC 2400 /* 1 second is 2400 ticks */
1.16 ! ratchov 49:
! 50: /*
! 51: * device or sub-device mode, must be a superset of corresponding SIO_XXX
! 52: * and MIO_XXX constants
! 53: */
! 54: #define MODE_PLAY 0x01 /* allowed to play */
! 55: #define MODE_REC 0x02 /* allowed to rec */
! 56: #define MODE_MIDIOUT 0x04 /* allowed to read midi */
! 57: #define MODE_MIDIIN 0x08 /* allowed to write midi */
! 58: #define MODE_MON 0x10 /* allowed to monitor */
! 59: #define MODE_LOOP 0x20 /* deviceless mode */
! 60: #define MODE_RECMASK (MODE_REC | MODE_MON)
! 61: #define MODE_AUDIOMASK (MODE_REC | MODE_MON | MODE_PLAY)
! 62: #define MODE_MIDIMASK (MODE_MIDIIN | MODE_MIDIOUT)
! 63:
! 64: /*
! 65: * underrun/overrun policies, must be the same as SIO_XXX
! 66: */
! 67: #define XRUN_IGNORE 0 /* on xrun silently insert/discard samples */
! 68: #define XRUN_SYNC 1 /* catchup to sync to the mix/sub */
! 69: #define XRUN_ERROR 2 /* xruns are errors, eof/hup buffer */
1.1 ratchov 70:
71: #endif /* !defined(CONF_H) */