Request: Plugin Tails

Hi Jules,

Would you mind adding the following feature: getting plugin tails? There’s currently no support for this, afaict…

May be worth noting that there is somewhat of a caveat: Audio Units give this value as a double (Float64), while VST gives this value as a platform-dependent integer (VstIntPtr)…


/** Tells the host that this plugin has a tail, and what its length is (in seconds)

    For VSTs, 0 is default, 1 means 'no tail', any other value is a tail length. (This is as mostly stated in the VST SDK documentation online)
    For AUs, you simply return a tail length
virtual double getTailSize() { return 0.0; }

juce_VSTPluginFormat - VSTPluginInstance:

double getTailSize() { return (double)dispatch (effGetTailSize, 0, 0, 0, 0); }

Just noticed the Introjucer is setup to add this functionality…

I personally don’t think it’s a good idea to have it setup through the Introjucer since, for example, a reverb plugin can have varying tail lengths. Instead, when creating a plugin via the Introjucer, the getTailSize() method (as I’ve called it) should be generated for the user, returning 0.

That would indeed be a better solution, but would need to be rolled out to all the formats, etc. No time to look at it right now…

Multiformat feature implementation challenge accepted (for when you’ve time to take a look, of course):

double getTailSize()
    double tailSize = 0.0;

    AudioUnitGetProperty (audioUnit, kAudioUnitProperty_TailTime,
                          kAudioUnitScope_Global, 0, &tailSize, sizeof (double));

    return tailSize;

(Not tested)

Going all out for shits and giggles - Introjucer implementation(?)


double FILTERCLASSNAME::getTailSize()
    return 0.0;


"double FILTERCLASSNAME::getTailSize()\r\n"
"    return 0.0;\r\n"

Cool. But do the RTAS/AAX formats have an equivalent concept too?

Ah, sorry - I can’t say since I don’t have the SDK; I’m not an Avid-registered plugin developer…

I’ve begun implementing this in my fork (see my signature). I’ve no idea if the AudioUnit code is correct - I wrote it by deduction. Also, I do not have the means of writing the AAX/RTAS code to support this feature.

If anyone can take a look and let me know if it’s right, I’d appreciate it!


Mind taking a better look at this, Jules?

Ok, sanity-checking welcome…

Alright so when creating a dummy/test VST plugin with JUCE; I specify 10 seconds for tail, and receive 0 in the PluginHost when running it. I guess it’s not being truly implemented?

Right, so the VST wrapper is just missing the VST implementation of the nicely named method: “getGetTailSize()”:

    VstInt32 getGetTailSize()
        return (VstInt32) (filter->getTailLengthSeconds() * (double) getSampleRate());

“getGetTailSize”?? Was one “get” not enough?

Not a clue. Maybe Steinberg foresaw the implementation being a “getting” of “getting” a tail size.

Bizarre… Oh well, I’ve added that now, thanks!