Halyri - Mobiili  0.9
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events
Halyri.AudioVideoManagers.WaveFileHeader Class Reference

Class for generating canonical WAVE header to an array of PCM samples. More...

Static Public Member Functions

static byte[] AddWaveHeader (byte[] pcm, int bytesPerSample, int channels, int sampleRate)
 Generates WAVE header for the provided PCM sample data. The length of the returned array is data length + 44. The length of the PCM data is limited by the limits of the WAVE header. More...
 

Static Private Attributes

static string chunkID = "RIFF"
 
static string format = "WAVE"
 
static string chunk1ID = "fmt "
 
static string subchunk2ID = "data"
 
static Encoding strEncoding = System.Text.Encoding.UTF8
 
static int headersLength = 44
 
static int chunk1SizeOffset = 8
 

Detailed Description

Class for generating canonical WAVE header to an array of PCM samples.

<author>Veli-Mikko Puupponen</author>

Member Function Documentation

static byte [] Halyri.AudioVideoManagers.WaveFileHeader.AddWaveHeader ( byte[]  pcm,
int  bytesPerSample,
int  channels,
int  sampleRate 
)
static

Generates WAVE header for the provided PCM sample data. The length of the returned array is data length + 44. The length of the PCM data is limited by the limits of the WAVE header.

Parameters
pcmArray of complete PCM samples with no compression
bytesPerSampleNumber of bytes (bits/8) per sample
channelsChannels in the PCM data, 1 for mono 2 for stereo
sampleRateSampling rate of the data
Returns

Member Data Documentation

string Halyri.AudioVideoManagers.WaveFileHeader.chunk1ID = "fmt "
staticprivate
int Halyri.AudioVideoManagers.WaveFileHeader.chunk1SizeOffset = 8
staticprivate
string Halyri.AudioVideoManagers.WaveFileHeader.chunkID = "RIFF"
staticprivate
string Halyri.AudioVideoManagers.WaveFileHeader.format = "WAVE"
staticprivate
int Halyri.AudioVideoManagers.WaveFileHeader.headersLength = 44
staticprivate
Encoding Halyri.AudioVideoManagers.WaveFileHeader.strEncoding = System.Text.Encoding.UTF8
staticprivate
string Halyri.AudioVideoManagers.WaveFileHeader.subchunk2ID = "data"
staticprivate

The documentation for this class was generated from the following file: