What are DAWs reading when scanning the plugins folders?

DSP, Plug-in and Host development discussion.
Fender19
KVRist
467 posts since 30 Aug, 2012

Post Fri Jul 31, 2020 10:56 pm

When I attach Logic Pro X to the debugger in Xcode it shows that my AU plugin's constructor is not called until the plugin is actually loaded onto a track. Scanning the plugin in Plugin Manager shows no action, i.e., a hitpoint at the constructor is not triggered.

So if the plugin constructor is not being called during plugin scanning what are DAWs reading that tells them the I/O configuration capabilities of the available plugins? Is there some other function or header file that provides the plugin I/O information?

How, exactly, does this work?
Last edited by Fender19 on Sat Aug 01, 2020 7:32 am, edited 1 time in total.

User avatar
syntonica
KVRian
644 posts since 25 Sep, 2014 from Specific Northwest

Post Fri Jul 31, 2020 11:20 pm

As far as I recall, auval and DAWs do instantiate the plugin and poke it with numerous sticks.

User avatar
Vokbuz
KVRist
207 posts since 24 Aug, 2014 from Moscow

Post Sat Aug 01, 2020 4:35 am

AudioUnits have all required info in the Info.plist file. There is no need to instantiate plugin to get its information.

For I/O instantiation required and it should be done.

Fender19
KVRist
467 posts since 30 Aug, 2012

Post Sat Aug 01, 2020 7:32 am

syntonica wrote:
Fri Jul 31, 2020 11:20 pm
As far as I recall, auval and DAWs do instantiate the plugin and poke it with numerous sticks.
That's what I thought too - so then why doesn't it show that in the debugger? I don't see anything happening until the plugin is actually loaded in a track.

Fender19
KVRist
467 posts since 30 Aug, 2012

Post Sat Aug 01, 2020 7:34 am

Vokbuz wrote:
Sat Aug 01, 2020 4:35 am
AudioUnits have all required info in the Info.plist file. There is no need to instantiate plugin to get its information.
I don't see any plugin I/O configuration info in the plugin's Info.plist file - only build and version data.

Fire Sledge - Ohm Force
KVRist
119 posts since 2 Nov, 2000 from 404 - Not found

Post Sat Aug 01, 2020 12:23 pm

Fender19 wrote:
Sat Aug 01, 2020 7:32 am
That's what I thought too - so then why doesn't it show that in the debugger? I don't see anything happening until the plugin is actually loaded in a track.
Probably because the host uses a separate process to collect the information. If the plug-in crashes hard because of some issue (missing resource, dongle, poor implementation, etc.) this doesn’t crash the host.

Fender19
KVRist
467 posts since 30 Aug, 2012

Post Sat Aug 01, 2020 3:04 pm

Fire Sledge - Ohm Force wrote:
Sat Aug 01, 2020 12:23 pm
Fender19 wrote:
Sat Aug 01, 2020 7:32 am
That's what I thought too - so then why doesn't it show that in the debugger? I don't see anything happening until the plugin is actually loaded in a track.
Probably because the host uses a separate process to collect the information. If the plug-in crashes hard because of some issue (missing resource, dongle, poor implementation, etc.) this doesn’t crash the host.
Any tips on how to debug it in that case?

Jeff McClintock
KVRist
319 posts since 30 Jan, 2005 from New Zealand

Post Sun Aug 02, 2020 4:08 pm

Fender19 wrote:
Sat Aug 01, 2020 3:04 pm
Fire Sledge - Ohm Force wrote:
Sat Aug 01, 2020 12:23 pm
Fender19 wrote:
Sat Aug 01, 2020 7:32 am
That's what I thought too - so then why doesn't it show that in the debugger? I don't see anything happening until the plugin is actually loaded in a track.
Probably because the host uses a separate process to collect the information. If the plug-in crashes hard because of some issue (missing resource, dongle, poor implementation, etc.) this doesn’t crash the host.
Any tips on how to debug it in that case?
Scanning a plugin is pretty quick, so you usually don't have the opportunity to attach a debugger. In this situation, I sometimes temporarily add a dialog box to the plugin's constructor. What this does is pause the plugin and give you the time to attach a debugger.

User avatar
MadDogE134
KVRian
525 posts since 26 Nov, 2007

Post Sun Aug 02, 2020 4:21 pm

as far as i know the DAW is just looking for a 'listing' to place in it's browser although in Studio One for instance during the scan it also looks for validation of the plugin like ilok returned response or checking if demo items are current or expired. i don't think it is an actual 'call' for the plugin... just scans attached info

it is sad that those who are disadvantaged tend to complain less than those who are able


Fender19
KVRist
467 posts since 30 Aug, 2012

Post Mon Aug 03, 2020 9:38 am

MadDogE134 wrote:
Sun Aug 02, 2020 4:21 pm
i don't think it is an actual 'call' for the plugin... just scans attached info
What attached info? There is nothing in the plugin Info.plist about plugin I/O capabilities.

How does the DAW "know" if a plugin is mono or stereo, has side chain capability, etc.? Somehow the DAW determines that BEFORE the plugin is loaded into a project - so the DAW displays the plugin in the applicable channel FX lists, etc.

This is baffling! How does it work?

lkjb
KVRist
164 posts since 13 Oct, 2012

Post Mon Aug 03, 2020 11:16 am

Why don't you write some log output to a file and have a look at said file after running the plugin scan.
It is also possible that the DAW and even Plugin Manager doesn't scan the plugin again as long as it hasn't change. For that the plugin file's timestamps, size and even version could be checked.

Regarding debugging a plugin scan: I remember vaguely that this won't work if the scan is done by another process. I think I ran into this when trying to figure out why auval wouldn't validate a plugin in Logic but had to run auvaltool instead of Logic for debugging. Nowadays you have to copy auvaltool to some location where you can actually select it for debugging but luckily, I haven't had to do this for some time so I'm not sure.

Fender19
KVRist
467 posts since 30 Aug, 2012

Post Mon Aug 03, 2020 2:54 pm

lkjb wrote:
Mon Aug 03, 2020 11:16 am
Regarding debugging a plugin scan: I remember vaguely that this won't work if the scan is done by another process. I think I ran into this when trying to figure out why auval wouldn't validate a plugin in Logic but had to run auvaltool instead of Logic for debugging. Nowadays you have to copy auvaltool to some location where you can actually select it for debugging but luckily, I haven't had to do this for some time so I'm not sure.
Yes, I did that with auvaltool and now I can see what's happening in auvaltool. However, some plugins that PASS auval FAIL in Logic. That is what I'm dealing with right now. I can't "see" what's happening in Logic before the plugin is actually loaded onto a track to understand what's preventing it from loading.

Return to “DSP and Plug-in Development”