I have created a class that allows visualizing the object hierarchy of scene nodes and gui elements.
It has two modes, "windowed" and "stand-alone". It displays the DebugName, the id and the name of scene nodes (that can be assigned with ISceneNode::setName() ) or the text of gui elements respectively.
If an object is not visible an asterisk ("*") is put in front of it.
Please note that the "DebugNames" of objects are displayed. These are only available in debug build of the engine. However, unfortunately not all Irrlicht objects have a "DebugName" currently (Irrlicht 0.8 ). If an object has none, then "NO_DEBUG_NAME" will be displayed instead. This is also the case for ALL objects in Release build of the engine (_DEBUG macro unset).
Niko: The debug name thing is really a great thing, not only for this viewer. But since the are not set in many classes it looses its usefulness a bit. If I were you, I'd make them complete in the next version.
Here is two screenshots:
This is the demo with the viewer built in (stand-alone). Many of the debug names are added by me. Normally you would see more "NO_DEBUG_NAME"s. The names "Sydney" and "Sydney Spheremap" I have set with setName().
Here is the viewer (windowed) in the User Interface example with untouched debug names. As you see only my viewer actually has one...
Well, if anyone likes to try it out you can download it here:
http://development.mindfloaters.de/Downloads.12.0.html
jox
New tool class CGUIIrrObjectTreeViewer
New tool class CGUIIrrObjectTreeViewer
It is like it is. And because it is like it is, things are like they are.
Re: New tool class CGUIIrrObjectTreeViewer
Funny thing
In 0.9, all SceneNodes and GUI elements will have set the name.jox wrote:Niko: The debug name thing is really a great thing, not only for this viewer. But since the are not set in many classes it looses its usefulness a bit. If I were you, I'd make them complete in the next version.