Age | Commit message (Collapse) | Author |
|
|
|
|
|
it to the *_open() functions. It's more flexible this way. No behaviour
change.
|
|
checking for truncation every time we touch the string, simply allocate
a memory chunk large enough to store the full path.
|
|
of hardcoded strings. no object change.
|
|
|
|
|
|
|
|
As ratchov@ notes:
"all _aucat_wmsg() callers set hdl->wtodo, so your diff can't break
things that used to work by accident."
ok ratchov@
|
|
for talking to aucat/sndiod
ok ratchov@
|
|
|
|
|
|
ok deraadt, guenther
|
|
ok ratchov
|
|
|
|
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@
|
|
messages and enable flow control for MIDI. Since this requires protocol
version bump, both sndiod and libsndio must be kept up to date to work
together.
|
|
suggested by deraadt@
|
|
single aucat instance to handle all audio and MIDI services. Since
this partially breaks compatibility, this is a opportunitiy to fix few
other design mistakes (eg ':' being used by inet6, type name vs api
name confusion, etc..). This leads to the following names:
type[@hostname][,unit]/devnum[.option]
The device number is the minor device number for direct hardware
access (ie the 'N' in /dev/audioN). For aucat, this is the occurence
number of the -f (or -M) option.
There's a compatibility hook to keep old names working if only one
aucat server is running.
|
|
and fixed by Remco <remco at d-compu.dyndns.org>, thanks!
|
|
with almost the same syntax (roughly an extra -M option).
Thru boxes are created with aucat, and corresponding MIDI port
names have the "aucat" prefix instead of "midithru". The old
device name will still work some time for backward compatibility.
ok deraadt
|
|
|
|
code. This is simpler as long as not all backends use the same
default.
|
|
when the server and the client are not of the same endianness.
Found by naddy.
|
|
|
|
work over TCP, for instance, to expose the sound card of one machine
with other machines of the network.
The first client generates a 128-bit random number (aka the
session cookie), saves it in $HOME/.aucat_cookie and sends it to the
server. Successive clients load the cookie from $HOME/.aucat_cookie
and send it to the server but the server accepts only clients whose
cookie matches the session cookie. When all clients are gone, the
session is over, and another cookie could start a new session, and so
on.
TCP is enabled on the server with the new -L option, and on the client
side hostnames are specified with a new optional component in the
device name.
hints from damien, dlg and deraadt, tweaks from jmc
|
|
protocol specific code. No behaviour change
|
|
with the server. As we're at it use the same protocol for midi and
audio. Now, both audio and midi code use the same SNDIO_DEBUG environment
variable to turn on/off DPRINTF's.
|
|
audio-related functions and put them in files named sio_<backend>.c
No behaviour changes.
|
|
AMSG_xxx macros, which in turns simplifies the code
|
|
complicated. Instead, request clients to provide enough samples
and start with buffers full.
|
|
|
|
Add a new ``initial position'' message which is simpler. No bahaviour
change, except effects of the protocol version crank.
|
|
|
|
|
|
run by root, it binds a shared address to the socket, cranks the
process priority and drops privileges. sio_open(3) will try to
connect to the private socket first (if any), then to the shared
socket. Only one user may have connections to aucat at a given
time.
based on discussions with henning, pyr and others
ok jacek, deraadt
|
|
- make the ``-m mode'' option per subdevice, allowing
subdevices to be play-only or rec-only even if the
server is full-duplex
- add ``monitoring'' mode (with ``-m mon''). This is a
record-only stream from which played streams can be
recorded (kind of ``record what you hear'').
- allow MIDI devices to be subscribed to the controlling
MIDI port of the server, ie what midicat does (with -f
option), but using the -q option.
- add flow control to the protocol, and serialize clock
ticks (sio_onmove() calls) and data chunks. This should
fix certain full-duplex programs, broken with ``magic''
block/buffer size combinations.
- enable 3 block latency which is the minimum theoretical.
Make -z and -b options correspond to device parameters.
- make sio_getcap(3) the same for aucat and sun backends,
ie return whatever is supported (``everything'' in the
aucat case, since everything is actulally supported).
aucat (player):
- enable ``-m mode'' option to select between monitoring
and recording when ``-o file'' is used.
- plug MIDI code to non-server codepath. The MIDI control
device is specified with the ``-q device'' option, as in
server mode.
- impliment lseek()'ing within files (controlled
through MIDI). Necessary to use aucat with a MIDI
sequencer.
midicat (thrubox):
- rename ``-f'' flag to ``-q'', so it has the
same name as in aucat (-f is still working)
ok jakemsr@, tweaks from jmc@
|
|
ok ratchov
|
|
can return POLLOUT (if requested), even the handle was not writable when
sio_pollfd() was called but become writable somewhere in the code path
of sio_revents().
This should improve stability of programs using very small buffers.
|
|
entering a busy loop
|
|
stream in a way that the pause never occurs in the middle of data
chunks. Beside being more natural, this allows the client to send
non-data messages during the pause (set the volume, stop playback...),
rather than delaying them until the end of the pause. It's about
few milliseconds only.
|
|
instead of ``appbufsz'', which violates the flow control mechanism.
Fix this longstanding bug by enabling negative values in AMSG_MOVE
messages, this way the client is notified when its stream is
attached to the mixer, and can update its max transfer limit.
Since this fix changes the AMSG_MOVE message format, we crank the
protocol version, and thus remove code specific to the old protocol.
|
|
but later, it will permit aucat to reject connections from
clients statically linked to a unsupported version of libsndio.
idea from kittenis, otto and sthen
|
|
as a programming error. At any stage the program should be alble to
cleanly free resources and close the device.
|
|
on sio_close()
|
|
free resources and drop the connection. This allows the client
to ensuire that at any time it's using only one connection, thus
only one MIDI control channel.
|
|
of volume changes
|
|
from Thomas Pfaff
|
|
with open(2) and write(2) syscalls.
from Thomas Pfaff, jakemsr is fine with it
|
|
cannot cooperate with other programs. The aim of this change is
to allow any program to send midi data to other programs as they
were midi hardware. For instance, this change should solve the
longstanding problem of using a midi sequencer with software
synthesizers. More precisely:
- new midicat(1) utility (actually hardlink to aucat(1)).
it creates software midi thru boxes, allowing programs
to send midi messages to other programs as they were
midi(4) hardware.
- new midi api in libsndio (see mio_open(3)), to access
midi(4) devices and midicat(1) sockets in a uniform way.
- new device naming scheme <service>:<unit>[.<option>],
common to audio and midi.
- new sndio(7) manual describing concepts and naming
The current audio device naming still works, but people having
scripts or configuration files containing device names could read
the sndio(7) man page and slowly start updating device names.
discussed with jakemsr@ and deraadt@, help form jmc@
|