Home Units Hierarchy Routines All identifiers

Class unavclWaveCodecDevice

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type unavclWaveCodecDevice = class(unavclInOutWavePipe)

Description

Audio stream conversion from one supported format to another. It can convert PCM stream to other format (compression) or other format to PCM (decompression).

Usage: If components has no provider component with formatProvider=true, specify PCM stream parameters before activating: pcm_SamplesPerSec, pcm_BitsPerSample and pcm_NumChannels.

Set formatTag property to specify the audio format you wish to compress to or decompress from. Refer to WAVE_FORMAT_XXXX constants from unaMsAcmAPI.pas unit for possible values of this property, or you can use the output of amcEnum demo to receive the list of installed formats.

Set inputIsPCM to true, if you wish to convert PCM stream to another audio format (compression). Set inputIsPCM to false, if you wish to convert some audio format to PCM stream (decompression).

Example: refer to the vcTalkNow demo. It has c_codec_serverOut component, which is a consumer of waveIn_server component.

That means PCM stream, produced by waveIn_server will be passed to c_codec_serverOut automatically. It also has ip_server as a consumer. That means compressed audio stream will be passed to ip_server automatically.

Hierarchy

Overview

Methods

Public function setNonPCMFormat(format: PWAVEFORMATEXTENSIBLE): bool;
Protected function applyDeviceFormat(format: PWAVEFORMATEXTENSIBLE; isSrc: bool = true): bool; override;
Protected function getFormatExchangeData(out data: pointer): uint; override;
Public procedure AfterConstruction(); override;
Protected procedure createNewDevice(); override;
Protected procedure doSetDriverLibrary(const value: wString); override;
Protected procedure doSetDriverMode(value: unaAcmCodecDriverMode); override;
Protected procedure initWaveParams(); override;
Protected procedure onDriverChanged(); override;

Properties

Published property calcVolume;
Public property codec: unaMsAcmCodec read getCodec;
Published property driverLibrary;
Published property driverMode;
Published property enableDataProcessing;
Published property formatTag;
Published property formatTagImmunable default true;
Published property inputIsPcm;
Published property isFormatProvider default true;
Published property minActiveTime;
Published property minVolumeLevel;
Published property onThreshold;
Published property silenceDetectionMode;

Description

Methods

Public function setNonPCMFormat(format: PWAVEFORMATEXTENSIBLE): bool;

Sets non-PCM format for ACM codec device.

Protected function applyDeviceFormat(format: PWAVEFORMATEXTENSIBLE; isSrc: bool = true): bool; override;

Applies PCM format for ACM codec device.

Protected function getFormatExchangeData(out data: pointer): uint; override;

Returns format exchange data of the codec.

Public procedure AfterConstruction(); override;
 
Protected procedure createNewDevice(); override;

Creates ACM codec device.

Protected procedure doSetDriverLibrary(const value: wString); override;
 
Protected procedure doSetDriverMode(value: unaAcmCodecDriverMode); override;
 
Protected procedure initWaveParams(); override;
 
Protected procedure onDriverChanged(); override;

Notifies ACM codec device about driver change.

Properties

Published property calcVolume;
 
Public property codec: unaMsAcmCodec read getCodec;

Returns ACM codec device.

Published property driverLibrary;

When driverMode is set to unacdm_installable this property specifies the name of driver library to use. Refer to MSDN documentation for more information about installable drivers.

Published property driverMode;

ACM driver mode. When set to unacdm_acm, codec uses ACM to access stream conversion routines. unacdm_installable tells codec to use installable driver, specified by driverLibrary. unacdm_internal is not currently used.

Published property enableDataProcessing;

Specifies whether the component would perform any data conversion.

Published property formatTag;
 
Published property formatTagImmunable default true;

Codecs usually does not use the format tag provided by other PCM devices.

Published property inputIsPcm;
 
Published property isFormatProvider default true;

codec component is usually a format provider–so default value for was changed to true.

Published property minActiveTime;
 
Published property minVolumeLevel;
 
Published property onThreshold;
 
Published property silenceDetectionMode;
 

(c) 2012 Lake of Soft


Generated by PasDoc 0.12.1 on 2012-10-09