PDA

View Full Version : Can reqopen() be used in a modeler script to make a non-modal panel?



GregMalick
04-11-2004, 12:52 AM
As the Subject says "Can reqopen() be used in a modeler script to make a non-modal panel?"

I keep getting "unable to locate function reference reqopen()" when I try it but the reference manual doesn't mention that you can't.

GregMalick
04-13-2004, 09:42 PM
If you search in the forum, you'll see that the answer (for now) is a firm NO!



why am I talking to myself?

Dodgy
04-14-2004, 04:02 AM
Jettobevel manages to do a non-modal requester, it might be worth doing a search for the writer on this forum and asking him how he did it :) And then post the answer here :)

GregMalick
04-14-2004, 09:44 AM
I sent him an email, but from Forum searches I believe that you can only "fake" a non-modal panel. By fake, I mean that you reflect panel changes in an object , but you can't leave the panel up and continue modeling with other tools.

thanks for your input, I'll post what I find out.

Dodgy
04-14-2004, 10:28 AM
That's what I meant, sorry to mislead. It's still more useful than no interactivity then none though :)

GregMalick
04-14-2004, 09:54 PM
The real question is:

"How can we create a real modeling tool that we can use real time?"


Seems like the answer is "we can't".

I'm still not convinced.

Tom Speed
04-15-2004, 08:03 AM
Hi,

Let's see if I remember this correctly:

Non-modal plugins in Modeler use a 'MeshDataEdit' class, that allows for full interactivity with the viewport, and point/poly creation & editing whilst a panel remains open.

Currently LScript doesn't have the ability to access Modeler in this way, although a long time ago Bob Hood (LScript's main developer) hinted he may check it out.

If you check the SDK you'll see that this type of editing gets very 'meaty' :) Lot's of callback functions to handle user events. I'd also be worried about the speed of operation of such an LScript, but if your poly count was low (think game content < 5000poly?) it may not be so bad.

I'd love to see it happen in a future version though, there's plenty of scripts that could be enhanced with non-modal functionality.

Cya!
Tom

GregMalick
04-15-2004, 09:44 AM
Tom,
Let me play back the gist of what I think you said.

LScript can't. Programming with c/c++ using SDK can (but it's real hard).

That about sum it up?

Tom Speed
04-15-2004, 11:09 AM
That's it in a nutshell yeah. I guess for a seasoned C/C++ programmer it's not that hard to do.

Lynx3d
04-15-2004, 06:18 PM
Originally posted by Tom Speed

Non-modal plugins in Modeler use a 'MeshDataEdit' class, that allows for full interactivity with the viewport, and point/poly creation & editing whilst a panel remains open.


That would be 'MeshEditTool', the other is just a subset of 'CommandSequence' class.

I wouldn't say that it's hard to build an interactive tool, it's just more work...if you don't want viewport controls etc you can just grab any SDK example and throw out everything you don't need and just concentrate on the build function and the panel(s)...
But drawing a lot of helpers in the viewport and handle mouse input can yield much code...

GregMalick
04-15-2004, 09:18 PM
Any suggestions on which example to use?

DNA.c claims to use LWPanels to construct the interface and the ModLib library of Modeler functions to issue commands and perform mesh edits. But it's Kinda long.....Box3 is real short and uses the mesh-edit.....

Any known issues with compiling with C++.net?

Lynx3d
04-16-2004, 05:44 AM
Box3 and DNA both are no MeshEditTools...or what are you looking for?

At the botttom of the MeshEditTools page of the SDK are listed some examples, like box4, superq and spikeytool.

Visual C++ .Net should be fine, but i'm using Dev-C++ (it's freeware) so i can't help you there. But the SDK has a compiling description for Visual C++, should basically still work that way in .Net.

Can't help you with LWPanels either, i always used XPanels so far, they're pretty easy to handle, plus LW can show them within its own panels, like in the numeric panel of modeler.
Also haven't used ModLib so far. But to compile the DNA plugin you have to build the modlib library first and add it to the project.