C# 클래스 NAudio.Wave.WaveFormat

파일 보기 프로젝트 열기: jishi/Jishi.StreamToSonos 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
averageBytesPerSecond int
bitsPerSample short
blockAlign short
channels short
extraSize short
sampleRate int
waveFormatTag WaveFormatEncoding

공개 메소드들

메소드 설명
ConvertLatencyToByteSize ( int milliseconds ) : int

Gets the size of a wave buffer equivalent to the latency in milliseconds.

CreateALawFormat ( int sampleRate, int channels ) : WaveFormat

Creates an A-law wave format

CreateCustomFormat ( WaveFormatEncoding tag, int sampleRate, int channels, int averageBytesPerSecond, int blockAlign, int bitsPerSample ) : WaveFormat

Creates a WaveFormat with custom members

CreateIeeeFloatWaveFormat ( int sampleRate, int channels ) : WaveFormat

Creates a new 32 bit IEEE floating point wave format

CreateMuLawFormat ( int sampleRate, int channels ) : WaveFormat

Creates a Mu-law wave format

Equals ( object obj ) : bool

Compares with another WaveFormat object

FromFormatChunk ( BinaryReader br, int formatChunkLength ) : WaveFormat

Reads in a WaveFormat (with extra data) from a fmt chunk (chunk identifier and length should already have been read)

GetHashCode ( ) : int

Provides a Hashcode for this WaveFormat

MarshalFromPtr ( IntPtr pointer ) : WaveFormat

Helper function to retrieve a WaveFormat structure from a pointer

MarshalToPtr ( WaveFormat format ) : IntPtr

Helper function to marshal WaveFormat to an IntPtr

Serialize ( BinaryWriter writer ) : void

Writes this WaveFormat object to a stream

ToString ( ) : string

Reports this WaveFormat as a string

WaveFormat ( ) : System

Creates a new PCM 44.1Khz stereo 16 bit format

WaveFormat ( BinaryReader br ) : System

Reads a new WaveFormat object from a stream

WaveFormat ( int sampleRate, int channels ) : System

Creates a new 16 bit wave format with the specified sample rate and channel count

WaveFormat ( int rate, int bits, int channels ) : System

Creates a new PCM format with the specified sample rate, bit depth and channels

비공개 메소드들

메소드 설명
ReadWaveFormat ( BinaryReader br, int formatChunkLength ) : void

메소드 상세

ConvertLatencyToByteSize() 공개 메소드

Gets the size of a wave buffer equivalent to the latency in milliseconds.
public ConvertLatencyToByteSize ( int milliseconds ) : int
milliseconds int The milliseconds.
리턴 int

CreateALawFormat() 공개 정적인 메소드

Creates an A-law wave format
public static CreateALawFormat ( int sampleRate, int channels ) : WaveFormat
sampleRate int Sample Rate
channels int Number of Channels
리턴 WaveFormat

CreateCustomFormat() 공개 정적인 메소드

Creates a WaveFormat with custom members
public static CreateCustomFormat ( WaveFormatEncoding tag, int sampleRate, int channels, int averageBytesPerSecond, int blockAlign, int bitsPerSample ) : WaveFormat
tag WaveFormatEncoding The encoding
sampleRate int Sample Rate
channels int Number of channels
averageBytesPerSecond int Average Bytes Per Second
blockAlign int Block Align
bitsPerSample int Bits Per Sample
리턴 WaveFormat

CreateIeeeFloatWaveFormat() 공개 정적인 메소드

Creates a new 32 bit IEEE floating point wave format
public static CreateIeeeFloatWaveFormat ( int sampleRate, int channels ) : WaveFormat
sampleRate int sample rate
channels int number of channels
리턴 WaveFormat

CreateMuLawFormat() 공개 정적인 메소드

Creates a Mu-law wave format
public static CreateMuLawFormat ( int sampleRate, int channels ) : WaveFormat
sampleRate int Sample Rate
channels int Number of Channels
리턴 WaveFormat

Equals() 공개 메소드

Compares with another WaveFormat object
public Equals ( object obj ) : bool
obj object Object to compare to
리턴 bool

FromFormatChunk() 공개 정적인 메소드

Reads in a WaveFormat (with extra data) from a fmt chunk (chunk identifier and length should already have been read)
public static FromFormatChunk ( BinaryReader br, int formatChunkLength ) : WaveFormat
br System.IO.BinaryReader Binary reader
formatChunkLength int Format chunk length
리턴 WaveFormat

GetHashCode() 공개 메소드

Provides a Hashcode for this WaveFormat
public GetHashCode ( ) : int
리턴 int

MarshalFromPtr() 공개 정적인 메소드

Helper function to retrieve a WaveFormat structure from a pointer
public static MarshalFromPtr ( IntPtr pointer ) : WaveFormat
pointer System.IntPtr WaveFormat structure
리턴 WaveFormat

MarshalToPtr() 공개 정적인 메소드

Helper function to marshal WaveFormat to an IntPtr
public static MarshalToPtr ( WaveFormat format ) : IntPtr
format WaveFormat WaveFormat
리턴 System.IntPtr

Serialize() 공개 메소드

Writes this WaveFormat object to a stream
public Serialize ( BinaryWriter writer ) : void
writer System.IO.BinaryWriter the output stream
리턴 void

ToString() 공개 메소드

Reports this WaveFormat as a string
public ToString ( ) : string
리턴 string

WaveFormat() 공개 메소드

Creates a new PCM 44.1Khz stereo 16 bit format
public WaveFormat ( ) : System
리턴 System

WaveFormat() 공개 메소드

Reads a new WaveFormat object from a stream
public WaveFormat ( BinaryReader br ) : System
br System.IO.BinaryReader A binary reader that wraps the stream
리턴 System

WaveFormat() 공개 메소드

Creates a new 16 bit wave format with the specified sample rate and channel count
public WaveFormat ( int sampleRate, int channels ) : System
sampleRate int Sample Rate
channels int Number of channels
리턴 System

WaveFormat() 공개 메소드

Creates a new PCM format with the specified sample rate, bit depth and channels
public WaveFormat ( int rate, int bits, int channels ) : System
rate int
bits int
channels int
리턴 System

프로퍼티 상세

averageBytesPerSecond 보호되어 있는 프로퍼티

for buffer estimation
protected int averageBytesPerSecond
리턴 int

bitsPerSample 보호되어 있는 프로퍼티

number of bits per sample of mono data
protected short bitsPerSample
리턴 short

blockAlign 보호되어 있는 프로퍼티

block size of data
protected short blockAlign
리턴 short

channels 보호되어 있는 프로퍼티

number of channels
protected short channels
리턴 short

extraSize 보호되어 있는 프로퍼티

number of following bytes
protected short extraSize
리턴 short

sampleRate 보호되어 있는 프로퍼티

sample rate
protected int sampleRate
리턴 int

waveFormatTag 보호되어 있는 프로퍼티

format type
protected WaveFormatEncoding waveFormatTag
리턴 WaveFormatEncoding