#
OGG output
OGG
: An open container format that is free of software patents and is designed to efficiently stream and manipulate high-quality digital multimedia. It encompasses a range of codecs, with Vorbis being the most commonly used for audio compression.
Use the OGGSinkSettings
class to set the parameters.
#
Block info
Name: OGGSinkBlock.
#
The sample pipeline
graph LR; UniversalSourceBlock-->VorbisEncoderBlock; VorbisEncoderBlock-->OGGSinkBlock;
#
Sample code
var pipeline = new MediaBlocksPipeline();
var filename = "test.mp3";
var fileSource = new UniversalSourceBlock(await UniversalSourceSettings.CreateAsync(new Uri(filename)));
var vorbisEncoderBlock = new VorbisEncoderBlock(new VorbisEncoderSettings());
pipeline.Connect(fileSource.AudioOutput, vorbisEncoderBlock.Input);
var oggSinkBlock = new OGGSinkBlock(new OGGSinkSettings(@"output.ogg"));
pipeline.Connect(vorbisEncoderBlock.Output, oggSinkBlock.CreateNewInput(MediaBlockPadMediaType.Audio));
await pipeline.StartAsync();
#
Platforms
Windows, macOS, Linux, iOS, Android.