stephen Posted January 10, 2014 Share Posted January 10, 2014 I finally got around to dedicating some time to XDMD. I would like to create an out of proc ActiveX control to provide DMD support for Visual Pinball original tables.I am able to create a C# out of proc ActiveX control, call it from Visual Pinball VB script, and set break points in the ActiveX control. Straight forward.I am able to create a console app that calls XDMD to display the PinballX image (like in the XDMD Demo app, but within a console app). Cool beans.In the ActiveX control, I created a method called Test that would invoke XDMD to display the PinballX image (I made sure the "current directory" was where all of the DLLs and assets were located).I create the object in Visual Pinball script and called the Test method in the left flipper event handler.Results:A window appears in the middle of the display, but nothing was drawn (it was all white). When hovered over the task bar icon for the Virtual DMD I it said "not responding".My Test method spawns a thread to talk to XDMD. That way I can return immediately to VP. The thread has a while loop (like XDMD Demo) and looks for "ready". The PinballX transition takes about < 2 seconds. My code loops for < 2 seconds before the XDMD device becomes ready again. That tells me the XDMD Device Render is doing the right thing, timing wise, to schedule the animations. But nothing appears.I look at the modules loaded while running the console app and compared to the modules loaded within the ActiveX app. The ActiveX app loads all of the same DLLs. So I don't think it's a permissions/access, or search path, or GAC thing.Does anybody have experience which might point me in the right direction? I am hoping there is a simple and obvious solution that I hadn't thought of. Quote Link to comment Share on other sites More sharing options...
stephen Posted January 10, 2014 Author Share Posted January 10, 2014 This forum is magic. I messed with this for 3 hours and couldn't get it working. I post my question, take a break, and when I come back to it - I have it solved in 15 minutes.I'm still not sure why it didn't work before, but I now create the XDMD.Device on ActiveX startup instead of in the object instance (which is the correct design anyway). Quote Link to comment Share on other sites More sharing options...
unclewilly Posted January 10, 2014 Share Posted January 10, 2014 Really excited for this.Vp has needed this for years 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.