Custom GUI Development

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
necroMonger
Posts: 5
Joined: Mon Jun 11, 2007 3:36 am

Custom GUI Development

Post by necroMonger »

Hello,

I plan to use Irrlicht engine for my Bachelor thesis assignment :roll: I will have to make an application that will use some customized GUI features for user input. The basic GUI idea, will be as a set of inter-connected nodes. Giving basis to these connections, the output will be affected in real-time.

Quick questions:

1. How can I implement this Node-style behaviour?
Is there already something similar into irrlicht's GUI features?

2. This extension to GUI, how 'deep' will make some one mess with the source? Node GUI behaviour is not the the purpose of my assignment, however if it can be completed in two weeks then I'll try to implement it.
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

Hm, sorry, I don't get it yet. Maybe you could draw a small example for the sort of GUI-Elements which you need?
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
necroMonger
Posts: 5
Joined: Mon Jun 11, 2007 3:36 am

Post by necroMonger »

Here it is, one version of the prototypes I've created.

Image
bitplane
Admin
Posts: 3204
Joined: Mon Mar 28, 2005 3:45 am
Location: England
Contact:

Re: Custom GUI Development

Post by bitplane »

Everything GUI-based in the engine is completely pluggable - you can add your own external elements just by inheriting IGUIElement and adding them to the environment. You don't need to mess with the engine's source, you can build complex GUI elements by inheriting from (file dialog is CGUIWindow) and/or nesting simpler ones (a combo box contains a button and a listbox, listbox contains a scrollbar, a scrollbar contains 2 buttons, etc).
for an example, see the source to the gui elements, and the GUI editor project inside /tools.

If you want to be able to create and edit your new element types in the gui editor, you should
1) override serialize/deserializeAttributes and getType methods of IGUIElement so they can be edited, loaded and saved
2) make sure children (for example text boxes) have setSubElement(true) called so that the GUI knows they are part of their parent and not separate entities.
3) add all your custom elements into a new IGUIElementFactory, so they can be created by name
Submit bugs/patches to the tracker!
Need help right now? Visit the chat room
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

Hey just curious what year are you into your study?
Post Reply