Home Units Hierarchy Routines All identifiers

Class unaAsioDriver

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type unaAsioDriver = class(unaObject)

Description

– unaAsioDriver –

Hierarchy

Overview

Methods

Public constructor create(asio: iASIO);
Public destructor Destroy(); override;
Public function canSampleRate(sampleRate: ASIOSampleRate): bool;
Public function controlPanel(): ASIOError;
Public function future(selector: long; opt: pointer = nil): ASIOError;
Public function getBufferSizeInBytes(chIndex: int): int;
Public function getClockSources(clocks: pASIOClockSources; var numSources: long): ASIOError;
Public function getDriverError(hardCall: bool = true): aString;
Public function getSamplePosition(out sPos: ASIOSamples; out tStamp: ASIOTimeStamp): ASIOError;
Public function getSamples(channelIndex, bufIndex: int; outBuffer: pInt16Array; startSampleIndex: int = 0; samplesCount: int = -1): ASIOError;
Public function init(sysref: long = 0; createBuffers: bool = true; bufSize: int = -1): ASIOError;
Public function outputReady(): ASIOError;
Public function release(): bool;
Public function setClockSource(reference: long): ASIOError;
Public function setSample(channelIndex, bufIndex, sampleIndex, value: int32; op: unaASIOSampleOp = soAdd): ASIOError; overload;
Public function setSample(channelIndex, bufIndex, sampleIndex: int; value: double; op: unaASIOSampleOp = soAdd): ASIOError; overload;
Public function setSampleRate(const sampleRate: ASIOSampleRate): ASIOError;
Public function setSamples(channelIndex, bufIndex, startSampleIndex, samplesCount: int; values: pDouble; op: unaASIOSampleOp = soAdd): ASIOError; overload;
Public function setSamples(channelIndex, bufIndex: int; inBuffer: pInt16Array; startSampleIndex: int = 0; samplesCount: int = -1): ASIOError; overload;
Public function setSamples(channelIndex, bufIndex, startSampleIndex, samplesCount: int; value: pInt32; op: unaASIOSampleOp = soAdd): ASIOError; overload;
Public function start(createBuffers: bool = false; bufSize: int = -1): ASIOError;
Public function stop(releaseBuffers: bool = false): ASIOError;
Protected function createBuffers(bufferInfos: pASIOBufferInfo; numChannels: long; bufferSize: long; callbacks: pASIOCallbacks): ASIOError;
Protected function disposeBuffers(): ASIOError;
Protected function doAsioMessage(selector: long; value: long; message: pointer; opt: pDouble): long; virtual;
Protected function doBufferSwitchTimeInfo(timeInfo: pASIOTime; index: long; processNow: bool): pASIOTime; virtual;
Protected function getBufferSize(out minSize, maxSize, preferredSize, granularity: long): ASIOError;
Protected function getChannels(out numInputChannels: long; out numOutputChannels: long): ASIOError;
Protected function getDriverName(hardCall: bool = false): aString;
Protected function getDriverVersion(hardCall: bool = false): long;
Protected function getLatencies(out inputLatency: long; out outputLatency: long): ASIOError;
Protected procedure doBufferSwitch(index: long; processNow: bool); virtual;
Protected procedure doSampleRateChanged(rate: ASIOSampleRate); virtual;

Properties

Public property bufActualSize: long read f_actualBufSize;
Public property bufferInfo[index:int]: pASIOBufferInfo read getBufferInfoByIndex;
Public property bufferProcessor: unaAsioBufferProcessor read f_bp write setBufferProcessor;
Public property bufGranularity: long read f_granularity;
Public property bufMaxSize: long read f_maxBufSize;
Public property bufMinSize: long read f_minBufSize;
Public property bufPreferredSize: long read f_preferredBufSize;
Public property channelInfo[index:int]: pASIOChannelInfo read getChannelInfoByIndex;
Public property driverInfo: pASIODriverInfo read getDriverInfo;
Public property driverState: unaASIODriverState read f_driverState;
Public property inputChannels: long read f_inputChannels;
Public property inputLatency: long read f_inputLatency;
Public property onAsioMessage: asioMessageEvent read f_onAM;
Public property onBufferSwitch: bufferSwitchEvent read f_onBS;
Public property onBufferSwitchTimeInfo: bufferSwitchTimeInfoEvent read f_onBSTI;
Public property onSampleRateChanged: sampleRateChangedEvent read f_onSRC;
Public property outputChannels: long read f_outputChannels;
Public property outputLatency: long read f_outputLatency;
Public property postOutput: bool read f_postOutput;
Public property sampleRate: ASIOSampleRate read getSampleRate;

Description

Methods

Public constructor create(asio: iASIO);
 
Public destructor Destroy(); override;
 
Public function canSampleRate(sampleRate: ASIOSampleRate): bool;
 
Public function controlPanel(): ASIOError;
 
Public function future(selector: long; opt: pointer = nil): ASIOError;
 
Public function getBufferSizeInBytes(chIndex: int): int;

Returns number of bytes in buffer allocated for channel

Parameters
chIndex
index of channel
Public function getClockSources(clocks: pASIOClockSources; var numSources: long): ASIOError;
 
Public function getDriverError(hardCall: bool = true): aString;
 
Public function getSamplePosition(out sPos: ASIOSamples; out tStamp: ASIOTimeStamp): ASIOError;
 
Public function getSamples(channelIndex, bufIndex: int; outBuffer: pInt16Array; startSampleIndex: int = 0; samplesCount: int = -1): ASIOError;

Returns input samples as 16-bit values. NOTE: outBuffer must be large enough to hold all samples

Parameters
channelIndex
index of input channel (from 0 to inputChannels - 1), or -1 to return all channels
bufIndex
index of buffer to read data from (usually passed via callback)
outBuffer
array of int16 values to be filled with samples
startSampleIndex
first sample to copy
samplesCount
number of samples to copy, or -1 to copy the whole buffer
Returns

ASE_OK or error code

Public function init(sysref: long = 0; createBuffers: bool = true; bufSize: int = -1): ASIOError;
 
Public function outputReady(): ASIOError;
 
Public function release(): bool;
 
Public function setClockSource(reference: long): ASIOError;
 
Public function setSample(channelIndex, bufIndex, sampleIndex, value: int32; op: unaASIOSampleOp = soAdd): ASIOError; overload;
 
Public function setSample(channelIndex, bufIndex, sampleIndex: int; value: double; op: unaASIOSampleOp = soAdd): ASIOError; overload;
 
Public function setSampleRate(const sampleRate: ASIOSampleRate): ASIOError;
 
Public function setSamples(channelIndex, bufIndex, startSampleIndex, samplesCount: int; values: pDouble; op: unaASIOSampleOp = soAdd): ASIOError; overload;
 
Public function setSamples(channelIndex, bufIndex: int; inBuffer: pInt16Array; startSampleIndex: int = 0; samplesCount: int = -1): ASIOError; overload;

Sets output samples as 16-bit values. NOTE: inBuffer must be large enough to hold all samples

Parameters
channelIndex
index of input channel (from 0 to outputChannels - 1), or -1 to set all channels
bufIndex
index of buffer to set data at (usually passed via callback)
inBuffer
array of int16 values to assigted to samples
startSampleIndex
first sample to set
samplesCount
number of samples to set, or -1 to set the whole buffer
Returns

ASE_OK or error code

Public function setSamples(channelIndex, bufIndex, startSampleIndex, samplesCount: int; value: pInt32; op: unaASIOSampleOp = soAdd): ASIOError; overload;
 
Public function start(createBuffers: bool = false; bufSize: int = -1): ASIOError;
 
Public function stop(releaseBuffers: bool = false): ASIOError;
 
Protected function createBuffers(bufferInfos: pASIOBufferInfo; numChannels: long; bufferSize: long; callbacks: pASIOCallbacks): ASIOError;
 
Protected function disposeBuffers(): ASIOError;
 
Protected function doAsioMessage(selector: long; value: long; message: pointer; opt: pDouble): long; virtual;
 
Protected function doBufferSwitchTimeInfo(timeInfo: pASIOTime; index: long; processNow: bool): pASIOTime; virtual;
 
Protected function getBufferSize(out minSize, maxSize, preferredSize, granularity: long): ASIOError;

ASIO interface

Protected function getChannels(out numInputChannels: long; out numOutputChannels: long): ASIOError;
 
Protected function getDriverName(hardCall: bool = false): aString;
 
Protected function getDriverVersion(hardCall: bool = false): long;
 
Protected function getLatencies(out inputLatency: long; out outputLatency: long): ASIOError;
 
Protected procedure doBufferSwitch(index: long; processNow: bool); virtual;
 
Protected procedure doSampleRateChanged(rate: ASIOSampleRate); virtual;
 

Properties

Public property bufActualSize: long read f_actualBufSize;

Actually allocated buffers size (samples)

Public property bufferInfo[index:int]: pASIOBufferInfo read getBufferInfoByIndex;

Buffer information

bufferInfo and channelInfo share the same indexing, as the data in them are linked together max index is inputChannels + outputChannels - 1, input channels go first

Public property bufferProcessor: unaAsioBufferProcessor read f_bp write setBufferProcessor;

Buffer switch event

Public property bufGranularity: long read f_granularity;

Granularity (samples)

Public property bufMaxSize: long read f_maxBufSize;

Maximum buffer size (samples)

Public property bufMinSize: long read f_minBufSize;

Minimum buffer size (samples)

Public property bufPreferredSize: long read f_preferredBufSize;

Preferred buffer size (samples)

Public property channelInfo[index:int]: pASIOChannelInfo read getChannelInfoByIndex;

Channel information

bufferInfo and channelInfo share the same indexing, as the data in them are linked together max index is inputChannels + outputChannels - 1, input buffers go first

Public property driverInfo: pASIODriverInfo read getDriverInfo;
 
Public property driverState: unaASIODriverState read f_driverState;
 
Public property inputChannels: long read f_inputChannels;

Number of input channels

Public property inputLatency: long read f_inputLatency;

Input latency (samples)

Public property onAsioMessage: asioMessageEvent read f_onAM;

ASIO Message event

Public property onBufferSwitch: bufferSwitchEvent read f_onBS;

Buffer switch event

Public property onBufferSwitchTimeInfo: bufferSwitchTimeInfoEvent read f_onBSTI;

Buffer switch event

Public property onSampleRateChanged: sampleRateChangedEvent read f_onSRC;

SR change event

Public property outputChannels: long read f_outputChannels;

Number of output channels

Public property outputLatency: long read f_outputLatency;

Output latency (samples)

Public property postOutput: bool read f_postOutput;
 
Public property sampleRate: ASIOSampleRate read getSampleRate;

Current sampling rate (samples/second)

(c) 2012 Lake of Soft


Generated by PasDoc 0.12.1 on 2012-10-09