When a file is being played with the playback
application and the speed is changed with eg.
uuid_fileman speed:+1 the audio pitch increases.
This commit tries to preserve the pitch even when the
speed is changed.
How?
+ Use longer sample chunks (where original freq is preserved)
+ Search for the best cut position using cross-correlation
+ Crossfade adjacent chunks to each other
This updated co-authored commit from the original attempts
to optimize memory usage by allocating memory on the heap
for samples of the previous frame, but using stack memory
for the modified data that is flushed to the buffer.
Co-authored-by: hari <lharangozo@feastfox.com>
Co-authored-by: Joseph Nadiv <ynadiv@corpit.xyz>