Archived

This topic is now archived and is closed to further replies.

3D Studio Max DLL Question

This topic is 5318 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Do you guys know of any way I could call functions from a DLL from 3D Studio Max? Preferably with Maxscript, but I doubt this would be possible so I may have to write a plug-in... Any info on where to start?

Share this post


Link to post
Share on other sites
Max plugins are renamed DLLs with GUIDs and special export functions.

AFAIK MaxScript only lets you access functionality and objects based on Max SDK classes - i.e. internal Max functions AND Max Plugins. But not arbitrary DLLs.

An unmangled export in a plain DLL has no information about input parameters, return values, expectations etc. And without something like IDL or explicitly having to prototype the DLL exports in script, I don''t see a way MaxScript could do it.

So your best bet is probably to write a plugin (there''s an AppWizard in the SDK) to interface between script and the external DLL. For most plain DLLs that don''t have complex external dependencies it''d be really easy to do. The object your plugin exported would be accessable as a scripting object.

--
Simon O''Connor
Creative Asylum Ltd
www.creative-asylum.com

Share this post


Link to post
Share on other sites