CAudio_ID
Return to Top  Previous Page  Next Page
AVITags DLL has CAudio_ID enumeration declared in IExtendedAVITags interface for access technical characteristics of audio streams (up to 3) in the information container. These constants are suited to be Info_ID parameter in GetInfo and SetInfo methods. Note, you must use IDI_Audio_Stream, IDI_Audio_Stream2 or IDI_Audio_Stream for Type_ID parameter to refer the information of each audio stream properly.

To determine if there exists particular audio stream in AVI file check
IDA_Codec_TwoCC value of the corresponding stream:

   if GetInfo(aviinfo, IDI_Audio_Stream, IDA_Codec_TwoCC) <> ''
 then begin // The audio stream #1 exists

All the constants in the enumeration lie in the range
[0 .. IDA_max], so if you want to count all the IDA_... values, use following construction:

   for cur_ida := 0 to IDA_max do begin
      ... cur_ida ...
   end;

Constant
Unit
Example
Description
IDA_Codec_TwoCC
---
8132
decimal representation of two character code of the audio codec used, for example:
85 - MPEG 1 Layer 3  
8132 - NCT Soft ALF2CD ACM  
IDA_Data_Rate
bits per second
255984
characterize bandwidth: average amount of information per second used when audio being decompressed
IDA_Sampling_Rate
Hz
44100
characterize maximum audio frequency: number of samples per second
IDA_Bit_Depth
bits per sample
0
informative for PCM and similar audio formats: a number of bits in one audio sample (usually 8, 16 or 24 bits)
IDA_Channels
---
2
a number of audio channels encoded in the audio stream, for example:
1 - mono  
2 - stereo  
5 - surround sound and so on  
IDA_Duration
millisecondes
9567
duration of the audio stream
IDA_Language
---
0
language of the audio stream in terms of locale code, for example:
1049 - Russian  
IDA_Rate
samples per scale unit
31998
characterize audio playback speed: rate value (sps = rate / scale)
IDA_Scale
scale units per second
2972
characterize audio playback speed: scale value (sps = rate / scale)
IDA_Length
samples
103
total number of audio samples in the audio stream
IDA_Size
bytes
306125
total size of the audio data (without corresponding headers and indexes)
IDA_Sample_Size
bytes
2972
the size of audio sample