Observations after a huge integration

thecaptain

10-01-2008 10:17:31

I just spend the last 5 hours trying to integrate the new version of QuickGUI (since the new rendering system) into our MMOG project, and I think I've finally gotten it to work!

However, there are of course some glitches that I'd like to work through (including the DirectX rendering thing :P).

One thing I noticed was that under OpenGL, if you place a rectangle for rendering a background image for a menu or something (we do this in our game), the GUI doesn't show up! I was able to reproduce this behavior by adding this code into the demo:
// Create background rectangle covering the whole screen
Ogre::Rectangle2D* mRect = new Rectangle2D(true);
mRect->setCorners(-1.0, 1.0, 1.0, -1.0);

// Render the background before everything else
mRect->setRenderQueueGroup(RENDER_QUEUE_BACKGROUND);

// Use infinite AAB to always stay visible
AxisAlignedBox aabInf;
aabInf.setInfinite();
mRect->setBoundingBox(aabInf);

SceneNode* backgroundNode = mSceneMgr->getRootSceneNode()->createChildSceneNode("Background");
backgroundNode->attachObject(mRect);


Even though the rectangle is set to RENDER_QUEUE_BACKGROUND, the GUI is not showing up. This only happens on OpenGL.

I also had a question regarding QuickGUI::Image. Is there a way to simply load an image file and display it? Maybe something like img->loadImage(fighter23.png);? We have a menu screen with all sorts of icons for items, and it wouldn't really make sense to put all of these images into a skinset. If there is a way to do it already, how?

Now finally some sleep...

kungfoomasta

10-01-2008 18:23:47

Image and Sheet widget can have a material applied to it. I could create a convenience method where the user provides a texture, and I wrap it in a material behind the scenes.

Right now the only way to have iamges added to skinsets are to pre-append the skin name to the image name, and make sure its of the same type of the skinset.

qgui.someImage.png
qgui.anotherImage.png

If you delete the Skinset.qgui.png and qgui.skinset files, they will be re-created. During the creation process they will take in any files matching the image extension and skin prefix.

I have no idea regarding the rectangle...