# VST3 Wrapper

**URL:** <https://forum.juce.com/t/vst3-wrapper/12056>\
**Category:** Audio Plugins\
**Created:** [December 19, 2013, 2:06pm UTC](https://forum.juce.com/t/vst3-wrapper/12056 "2013-12-19T14:06:36Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![chkn](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/chkn/32/3862_2.png) [@chkn](https://forum.juce.com/u/chkn)\
**Post date:** [December 19, 2013, 2:06pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/1 "2013-12-19T14:06:36Z")

</div>

Any news, when it will be added to juce?

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [December 19, 2013, 3:01pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/2 "2013-12-19T15:01:29Z")

</div>

Sorry, deep in Tracktion5 panic-mode&nbsp;at the moment, and concentrating on hosting.. Should be early in the new year!

---

<div class="post-metadata">

**Author:** ![chkn](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/chkn/32/3862_2.png) [@chkn](https://forum.juce.com/u/chkn)\
**Post date:** [December 19, 2013, 3:32pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/3 "2013-12-19T15:32:30Z")

</div>

cool :)

---

<div class="post-metadata">

**Author:** ![siedschl](https://avatars.discourse-cdn.com/v4/letter/s/4bbf92/32.png) [@siedschl](https://forum.juce.com/u/siedschl)\
**Post date:** [December 20, 2013, 9:14am UTC](https://forum.juce.com/t/vst3-wrapper/12056/4 "2013-12-20T09:14:39Z")

</div>

What's the hosting status? I just read your "news" comment about it... is there still anything we could do to help? Which are the plugins that are not working at the moment?

---

<div class="post-metadata">

**Author:** ![olilarkin](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/olilarkin/32/7142_2.png) [@olilarkin](https://forum.juce.com/u/olilarkin)\
**Post date:** [December 20, 2013, 9:55am UTC](https://forum.juce.com/t/vst3-wrapper/12056/5 "2013-12-20T09:55:15Z")

</div>

i noticed IPlug-made&nbsp;VST3 plugins are not working in the Plugin Demo host. this might be because they are based on SingleComponentEffect? Jules - if you want a test plugin let me know

---

<div class="post-metadata">

**Author:** ![jrlanglois](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/jrlanglois/32/21372_2.png) [@jrlanglois](https://forum.juce.com/u/jrlanglois)\
**Post date:** [December 20, 2013, 2:10pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/6 "2013-12-20T14:10:00Z")

</div>

> What's the hosting status?&nbsp;I just read your "news" comment about it... is there still anything we could do to help? Which are the plugins that are not working at the moment?

The following&nbsp;plugins that I can test&nbsp; **don't** work correctly:

- _iZotope's Ozone5, Insight, Meter Tap_&nbsp;and _Iris&nbsp;_plugins&nbsp;appear&nbsp;to load fine, but none of them&nbsp;show their UI
- _MeldaProductions_' _MDynamicEQ_ cans the host on load for, at the time of this message, what&nbsp;is a presently an unknown reason
- _Steinberg_'s _ADelay_ crashes on deletion
- _Steinberg's HostChecker_&nbsp;kills the host when calling EditController's setComponentState(). If I comment that sequence out, _Host Checker_ works as it should (except it leaks memory like there's no tomorrow!)

So what does work, without hassle?

- Seemingly every other _MeldaProductions'_ plugins' do
- Likewise for FabFilter
- _Steinberg's Note Expression Synth_, both with and without UI

---

<div class="post-metadata">

**Author:** ![jrlanglois](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/jrlanglois/32/21372_2.png) [@jrlanglois](https://forum.juce.com/u/jrlanglois)\
**Post date:** [December 20, 2013, 2:19pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/7 "2013-12-20T14:19:00Z")

</div>

> i noticed IPlug-made&nbsp;VST3 plugins are not working in the Plugin Demo host. this might be because they are based on SingleComponentEffect? Jules - if you want a test plugin let me know

A test plugin would be fantastic, and greatly appreciated!&nbsp;

---

<div class="post-metadata">

**Author:** ![siedschl](https://avatars.discourse-cdn.com/v4/letter/s/4bbf92/32.png) [@siedschl](https://forum.juce.com/u/siedschl)\
**Post date:** [January 29, 2014, 4:15pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/8 "2014-01-29T16:15:40Z")

</div>

I just built the latest demo host on Maverick. iZotope Nectar 2 and NUGEN Stereoplacer both load but show a blank GUI. MeldaProduction MDrummer loads but crashes the host when trying to open the GUI (with an assertion in the destructor of ReferenceCountedObject). Jules, can we/should we do anything to help, or are you already deeply involved in solving this yourself ?

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [January 29, 2014, 4:23pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/9 "2014-01-29T16:23:09Z")

</div>

Hmm - haven't tried those plugins.. We'll try to look at them when we can, but any clues would be welcome!

---

<div class="post-metadata">

**Author:** ![jrlanglois](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/jrlanglois/32/21372_2.png) [@jrlanglois](https://forum.juce.com/u/jrlanglois)\
**Post date:** [January 29, 2014, 6:19pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/10 "2014-01-29T18:19:26Z")

</div>

I've handed over a juce-integrated VST3 client implementation to Jules, along with a series of changes to the VST3 hosting side, so _much_ testing will be needed in the (hopefully) near future to get things working appropriately.

Since writing the hosting side, I noticed that all iZotope plugs give the same result (load&nbsp;but window/graphic-less),&nbsp;without a damned clue why. This is on both Mac and Windows. They're probably all expecting a different order of things to happen, or something is commonly missing. Who knows; we basically need someone from iZotope to tell us.

---

<div class="post-metadata">

**Author:** ![siedschl](https://avatars.discourse-cdn.com/v4/letter/s/4bbf92/32.png) [@siedschl](https://forum.juce.com/u/siedschl)\
**Post date:** [February 11, 2014, 1:20pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/11 "2014-02-11T13:20:40Z")

</div>

Still no luck with Meldaproduction and Stereoplacer (black windows) with the tip of today (on a Maverick Mac). I've tried "FabFilter One" (free demo available) and the UI is displayed fine, generally everything seems to work but when deleting the plugin window the destructor is being called twice, leading to an assumption in the leak detector for VST3PluginWindow:

```
~VST3PluginWindow()
    {
        view->removed();
        getAudioProcessor()->editorBeingDeleted (this);

       #if JUCE_MAC
        dummyComponent.setView (nullptr);
        [pluginHandle release];
       #endif

       const Steinberg::FReleaser releaser (view);
    }
```

The culprit seems the Steinberg releaser, which again causes the VST3PluginWindow destructor to be called. If I comment out the releaser line, everything's good and I get no leakage...

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [February 11, 2014, 1:24pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/12 "2014-02-11T13:24:23Z")

</div>

I checked in a fix for that about half an hour ago..

---

<div class="post-metadata">

**Author:** ![siedschl](https://avatars.discourse-cdn.com/v4/letter/s/4bbf92/32.png) [@siedschl](https://forum.juce.com/u/siedschl)\
**Post date:** [February 11, 2014, 1:35pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/13 "2014-02-11T13:35:07Z")

</div>

Most excellent! Works, thanks!

---

<div class="post-metadata">

**Author:** ![siedschl](https://avatars.discourse-cdn.com/v4/letter/s/4bbf92/32.png) [@siedschl](https://forum.juce.com/u/siedschl)\
**Post date:** [February 12, 2014, 4:29pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/14 "2014-02-12T16:29:26Z")

</div>

More news from the plugins that show a black UI (mainly Meldaproduction): when building the 64 bit version of the plugin host, everything's fine, the issue only occurs with the 32 bit version...

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [February 12, 2014, 5:05pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/15 "2014-02-12T17:05:43Z")

</div>

OSX or Windows?

---

<div class="post-metadata">

**Author:** ![siedschl](https://avatars.discourse-cdn.com/v4/letter/s/4bbf92/32.png) [@siedschl](https://forum.juce.com/u/siedschl)\
**Post date:** [February 12, 2014, 5:50pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/16 "2014-02-12T17:50:12Z")

</div>

OSX Mavericks.

---

<div class="post-metadata">

**Author:** ![railjonrogut](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/railjonrogut/32/505_2.png) [@railjonrogut](https://forum.juce.com/u/railjonrogut)\
**Post date:** [February 12, 2014, 7:51pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/17 "2014-02-12T19:51:51Z")

</div>

On both OSX and Win8… and can be recreated using the demo plugin…

```auto
#ifndef JucePlugin_MaxNumOutputChannels
 #define JucePlugin_MaxNumOutputChannels 32
#endif
```

The plugin only has 14 outputs.

Rail

---

<div class="post-metadata">

**Author:** ![jrlanglois](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/jrlanglois/32/21372_2.png) [@jrlanglois](https://forum.juce.com/u/jrlanglois)\
**Post date:** [February 13, 2014, 2:47pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/18 "2014-02-13T14:47:00Z")

</div>

Off the top of my head, is it possible the&nbsp;VST3 code is just not providing a speaker configuration?

The latest SDK shows a max of&nbsp;24 channels:&nbsp;Steinberg::Vst::SpeakerArr::kString222

---

<div class="post-metadata">

**Author:** ![jrlanglois](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/jrlanglois/32/21372_2.png) [@jrlanglois](https://forum.juce.com/u/jrlanglois)\
**Post date:** [February 13, 2014, 3:08pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/19 "2014-02-13T15:08:14Z")

</div>

```
/** The equivalent numChannels and speaker arrangements should always
    match between this function and fillWithCorrespondingSpeakerArrangements().
    There can only be 1 arrangement per channel count. (i.e.: 4 channels == k31Cine OR k40Cine)
    @see fillWithCorrespondingSpeakerArrangements
*/
static Steinberg::Vst::SpeakerArrangement getArrangementForNumChannels (int numChannels) noexcept
{
    using namespace Steinberg::Vst::SpeakerArr;
    if (numChannels == 24)  return (Steinberg::Vst::SpeakerArrangement) 1929904127; // Known as "k222" - for backwards compatibility with older SDKs
    if (numChannels == 14)  return k131;
    if (numChannels == 13)  return k130;
    if (numChannels == 12)  return k111;
    if (numChannels == 11)  return k101;
    if (numChannels == 10)  return k91;
    if (numChannels == 9)   return k90;
    if (numChannels == 8)   return k71CineFullFront;
    if (numChannels == 7)   return k61Cine;
    if (numChannels == 6)   return k51;
    if (numChannels == 5)   return k50;
    if (numChannels == 4)   return k31Cine;
    if (numChannels == 3)   return k30Cine;
    if (numChannels == 2)   return kStereo;
    if (numChannels == 1)   return kMono;
    // Custom channel configuration:
    if (numChannels > 0)
    {
        juce::BigInteger bi;
        bi.setRange (0, jmin (numChannels, (int) (sizeof (Steinberg::Vst::SpeakerArrangement) * 8)), true);
        return (Steinberg::Vst::SpeakerArrangement) bi.toInt64();
    }
    return kEmpty;
}
/** The equivalent numChannels and speaker arrangements should always
    match between this function and getArrangementForNumChannels().
    There can only be 1 arrangement per channel count. (i.e.: 4 channels == k31Cine OR k40Cine)
    @see getArrangementForNumChannels
*/
static void fillWithCorrespondingSpeakerArrangements (Array<Steinberg::Vst::SpeakerArrangement>& destination,
                                                      int numChannels)
{
    using namespace Steinberg::Vst::SpeakerArr;
    destination.clearQuick();
    if (numChannels <= 0)
    {
        destination.add (kEmpty);
        return;
    }
    /*
        The order of the arrangement checks must be descending, since most plugins test for
        the first arrangement to match their number of specified channels.
    */
    // Custom channel configuration:
    if (numChannels > 24)
    {
        juce::BigInteger bi;
        bi.setRange (0, jmin (numChannels, (int) (sizeof (Steinberg::Vst::SpeakerArrangement) * 8)), true);
        destination.add ((Steinberg::Vst::SpeakerArrangement) bi.toInt64());
    }
    if (numChannels >= 24)  destination.add ((Steinberg::Vst::SpeakerArrangement) 1929904127); // Known as "k222" - for backwards compatibility with older SDKs
    if (numChannels >= 14)  destination.add (k131);
    if (numChannels >= 13)  destination.add (k130);
    if (numChannels >= 12)  destination.add (k111);
    if (numChannels >= 11)  destination.add (k101);
    if (numChannels >= 10)  destination.add (k91);
    if (numChannels >= 9)   destination.add (k90);
    if (numChannels >= 8)   destination.add (k71CineFullFront);
    if (numChannels >= 7)   destination.add (k61Cine);
    if (numChannels >= 6)   destination.add (k51);
    if (numChannels >= 5)   destination.add (k50);
    if (numChannels >= 4)   destination.add (k31Cine);
    if (numChannels >= 3)   destination.add (k30Cine);
    if (numChannels >= 2)   destination.add (kStereo);
    if (numChannels >= 1)   destination.add (kMono);
}
```

---

<div class="post-metadata">

**Author:** ![railjonrogut](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/railjonrogut/32/505_2.png) [@railjonrogut](https://forum.juce.com/u/railjonrogut)\
**Post date:** [February 14, 2014, 11:24pm UTC](https://forum.juce.com/t/vst3-wrapper/12056/20 "2014-02-14T23:24:00Z")

</div>

The latest tip (139e192) fixes the outputs issue (Yay).

The OSX Demo Host 64 bit only shows a black GUI though.

On quitting the host I got:

```auto
*** Leaked objects detected: 1 instance(s) of class ContentWrapperComponent
JUCE Assertion failure in juce_LeakedObjectDetector.h:95
```

from juce\_VST3PluginFormat.cpp line 946

Cheers,

Rail

[Next page](https://forum.juce.com/t/vst3-wrapper/12056.md?page=2)
