2
.\" Copyright (c) 2005, 4Front Technologies 2005\&.
3
.TH ossddk_adev_set_ratesource 9ossddk "12 Sep 2005" "SunOS 5.10" "OSS DDK Services"
5
ossddk_adev_set_ratesource \- Sets the rate source
9
#include <sys/soundcard.h>
11
#include <sys/ossddk/ossddk.h>
14
\fBvoid\fR ossddk_adev_set_ratesource(\fBint \fIdev\fP, \fBint \fIrate_source\fP);
18
Open Sound System specific (OSS 4.0 DDK)\&.
28
OSS audio device number.
36
Audio device number of the rate source.
41
In some cases the sampling rate of an audio device is locked with some other device.
42
This information may be usefull to some applications that support multiple
43
simultaneous devices. Knowing that the devices are rate locked together makes it
44
possible to bypass any synchronization mechanisms that are normally required.
46
The driver can set this parameter in the followinng cases:
48
1) The device is a virtual device that works on top of some other (real) device.
49
In that case the master device should be reported as the rate source.
51
2) If a sound card has multiple audio engines (recording or playback) then the
52
subsequent ones should report the first one as their rate source. However this should
53
only be done if all the engines use the same sample rate clock.
55
3) There may be multiple devices (cards) of the same type which are connected together
56
using some kind of sync cable. If the driver knows this it can use the first audio device
57
of the first card (or the mown master card) as the rate source for the other audio devices.
59
Sometimes several cards of different type may be syncronized together using
60
word clock or some other methods. In such cases the drivers should not try to
61
set the rate sources based on that. This situation will be handled by the upper
62
layers of OSS (in some future OSS versions).
67
\fISNDCTL_AUDIOINFO(2oss)\fR
69
\fIWriting Sound Device Drivers with OSS DDK\fR
71
\fIOpen Sound System Programmer's Guide\fR