Quick Sign In:  

Forum: VirtualDJ Plugins

Topic: Process to generate .bundle for mac - Page: 2
locoDogPRO InfinityModeratorMember since 2013
Thanks, wouldn't char parStatus[2048]; hold it on the stack?
std::format I'll look into, stringstream was taught to me very early. I learn bits of the std library from time to time when I get sick of reinventing the wheel with primitives, I never got there with stringstream because it was pretty straight forward.

**EDIT** std::format, just as easy, I just need to use it 50 times and I might remember it.
 

Posted Wed 13 Dec 23 @ 7:03 pm
AdionPRO InfinityCTOMember since 2006
When using char parStatus[2048]; it just means that it's part of CMyPlugin8 storage.
It then depends on how the memory for CMyPlugin8 is created on where that is stored.
If you would create the plugin in a function like:

void myfunction()
{
CMyPlugin8 myPlugin;
}

Then it would indeed be on the stack, and that would indeed be problematic if it's big.
But myPlugin can also be created on the heap, like CMyPlugin8 *myPlugin = new CMyPlugin8() in which case that is no concern.

There's 2 reasons you can know CMyPlugin8 is created like that.
-A plugin object needs to exist for a long time, so unless a new thread is created with its own stack just to hold the stack object alive, it would have to be stored on the heap
-VirtualDJ doesn't even know the specifics of CMyPlugin8, all it knows is that there is a function DllGetClassObject that can be used to create the plugin. And it turns out that that function is completely in your control, and indeed creates the CMyPlugin8 on the heap :)
 

Posted Thu 14 Dec 23 @ 6:36 am
locoDogPRO InfinityModeratorMember since 2013
Ahh ok, makes sense, all the tutorials I dip in & out of are general stand alone things, I never considered the implications of it being called by another program.
thanks

One final question; How would a mac user bypass the security hand holding employed for unregistered programs?
$100 (or whatever apple charge now) isn't much but I'm still completely against it on principle. [ It's like something out of UBIK, if you know Philip K Dick Sc-Fi ]
 

Posted Thu 14 Dec 23 @ 7:05 am
AdionPRO InfinityCTOMember since 2006
I don't think there's a way to really disable the mac security, so if you want to create programs/plugins for other people you most likely will need to join the apple developer program yes.
 

Posted Thu 14 Dec 23 @ 7:19 am
I'm glad to hear that the potential stack overflow issue isn't a concern with the way CMyPlugin8 is created on the heap.
 

Posted Tue 06 Feb 24 @ 1:45 pm
How do I load this on my Mac (Silicon). So I have cloned (https://github.com/szemek/virtualdj-plugins-examples ) and loaded the basic-plugin-with-default-interface into XCode. Built the .bundle file. Now when I created the plugins folder on my laptop, I found one at /Users/Username/Library/Application\ Support/VirtualDJ/PluginsMacArm. Should I just drop the .bundle directly inside this? Or should I put it in a specific sub-folder? I tried several things but it simply does not show my plugin when I open VirtualDJ and search for MyPlugin8 inside the VirtualDJ Extensions tab. How do I get this plugin activated and working?
 

Posted Tue 25 Jun 24 @ 9:56 am
szemekPRO InfinityMember since 2019
user29149771 wrote :
How do I get this plugin activated and working?


https://www.virtualdj.com/wiki/Developers.html
The plugin must be copied in the following folders:
[PC] .\Documents\VirtualDJ\Plugins\{Sub-Folder} for VirtualDJ - 32bit (dll in 32bit)
[PC] .\Documents\VirtualDJ\Plugins64\{Sub-Folder} for VirtualDJ - 64bit (dll in 64bit)
[Mac] ./Documents/VirtualDJ/Plugins64/{Sub-Folder} for VirtualDJ - 64bit (bundle in 64bit)
[Mac Arm/Apple Silicon] ./Documents/VirtualDJ/PluginsArm/{Sub-Folder} for VirtualDJ - ARM 64bit (bundle in 64bit)


For available examples:
basic & audio plugins go to SoundEffect
video fx plugin goes to VideoEffect
video transition goes to VideoTransition
online source plugin goes to OnlineSources
 

Posted Tue 25 Jun 24 @ 5:41 pm