C# Класс Translate.Services.Audio.WaveFormatEx

Class WAVEFORMATEX Implementation of a standard WAVEFORMATEX structure
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AudioDurationFromBufferSize ( uint audioDataSize ) : long

Calculate the duration of audio based on the size of the buffer

BufferSizeFromAudioDuration ( long duration ) : long

Calculate the buffer size necessary for a duration of audio

SetFromByteArray ( byte byteArray ) : void

Set the data from a byte array (usually read from a file)

ToHexString ( ) : string

Convert the data to a hex string

ToLittleEndianString ( string bigEndianString ) : string

Convert a BigEndian string to a LittleEndian string

ToString ( ) : string

Ouput the data into a string.

ValidateWaveFormat ( ) : void

Validate that the Wave format is consistent.

Описание методов

AudioDurationFromBufferSize() публичный Метод

Calculate the duration of audio based on the size of the buffer
public AudioDurationFromBufferSize ( uint audioDataSize ) : long
audioDataSize uint the buffer size in bytes
Результат long

BufferSizeFromAudioDuration() публичный Метод

Calculate the buffer size necessary for a duration of audio
public BufferSizeFromAudioDuration ( long duration ) : long
duration long the duration
Результат long

SetFromByteArray() публичный Метод

Set the data from a byte array (usually read from a file)
public SetFromByteArray ( byte byteArray ) : void
byteArray byte The array used as input to the stucture
Результат void

ToHexString() публичный Метод

Convert the data to a hex string
public ToHexString ( ) : string
Результат string

ToLittleEndianString() публичный статический Метод

Convert a BigEndian string to a LittleEndian string
public static ToLittleEndianString ( string bigEndianString ) : string
bigEndianString string A big endian string
Результат string

ToString() публичный Метод

Ouput the data into a string.
public ToString ( ) : string
Результат string

ValidateWaveFormat() публичный Метод

Validate that the Wave format is consistent.
public ValidateWaveFormat ( ) : void
Результат void