diff options
author | Alexandre Ratchov <ratchov@cvs.openbsd.org> | 2012-11-23 07:03:29 +0000 |
---|---|---|
committer | Alexandre Ratchov <ratchov@cvs.openbsd.org> | 2012-11-23 07:03:29 +0000 |
commit | e0ec54cfb7c1e7d74bad5acd7800df96c1c4d3d4 (patch) | |
tree | dfd9738fc0938d8c3ed1cb3d3ba25202ca3a4472 /lib/libsndio | |
parent | 42dd4f4c8b798c2f8b9e8544080704a71226370e (diff) |
Remplace aucat server by a new sndiod daemon aimed to be simpler
smaller and faster than aucat. It's a drop in replacement with the
following exceptions that don't affect the default setup:
- The sample rate and the encoding are a per-device parameters
thus -r and -e options must precede the corresponding -f option
- MIDI thru boxes are dynamically created and no -M option
is required anymore, so -M was removed.
- MIDI ports are exposed with a new ``midi/N'' name, rather
than abusing MIDI thru boxes.
with help from armani@, ok deraadt@
Diffstat (limited to 'lib/libsndio')
-rw-r--r-- | lib/libsndio/aucat.c | 5 | ||||
-rw-r--r-- | lib/libsndio/mio.c | 4 | ||||
-rw-r--r-- | lib/libsndio/sndio.7 | 7 |
3 files changed, 10 insertions, 6 deletions
diff --git a/lib/libsndio/aucat.c b/lib/libsndio/aucat.c index e1e5211a3ea..c146616df28 100644 --- a/lib/libsndio/aucat.c +++ b/lib/libsndio/aucat.c @@ -1,4 +1,4 @@ -/* $OpenBSD: aucat.c,v 1.55 2012/11/02 10:24:58 ratchov Exp $ */ +/* $OpenBSD: aucat.c,v 1.56 2012/11/23 07:03:28 ratchov Exp $ */ /* * Copyright (c) 2008 Alexandre Ratchov <alex@caoua.org> * @@ -444,8 +444,7 @@ aucat_open(struct aucat *hdl, const char *str, unsigned int mode, DPRINTF("%s: junk at end of dev name\n", p); return 0; } - if (type) - devnum += 16; /* XXX */ + devnum += type * 16; /* XXX */ DPRINTF("aucat_open: host=%s unit=%u devnum=%u opt=%s\n", host, unit, devnum, opt); if (host[0] != '\0') { diff --git a/lib/libsndio/mio.c b/lib/libsndio/mio.c index 0f130dbe392..f965a148fb5 100644 --- a/lib/libsndio/mio.c +++ b/lib/libsndio/mio.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mio.c,v 1.16 2012/10/27 12:08:25 ratchov Exp $ */ +/* $OpenBSD: mio.c,v 1.17 2012/11/23 07:03:28 ratchov Exp $ */ /* * Copyright (c) 2008 Alexandre Ratchov <alex@caoua.org> * @@ -61,6 +61,8 @@ mio_open(const char *str, unsigned int mode, int nbio) return mio_aucat_open(p, mode, nbio, 0); if ((p = sndio_parsetype(str, "midithru")) != NULL) return mio_aucat_open(p, mode, nbio, 1); + if ((p = sndio_parsetype(str, "midi")) != NULL) + return mio_aucat_open(p, mode, nbio, 2); if ((p = sndio_parsetype(str, "rmidi")) != NULL) { return mio_rmidi_open(p, mode, nbio); } diff --git a/lib/libsndio/sndio.7 b/lib/libsndio/sndio.7 index 78461bc75ef..e1340a54a2e 100644 --- a/lib/libsndio/sndio.7 +++ b/lib/libsndio/sndio.7 @@ -1,4 +1,4 @@ -.\" $OpenBSD: sndio.7,v 1.10 2012/05/23 19:25:11 ratchov Exp $ +.\" $OpenBSD: sndio.7,v 1.11 2012/11/23 07:03:28 ratchov Exp $ .\" .\" Copyright (c) 2007 Alexandre Ratchov <alex@caoua.org> .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: May 23 2012 $ +.Dd $Mdocdate: November 23 2012 $ .Dt SNDIO 7 .Os .Sh NAME @@ -93,6 +93,9 @@ Audio device exposed by .It Pa midithru MIDI thru box created with .Xr sndiod 1 . +.It Pa midi +MIDI port exposed by +.Xr sndiod 1 . .It Pa default Any audio device or MIDI port. .El |