Auditioning loops within a plugin


#1

Hi,

I’m developing a plugin that streams audio out of in-built MIDI loops. Apart from the normal streaming playback, I need the plugin editor to allow users to audition the loops before selecting them, and I was wondering what you would recommend for that. Should I:

a) Use the host audio output, the same way like when the host is driving playback. But can I rely on all hosts continuously calling processBlock(), even when not actually playing?
b) Instantiate my own audio output device within the plugin and process my “audition” calls through that. I understand that this raises different issues that must be handled, like having separate audio processing threads, possible allocation issues of the audio device, etc… But on the other side, it would provide a host-independent solution for any audition output.

What do you guys suggest? Thanks for any feedback.

Cheers!

Mariano

P.S. @ Jules: great library, man! I’ll be purchasing a license shortly.


#2

a)
Don’t bother do not anything else imho


#3

Thanks. But you agree that in case the host only calls processBlock when actually playing, audition won’t work. I have read through some posts and am not sure whether all hosts keep calling the callback at all times. What is your experience with the various hosts out there?


#4

Garage Band use to not call process until the user hit play the first time but it might have changed in the latest version
Otherwise never had problem with other hosts.


#5

ok, great to know. I guess all I need is to keep 2 clearly separated modes (normal playback and audition), with 2 different play heads (one from the host, and an internal one).


#6

Yes, don’t try to open your own audio device - it’s a lot of trouble, and might clash with the host’s use of the audio system, so may not even work in some situations.

You can always run a timer to check whether your audio stream is actually playing, and if not, show a message like “please make sure your host is streaming audio in order to hear the preview!” or something.


#7

Cool. Thanks a lot for your help.