How to make GUI controls with FPS camera??

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
steveybop
Posts: 30
Joined: Wed Mar 02, 2005 2:52 pm

How to make GUI controls with FPS camera??

Post by steveybop »

I have a program using the FPS style camera, which uses the mouse to control the direction the camera is pointing. What i want is a GUI to allow the user to control some values, but how do you make the GUI accessable if the mouse is used for the camera??

i was thinking that the only way to do it is to make the GUI first, like a setup screen then take these values and render the scene on its own. IS this the only way to do it and would this require 2 render loops?

if any body could make any suggestions, it would be welcome. I wanted something similar to the mesh viewer (tutorial 9) which seems to have an accessable GUI at runtime.
DISCLAIMER: Having read this post & all information therein,you have entered into a legally binding contract.You are obliged to agree wholeheartedly with all opinions expressed within this post.Failure to comply will be deemed a breach of contract.
Midnight
Posts: 1772
Joined: Fri Jul 02, 2004 2:37 pm
Location: Wonderland

Post by Midnight »

ok this is a difficult question to answer..

it sounds like you want an options screen...

or possably controls like "Evil Genius" has for example (3d elements with mostly gui controls)

it's not possable to make a FPS using mouse for the camera AND having gui unless there was a way to stop control of the camera so the mouse could be used like the mesh viewer.

I suggest you look at the techdemo that should show you exactly how to do a menu "before" the game... there are no working examples of "in game" options like a menu you can bring up in the middle of the game a "pause menu" for example.

I might be able to explain more in depth if I had a better idea of exactly what you're trying to achieve.
steveybop
Posts: 30
Joined: Wed Mar 02, 2005 2:52 pm

Post by steveybop »

What i have is more like a simulation than a game, what i need is to allolw the user to specify some values using scroll bars and some options using (probably) combo box. They dont have to be "in game", i just thought it may be easier to have them always there as opposed to popped up once.

What i had envisioned at the start was a setup like mesh viewer, GUI on side with options, user sets options then presses a run button which runs render loop for simulation, tehn changes what they want and press run again etc
Therefore, GUI always there and changable, actual 3D graphics being rendered along side the GUI. This would require seperate render loops right?


Ps is the source for the tech demo available, where?
DISCLAIMER: Having read this post & all information therein,you have entered into a legally binding contract.You are obliged to agree wholeheartedly with all opinions expressed within this post.Failure to comply will be deemed a breach of contract.
Midnight
Posts: 1772
Joined: Fri Jul 02, 2004 2:37 pm
Location: Wonderland

Post by Midnight »

o ok yeah thats totally do-able... you would probably want to setup some kind of event to make the window appear when the simulation is finished or not playing... the techdemo help you with this.

you can download the techdemo yes it comes with Irrlicht and is in the same exact place the meshviewer is I believe it's called simply "demo"

depends what version of irrlicht you have i think but by now everyone should be using 0.9 I think.

No I don't think you would use 2 render loops for anything (could be wrong)
run different classes like the techdemo or use events to call the window visable or something.
Post Reply