Home Units Hierarchy Routines All identifiers

Class unaWaveInDevice

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type unaWaveInDevice = class(unaWaveDevice)

Description

Use this class to record live audio. deviceID parameter used to construct instances of this class can be from 0 to unaWaveInDevice.getDeviceCount() - 1, or you can use WAVE_MAPPER value instead.

After opening the device check periodically output stream by calling read() method, or use onDataAvailable() event to receive new data chunks.

Hierarchy

Overview

Methods

Public constructor create(deviceID: uint = WAVE_MAPPER; mapped: bool = false; direct: bool = true; overNum: unsigned = 0);
Public function formatChoose(var format: pWAVEFORMATEX; const title: wString = ''; style: unsigned = ACMFORMATCHOOSE_STYLEF_INITTOWFXSTRUCT; enumFlag: unsigned = ACM_FORMATENUMF_HARDWARE + ACM_FORMATENUMF_INPUT; enumFormat: pWAVEFORMATEX = nil): MMRESULT;
Public class function getCaps(deviceID: uint; var caps: WAVEINCAPSW): bool; overload;
Public class function getDeviceCount(): unsigned;
Public class function getErrorText(errorCode: MMRESULT): string;
Public function getInCaps(): pWAVEINCAPSW;
Protected function addHeader(header: unaWaveHeader): MMRESULT; override;
Protected function afterOpen(): MMRESULT; override;
Protected function doClose(timeout: tTimeout = 1): MMRESULT; override;
Protected function doGetErrorText(errorCode: MMRESULT): string; override;
Protected function doGetPosition(): int64; override;
Protected function doOpen(flags: uint): MMRESULT; override;
Protected function formatChooseDef2(var format: pWAVEFORMATEX): MMRESULT; override;
Protected function getMasterIsSrc2(): bool; override;
Protected function onHeaderDone(header: unaWaveHeader; wakeUpByHeaderDone: bool): bool; override;
Protected function prepareHeader(header: pointer): MMRESULT; override;
Protected function unprepareHeader(header: pointer): MMRESULT; override;
Protected procedure startIn(); override;
Protected procedure startOut(); override;

Properties

Public property handle;

Description

Methods

Public constructor create(deviceID: uint = WAVE_MAPPER; mapped: bool = false; direct: bool = true; overNum: unsigned = 0);

Creates wave recording device.

Public function formatChoose(var format: pWAVEFORMATEX; const title: wString = ''; style: unsigned = ACMFORMATCHOOSE_STYLEF_INITTOWFXSTRUCT; enumFlag: unsigned = ACM_FORMATENUMF_HARDWARE + ACM_FORMATENUMF_INPUT; enumFormat: pWAVEFORMATEX = nil): MMRESULT;

Displays format selection dialog.

Public class function getCaps(deviceID: uint; var caps: WAVEINCAPSW): bool; overload;

MME only.

Returns

device caps.

Public class function getDeviceCount(): unsigned;

MME only.

Returns

recording device count.

Public class function getErrorText(errorCode: MMRESULT): string;

MME only.

Returns

device error text.

Public function getInCaps(): pWAVEINCAPSW;

MME only.

Returns

device caps.

Protected function addHeader(header: unaWaveHeader): MMRESULT; override;
 
Protected function afterOpen(): MMRESULT; override;
 
Protected function doClose(timeout: tTimeout = 1): MMRESULT; override;
 
Protected function doGetErrorText(errorCode: MMRESULT): string; override;
 
Protected function doGetPosition(): int64; override;
 
Protected function doOpen(flags: uint): MMRESULT; override;
 
Protected function formatChooseDef2(var format: pWAVEFORMATEX): MMRESULT; override;

Displays a format choose dialog. Reallocates (if necessary) given format.

Protected function getMasterIsSrc2(): bool; override;

Returns false.

Protected function onHeaderDone(header: unaWaveHeader; wakeUpByHeaderDone: bool): bool; override;
 
Protected function prepareHeader(header: pointer): MMRESULT; override;
 
Protected function unprepareHeader(header: pointer): MMRESULT; override;
 
Protected procedure startIn(); override;
 
Protected procedure startOut(); override;
 

Properties

Public property handle;

WinAPI MME handle

(c) 2012 Lake of Soft


Generated by PasDoc 0.12.1 on 2012-10-09