PDA

View Full Version : use dll in mel script


fred007
08-09-2003, 02:34 PM
is it possible to use a function in a dll i've created in a mel script and is yes how ?

mhovland
08-11-2003, 05:02 PM
I think it depends on how you've implimented the function.

First you would have to be compilling an .mll not a .dll

Second you would have to be using MPxCommand to create your own mel command.

I have created my own commands using this method, and as long as the plugin is loaded, I can call the commands I created through a mel interface.

My C++ knowledge is so minimal it isn't really knowledge at all, so take this for what it is, and artist trying to learn to write plugins for Maya.

alexx
08-12-2003, 09:49 AM
should be possible via a "system" command call i would presume

cheers

alexx

fred007
08-12-2003, 12:54 PM
Thanx :thumbsup:

mark_wilkins
08-12-2003, 04:48 PM
I don't think you'd do this via a "system" command, as there's no way to access DLLs from the command line.

Instead, you can make the same Windows system calls you'd make in any other program to load the DLL and call the functions in it.

So, as Mike Hovland implied above, you'd want to wrap your call to the DLL in a Maya command plug-in, then install that and use it in your MEL script.

-- Mark

mhovland
08-12-2003, 05:12 PM
Whew!

Glad I was right :applause:

Thanks for the additional input Mark.

mark_wilkins
08-12-2003, 05:46 PM
Sorry, Mike, I mostly followed up because it took me a while to realize what you meant and I figured that different words might help someone else who came along and read this thread later.

-- Mark

fred007
08-13-2003, 08:20 AM
Thanxs everybody for the precisions ... :thumbsup:

CGTalk Moderation
01-15-2006, 08:00 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.