We have an other issue with PPMulator here, that is also reproducable with the JuceDemoPlugin from current git:
open wavelab 6
add JuceDemoPlugin to the first slot of the master section
remove the plugin
add JuceDemoPlugin again to the same slot
-> wavelab hangs forever before the plugin appears
To put it mildly, Windows 7 / VS2005 / Wavelab 6 is a suboptimal combination for debugging. I tried for a while, but wasn’t able to properly attach the debugger to Wavelab to inspect this any further.
Did anyone else have similar problems in Wavelab 6 and was able to work around it? Since jules is pretty busy with the (exciting!) android stuff, we’re probably on our own with this issue for now.
Hi .
The exact same issue for me.
The problem seems to be linked to a thread that is waiting and waiting…
I’m currently working on it.
If other people have any idea…
if (! messageThreadIsDefinitelyCorrect )
{
MessageManager::getInstance()->setCurrentThreadAsMessageThread();
class MessageThreadCallback : public CallbackMessage
{
public:
MessageThreadCallback (bool& triggered_) : triggered (triggered_) {}
void messageCallback()
{
triggered = true;
}
private:
bool& triggered;
};
(new MessageThreadCallback (messageThreadIsDefinitelyCorrect))->post();
}
}
}[/code]
Look at the static bool messageThreadIsDefinitelyCorrect. it’s false before any instance of the plugin is opened and becomes true with the first instance, and, importantly, remains true even after that first instance is deleted. So I added a static instance counter that is incremented in the wrapper constructor and decremented in the destructor, and changed the crucial line to
if ((!messageThreadIsDefinitelyCorrect) || (instances==1) ), which fixes this issue and, as far as I can see, doesn’t introduce any new ones (you never know with Wavelab :evil: ).