Class AudioFormat
- Assembly
- MonoGame.Framework.Content.Pipeline.dll
Encapsulates the native audio format (WAVEFORMATEX) information of the audio content.
public sealed class AudioFormat
- Inheritance
-
AudioFormat
- Inherited Members
Properties
AverageBytesPerSecond
Gets the average bytes processed per second.
public int AverageBytesPerSecond { get; }
Property Value
- int
Average bytes processed per second.
BitsPerSample
Gets the bit depth of the audio content.
public int BitsPerSample { get; }
Property Value
- int
If the audio has not been processed, the source bit depth; otherwise, the bit depth of the new format.
BlockAlign
Gets the number of bytes per sample block, taking channels into consideration. For example, for 16-bit stereo audio (PCM format), the size of each sample block is 4 bytes.
public int BlockAlign { get; }
Property Value
- int
Number of bytes, per sample block.
ChannelCount
Gets the number of channels.
public int ChannelCount { get; }
Property Value
- int
If the audio has not been processed, the source channel count; otherwise, the new channel count.
Format
Gets the format of the audio content.
public int Format { get; }
Property Value
- int
If the audio has not been processed, the format tag of the source content; otherwise, the new format tag.
NativeWaveFormat
Gets the raw byte buffer for the format. For non-PCM formats, this buffer contains important format-specific information beyond the basic format information exposed in other properties of the AudioFormat type.
public ReadOnlyCollection<byte> NativeWaveFormat { get; }
Property Value
- ReadOnlyCollection<byte>
The raw byte buffer represented in a collection.
SampleRate
Gets the sample rate of the audio content.
public int SampleRate { get; }
Property Value
- int
If the audio has not been processed, the source sample rate; otherwise, the new sample rate.