Click or drag to resize
WaveWriter Class
Writes WAVE (waveform audio format) data to the stream.
Inheritance Hierarchy

Namespace: Alvas.Audio
Assembly: Alvas.Audio (in Alvas.Audio.dll) Version: 2016.0.6173.41573
Syntax
public class WaveWriter : AudioWriter

The WaveWriter type exposes the following members.

Constructors
  NameDescription
Public methodWaveWriter
Initializes a new instance of the WaveWriter class based on the supplied stream and a specific audio format header.
Top
Methods
  NameDescription
Public methodClose
Closes the current BinaryWriter and the underlying stream.
(Inherited from BinaryWriter.)
Public methodDispose
Releases all resources used by the current instance of the BinaryWriter class.
(Inherited from BinaryWriter.)
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Public methodFlush
Clears all buffers for the current writer and causes any buffered data to be written to the underlying device.
(Inherited from BinaryWriter.)
Public methodGetFormat
Returns pointer to audio format.
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodSeek
Sets the position within the current stream.
(Inherited from BinaryWriter.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodWrite(Boolean)
Writes a one-byte Boolean value to the current stream, with 0 representing false and 1 representing true.
(Inherited from BinaryWriter.)
Public methodWrite(Byte)
Writes an unsigned byte to the current stream and advances the stream position by one byte.
(Inherited from BinaryWriter.)
Public methodWrite(SByte)
Writes a signed byte to the current stream and advances the stream position by one byte.
(Inherited from BinaryWriter.)
Public methodWrite(Byte)
Writes a byte array to the underlying stream.
(Inherited from BinaryWriter.)
Public methodWrite(Char)
Writes a Unicode character to the current stream and advances the current position of the stream in accordance with the Encoding used and the specific characters being written to the stream.
(Inherited from BinaryWriter.)
Public methodWrite(Char)
Writes a character array to the current stream and advances the current position of the stream in accordance with the Encoding used and the specific characters being written to the stream.
(Inherited from BinaryWriter.)
Public methodWrite(Double)
Writes an eight-byte floating-point value to the current stream and advances the stream position by eight bytes.
(Inherited from BinaryWriter.)
Public methodWrite(Decimal)
Writes a decimal value to the current stream and advances the stream position by sixteen bytes.
(Inherited from BinaryWriter.)
Public methodWrite(Int16)
Writes a two-byte signed integer to the current stream and advances the stream position by two bytes.
(Inherited from BinaryWriter.)
Public methodWrite(UInt16)
Writes a two-byte unsigned integer to the current stream and advances the stream position by two bytes.
(Inherited from BinaryWriter.)
Public methodWrite(Int32)
Writes a four-byte signed integer to the current stream and advances the stream position by four bytes.
(Inherited from BinaryWriter.)
Public methodWrite(UInt32)
Writes a four-byte unsigned integer to the current stream and advances the stream position by four bytes.
(Inherited from BinaryWriter.)
Public methodWrite(Int64)
Writes an eight-byte signed integer to the current stream and advances the stream position by eight bytes.
(Inherited from BinaryWriter.)
Public methodWrite(UInt64)
Writes an eight-byte unsigned integer to the current stream and advances the stream position by eight bytes.
(Inherited from BinaryWriter.)
Public methodWrite(Single)
Writes a four-byte floating-point value to the current stream and advances the stream position by four bytes.
(Inherited from BinaryWriter.)
Public methodWrite(String)
Writes a length-prefixed string to this stream in the current encoding of the BinaryWriter, and advances the current position of the stream in accordance with the encoding used and the specific characters being written to the stream.
(Inherited from BinaryWriter.)
Public methodWrite(Byte, Int32, Int32)
Writes a region of a byte array to the current stream.
(Inherited from BinaryWriter.)
Public methodWrite(Char, Int32, Int32)
Writes a section of a character array to the current stream, and advances the current position of the stream in accordance with the Encoding used and perhaps the specific characters being written to the stream.
(Inherited from BinaryWriter.)
Public methodWriteData(Byte)
Writes an audio byte array to the underlying stream.
(Overrides AudioWriterWriteData(Byte).)
Public methodWriteData(Byte, Int64)
Writes an audio byte array to the underlying stream from specified position.
(Overrides AudioWriterWriteData(Byte, Int64).)
Public methodWriteData(Byte, Int64, WriteMode)
Writes an audio byte array to the underlying stream from specified position in specified mode.
(Overrides AudioWriterWriteData(Byte, Int64, WriteMode).)
Top
Properties
  NameDescription
Public propertyBaseStream
Gets the underlying stream of the BinaryWriter.
(Inherited from BinaryWriter.)
Top
Examples
This example shows how simple use WaveWriter.
string fileName = "123.wav";
RecorderEx recEx = new RecorderEx();
Stream stream = new FileStream(fileName, FileMode.Create);
WaveWriter wr = new WaveWriter(stream, recEx.FormatBytes());
See Also