Page 1 of 1

Controller Plugin crashes OpenSim

Posted: Fri Jul 29, 2022 2:56 pm
by mlaudu
I have a problem that started since OpenSim 4.2 and up to the current 4.4. I defined a muscle controller function and created a dll file as a plugin for it. In these versions of OpenSim, the GUI will only load the model files containing this controller if I add the file to a 'plugin' folder and put the dll file there. However, whenever I load a motion file associated with the model, OpenSim crashes and instantly closes. Any help with that? I attach here the model file containing the controller (oneleg_1.osim), the four source files I used to create the plugin - 'MuscleController.cpp', 'MuscleController.h', 'osimMuscleControllerDLL.h', 'RegisterTypes_osimMuscleController.cpp' and 'RegisterTypes_osimMuscleController.h'.