#
Scale/Tempo
The block scales tempo while maintaining pitch.
#
Block info
Name: ScaleTempoBlock.
#
The sample pipeline
graph LR; UniversalSourceBlock-->ScaleTempoBlock; ScaleTempoBlock-->AudioRendererBlock;
#
Sample code
var pipeline = new MediaBlocksPipeline();
var filename = "test.mp3";
var fileSource = new UniversalSourceBlock(await UniversalSourceSettings.CreateAsync(new Uri(filename)));
var tempo = new ScaleTempoBlock();
tempo.Overlap = 0.2;
tempo.Rate = 0.1;
tempo.Search = TimeSpan.FromMilliseconds(14);
tempo.Stride = TimeSpan.FromMilliseconds(30);
pipeline.Connect(fileSource.AudioOutput, tempo.Input);
var audioRenderer = new AudioRendererBlock();
pipeline.Connect(tempo.Output, audioRenderer.Input);
await pipeline.StartAsync();
#
Platforms
Windows, macOS, Linux, iOS, Android.