I wonder if there is some good built-in way to “preview” (i.e. listen to) an audio file without loading it into an edit.
Obviously I could add a custom audio callback to the JUCE Device Manager and play it from there using an AudioSource but I thought there might be a better way!
There’s a function createEditForPreviewingFile that can be used for this. We use it for our previews, it just attaches itself to the audio device and then you play/loop it like any other Edit.
No, there’s actually a simpler timestretch/pitch method that’s used with preview files so they can be played back immediately. This should all be taken care of if you use the Edit:: createEditForPreviewingFile method.