Speex encoder
WAV encoder block can produce a PCM stream with a specified format.
Use WAVEncoderSettings class to set the parameters.
Block info
Name: WAVEncoderBlock.
Pin direction | Media type | Pins count |
---|---|---|
Input | PCM | 1 |
Output | PCM | 1 |
The sample pipeline
FileSourceBlock
→ WAVEncoderBlock
→ WAVSinkBlock
Sample code
var pipeline = new MediaBlocksPipeline(false);
var fileSource = new FileSourceBlock();
fileSource.Filename = "test.mp3";
var wavEncoderBlock = new WAVEncoderBlock(new WAVEncoderSettings());
pipeline.Connect(fileSource.Output, wavEncoderBlock.Input);
var wavSinkBlock = new WAVSinkBlock(@"output.wav");
pipeline.Connect(wavEncoderBlock.Output, wavSinkBlock.Input);
await pipeline.StartAsync();
Platforms
Windows, macOS, Linux, iOS, Android.