# Hide audioparameters from host\[SOLVED\]

**URL:** <https://forum.juce.com/t/hide-audioparameters-from-host-solved/33810>\
**Category:** General JUCE discussion\
**Created:** [June 10, 2019, 10:55am UTC](https://forum.juce.com/t/hide-audioparameters-from-host-solved/33810 "2019-06-10T10:55:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![TheWaveWarden](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/thewavewarden/32/13708_2.png) [@TheWaveWarden](https://forum.juce.com/u/TheWaveWarden)\
**Post date:** [June 10, 2019, 10:55am UTC](https://forum.juce.com/t/hide-audioparameters-from-host-solved/33810/1 "2019-06-10T10:55:31Z")

</div>

is there a way to make an audioparamter not visible to the host, i.e. not controllable from outside the plugin editor?

I know I could add them to the valuetree without being an audioparameter, but I just wondered if there’s a flag or something to hide existing ones.

---

<div class="post-metadata">

**Author:** ![daniel](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/daniel/32/790_2.png) [@daniel](https://forum.juce.com/u/daniel)\
**Post date:** [June 10, 2019, 11:07am UTC](https://forum.juce.com/t/hide-audioparameters-from-host-solved/33810/2 "2019-06-10T11:07:10Z")

</div>

There was an “[isAutomatable()](https://docs.juce.com/develop/classAudioProcessorParameter.html#abcb70fe341ff9e30c7e1c5f6f9dae447)” flag in the past. It was removed from the constructor arguments in one of the latest refactoring of the AutopProcessorParameter classes.  
I can only assume, that since there were many hosts ignoring that flag anyway, it made no sense to have it configurable.

The flag is still inherent in the category, e.g. you can’t automate an inputGain (which is communicated to the host via parameters).

---

<div class="post-metadata">

**Author:** ![TheWaveWarden](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/thewavewarden/32/13708_2.png) [@TheWaveWarden](https://forum.juce.com/u/TheWaveWarden)\
**Post date:** [June 10, 2019, 8:21pm UTC](https://forum.juce.com/t/hide-audioparameters-from-host-solved/33810/3 "2019-06-10T20:21:04Z")

</div>

Ok then I’ll add them to the ValueTree directly.

I did some test trying to add them and succeeded, however when I print the tree it looks like this:

```auto
<Odin foo="4.2e1" bar="4.3e1">
  <PARAM id="amount_1_[0]" value="0"/>
  <PARAM id="amount_1_[1]" value="0"/>
  <PARAM id="amount_1_[2]" value="0"/>

```

The params added are foo and bar. Why are they in the Odin braces…? Is this how it is supposed to be? looks weird to me…

---

<div class="post-metadata">

**Author:** ![daniel](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/daniel/32/790_2.png) [@daniel](https://forum.juce.com/u/daniel)\
**Post date:** [June 10, 2019, 8:30pm UTC](https://forum.juce.com/t/hide-audioparameters-from-host-solved/33810/4 "2019-06-10T20:30:26Z")

</div>

It is totally up to you, how you add your values to the ValueTree.

The ValueTree is XML, so you added it using `setProperty()`, which translates to XML attributes.  
If you want it more generic, add your own child nodes to the ValueTree (best not to name them “PARAM”) and set the value as property there.

e.g.

```auto
auto node = treeState.state.getOrCreateChild ("Custom", nullptr);
auto param = node.getOrCreateChild ("MyParam", nullptr);
param.setProperty ("id", paramID, nullptr);
param.setProperty ("value", value, nullptr);

```

Whatever works for you, the host will not read or interpret that data.

---

<div class="post-metadata">

**Author:** ![TheWaveWarden](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/thewavewarden/32/13708_2.png) [@TheWaveWarden](https://forum.juce.com/u/TheWaveWarden)\
**Post date:** [June 10, 2019, 8:39pm UTC](https://forum.juce.com/t/hide-audioparameters-from-host-solved/33810/5 "2019-06-10T20:39:16Z")

</div>

cool thanks for the explanation! 🙂
