ok my first real try with CEGUI so be kind

Code: Select all
#include "CEGUI.h"
#include "renderers/OpenGLGUIRenderer/openglrenderer.h"
using namespace CEGUI;
#if defined( __WIN32__ ) || defined( _WIN32 )
#define WIN32_LEAN_AND_MEAN
#include "windows.h"
int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine,int nCmdShow)
#else
int MainUI(int argc, char *argv[])
#endif
{
CEGUI::OpenGLRenderer* myRenderer = new CEGUI::OpenGLRenderer(0);
new CEGUI::System(myRenderer);
// we will make extensive use of the WindowManager.
WindowManager& winMgr = WindowManager::getSingleton();
// load scheme and set up defaults
SchemeManager::getSingleton().loadScheme("../datafiles/schemes/TaharezLook.scheme");
System::getSingleton().setDefaultMouseCursor("TaharezLook", "MouseArrow");
FontManager::getSingleton().createFont("../datafiles/fonts/Commonwealth-10.font");
// load an image to use as a background
ImagesetManager::getSingleton().createImagesetFromImageFile("BackgroundImage", "../datafiles/imagesets/1.tga");
// here we will use a StaticImage as the root, then we can use it to place a background image
StaticImage* background = static_cast<StaticImage*>(winMgr.createWindow("TaharezLook/StaticImage", "background_wnd"));
// set position and size
background->setPosition(Point(0, 0));
background->setSize(Size(1, 1));
// disable frame and standard background
background->setFrameEnabled(false);
background->setBackgroundEnabled(false);
// set the background image
background->setImage("BackgroundImage", "full_image");
// install this as the root GUI sheet
System::getSingleton().setGUISheet(background);
Window* sheet = winMgr.createWindow("DefaultWindow", "root_wnd");
// attach this to the 'real' root
background->addChildWindow(sheet);
return true;
}
this compiles ok but when i try running it i get

then on clicking on ignore

and in the CEGUI.log i have
24/08/2006 15:22:53 (InfL1) +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
24/08/2006 15:22:53 (InfL1) + Crazy Eddie's GUI System - Event log +
24/08/2006 15:22:53 (InfL1) + (http://www.cegui.org.uk/) +
24/08/2006 15:22:53 (InfL1) +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
24/08/2006 15:22:53 (InfL1) CEGUI::Logger singleton created.
24/08/2006 15:22:53 (InfL1) ---- Begining CEGUI System initialisation ----
24/08/2006 15:22:53 (InfL1) CEGUI::ImagesetManager singleton created
24/08/2006 15:22:53 (InfL1) CEGUI::FontManager singleton created.
24/08/2006 15:22:53 (InfL1) CEGUI::WindowFactoryManager singleton created
24/08/2006 15:22:53 (InfL1) CEGUI::WindowManager singleton created
24/08/2006 15:22:53 (InfL1) CEGUI::SchemeManager singleton created.
24/08/2006 15:22:53 (InfL1) CEGUI::MouseCursor singleton created.
24/08/2006 15:22:53 (InfL1) CEGUI::GlobalEventSet singleton created.
24/08/2006 15:22:53 (InfL1) CEGUI::WidgetLookManager singleton created.
24/08/2006 15:22:53 (InfL1) WindowFactory for 'DefaultWindow' windows added.
24/08/2006 15:22:53 (InfL1) WindowFactory for 'DragContainer' windows added.
24/08/2006 15:22:53 (InfL1) WindowFactory for 'ScrolledContainer' windows added.
24/08/2006 15:22:53 (InfL1) Window type alias named 'DefaultGUISheet' added for window type 'DefaultWindow'.
24/08/2006 15:22:53 (InfL1) CEGUI::System singleton created.
24/08/2006 15:22:53 (InfL1) ---- CEGUI System initialisation completed ----
24/08/2006 15:22:53 (InfL1) ---- Version 0.4.1 ----
24/08/2006 15:22:53 (InfL1) ---- Renderer module is: CEGUI::OpenGLRenderer - Official OpenGL based renderer module for CEGUI ----
24/08/2006 15:22:53 (InfL1) ---- XML Parser module is: CEGUI::TinyXMLParser - Official tinyXML based parser module for CEGUI ----
24/08/2006 15:22:53 (InfL1) ---- Scripting module is: None ----
24/08/2006 15:22:53 (InfL1) Attempting to load Scheme from file '../datafiles/schemes/TaharezLook.scheme'.
24/08/2006 15:22:53 (InfL1) Attempting to create an Imageset from the information specified in file '../datafiles/imagesets/TaharezLook.imageset'.
24/08/2006 15:23:00 (Error) Exception: Imageset::xmlHandler::startElement - An unexpected error occurred while creating a Texture object from file '../datafiles/imagesets/TaharezLook.tga'
24/08/2006 15:23:00 (Error) Imageset::load - loading of Imageset from file '../datafiles/imagesets/TaharezLook.imageset' failed.
any help greatly apprecited