cpal
cpal copied to clipboard
How to convert a SizedSample to a f32?
I am trying to upgrade my audio_mixer crate to the latest version of cpal. It currently depends on cpal 0.13.4.
I believe I have to change Sample to SizedSample but I can't find a way to convert a SizedSample to a plain f32.
This is the line I'm struggling to get to compile: https://github.com/tuzz/audio_mixer/blob/f47de2157d249d864a35a50fdd4f3fb562c50576/src/audio_recorder.rs#L34
Is there a conversion trait I need to include?
Thanks
In theory to_sample should work.