[Solved] Unity Plugin & Parameters


I was building a Unity Plugin with hasEditor:false and I was using APVTS to get the parameters.

The sliders appear, but the listener appears to be deaf!

So, I’ve implemented this with the AudioParameterFloat (as advised in the blog post on unity plugin support ) , which works.

Can this be done with the APVTS approach?


It should. However, the AudioProcessorValueTreeState is Timer-driven:

I risk a guess, that the MessageManager is not running the Timer on Unity, if there is no Editor.
This needs looking into…

[Solved] Automation without GUI

Is it fixed in this commit?


I thought it would be useful to also ask a question an range normalisation here too.

In my plugin, I have a slider that is ranged -1 to 1. In unity it appears as 0 to 1. But Unity can have ranged sliders, e.g.

[ Range(-1.0f, 1.of)]
public float value = 0f;

Is it possible to fix this?


No @t0m - I’m working from the commit that comes after that.


I’ve got a fix for this, will push shortly.


@ed95 - working. Thanks again for the super speedy response.


Unfortunately not. All the other plug-in interfaces communicate parameter values via normalised values, but display un-normalised values. This is especially important for parameters with non-uniform ranges where a 0->1 range maps to an x->y range in an unpredictable (but monotonically increasing) fashion. Unity sliders without a 0->1 range would attempt to communicate un-normalised values.


OK, Understood. It’s not a big issue.

The values can be normalised in Unity to 0->1 before controlling the slider.