Jump to content

All my products and services are free. All my costs are met by donations I receive from my users. If you enjoy using any of my products, please donate to support me. My bare hosting costs are currently not met so please consider donating by either clicking this text or the Patreon link on the right.

Patreon

Recommended Posts

Posted

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.

Posted

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).

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...