2 Steinberg Audio Stream I/O API
3 (c) 1996, Steinberg Soft- und Hardware GmbH
7 c++ superclass to implement asio functionality. from this,
8 you can derive whatever required
14 // cpu and os system we are running on
16 // basic "C" interface
20 extern AsioDriver
*getDriver(); // for generic constructor
26 class AsioDriver
: public IASIO
,public CUnknown
29 AsioDriver(LPUNKNOWN pUnk
, HRESULT
*phr
);
33 static CUnknown
*CreateInstance(LPUNKNOWN pUnk
, HRESULT
*phr
);
35 virtual HRESULT STDMETHODCALLTYPE
NonDelegatingQueryInterface(REFIID riid
,void **ppvObject
);
44 virtual ~AsioDriver();
46 virtual ASIOBool
init(void* sysRef
);
47 virtual void getDriverName(char *name
); // max 32 bytes incl. terminating zero
48 virtual long getDriverVersion();
49 virtual void getErrorMessage(char *string
); // max 124 bytes incl.
51 virtual ASIOError
start();
52 virtual ASIOError
stop();
54 virtual ASIOError
getChannels(long *numInputChannels
, long *numOutputChannels
);
55 virtual ASIOError
getLatencies(long *inputLatency
, long *outputLatency
);
56 virtual ASIOError
getBufferSize(long *minSize
, long *maxSize
,
57 long *preferredSize
, long *granularity
);
59 virtual ASIOError
canSampleRate(ASIOSampleRate sampleRate
);
60 virtual ASIOError
getSampleRate(ASIOSampleRate
*sampleRate
);
61 virtual ASIOError
setSampleRate(ASIOSampleRate sampleRate
);
62 virtual ASIOError
getClockSources(ASIOClockSource
*clocks
, long *numSources
);
63 virtual ASIOError
setClockSource(long reference
);
65 virtual ASIOError
getSamplePosition(ASIOSamples
*sPos
, ASIOTimeStamp
*tStamp
);
66 virtual ASIOError
getChannelInfo(ASIOChannelInfo
*info
);
68 virtual ASIOError
createBuffers(ASIOBufferInfo
*bufferInfos
, long numChannels
,
69 long bufferSize
, ASIOCallbacks
*callbacks
);
70 virtual ASIOError
disposeBuffers();
72 virtual ASIOError
controlPanel();
73 virtual ASIOError
future(long selector
, void *opt
);
74 virtual ASIOError
outputReady();