PluginHostType::getHostDescription() fails for Logic on M1

Hi,

this returns “Unknown” for Logic and isLogic() returns false.

thx

Same show on Final Cut Pro X.
I made a little Plugin to test, the returned hostname is the XPCServices:
Bildschirmfoto 2021-01-09 um 23.46.08

Seems none of the PluginHostTypes will work. Don’t know, if Big Sur or M1 Silicon is the culprit.

1 Like

guess it will be the M1 as sandboxing isn’t used on Big Sur, just on M1.

I think it is not sandboxing but the out of process processing. sandboxing relates to the filesystem, IIUC. Here the host is the “AUHostingServiceXPC_arrow”, which is returned by PluginHostType.getHostPath(), which I let print in the screenshot above.
Tere is no way for JUCE with the current approach to know, who spawned the AUHostingServiceXPC process.

I struggle to keep up with Apples changing approaches, so I don’t know if sandboxing and Out-of-process comes in pairs… And I have only a M1 Big Sur and an Intel Mojave. Not a big test farm…

I was referring to the out-of-process when saying sandboxing as I think they come as a pair?

Yes, I wasn’t sure as well, if they come in pairs.

I found a little information on the apple webpage:
https://developer.apple.com/library/archive/documentation/Security/Conceptual/AppSandboxDesignGuide/AppSandboxInDepth/AppSandboxInDepth.html#//apple_ref/doc/uid/TP40011183-CH3-SW24

Seems they are separate. But chances are that the new OS pushes both technologies. I remember a Q&A session with Apple developers IIRC 2017 already, where they said the plan is to move all plugin loading in separate processes.

I wonder if AudioPluginHost will now automatically use out-of-process as well…

So AudioPluginHost doesn’t use XPC:

This is the code btw., in case somebody wants to reproduce:

void TestPluginHostTypeAudioProcessorEditor::paint (juce::Graphics& g)
{
    // (Our component is opaque, so we must completely fill the background with a solid colour)
    g.fillAll (getLookAndFeel().findColour (juce::ResizableWindow::backgroundColourId));

    g.setColour (juce::Colours::white);
    g.setFont (15.0f);
    juce::PluginHostType type;
    juce::String wrapper;
    switch (type.getPluginLoadedAs())
    {
        case juce::AudioProcessor::wrapperType_VST: wrapper = "VST"; break;
        case juce::AudioProcessor::wrapperType_VST3: wrapper = "VST3"; break;
        case juce::AudioProcessor::wrapperType_AudioUnit: wrapper = "AudioUnit"; break;
        case juce::AudioProcessor::wrapperType_AudioUnitv3: wrapper = "AudioUnitv3"; break;
        case juce::AudioProcessor::wrapperType_RTAS: wrapper = "RTAS"; break;
        case juce::AudioProcessor::wrapperType_AAX: wrapper = "AAX"; break;
        case juce::AudioProcessor::wrapperType_Standalone: wrapper = "Standalone"; break;
        case juce::AudioProcessor::wrapperType_Unity: wrapper = "Unity"; break;
        default: wrapper = "Unknown"; break;
    }
    g.drawFittedText (juce::String ("Host: ") + type.getHostDescription() + "\n"
                      + "loaded as: " + wrapper + "\n"
                      + type.getHostPath(), getLocalBounds(), juce::Justification::centred, 1);
}