Page 1 of 1

Need help with CEGUI + OGRE

Posted: Thu Feb 08, 2007 10:32
by Ender0910
Hi all,

I'm trying to get CEGUI working with OGRE. I've been following this tutorial: http://www.ogre3d.org/wiki/index.php/Basic_Tutorial_6


At first I tried CEGUI 0.5 and OGRE 1.2.5 [Dagon], both downloaded SDKs from the website. The problem was I kept getting link errors! I had linked the two libraries correctly but for some reason it just couldn't find certain functions.


After a lot of messing around, I tried with CEGUI 0.4. I got farther this time. Now I can compile successfully, but when I try to run, it says that "Entry point not found" in certain DLLs.


Any suggestions on how to get CEGUI working? I don't have any odd setups (Using Visual Studio 8 [2005] in Windows XP) and I follow the instructions pretty well.

Posted: Thu Feb 08, 2007 11:47
by mba
First, the dagon-branch including 1.2.5 and the CEGUI 0.5.0 is not directly compatible, its quite easy to make them work together if you are able to compile your own sdk's. If not you need the Eihort branch of ogre which is compatible with 0.5.0.

The following is from Ogres wiki and it shows which lines need to be modified in which files:

Code: Select all

  OgreCEGUITexture.h, Line 109
      virtual void loadFromMemory(const void* buffPtr, uint buffWidth, uint buffHeight, PixelFormat pixelFormat = CEGUI::Texture::PF_RGBA);
  OgreCEGUITexture.cpp, Line 144
      void OgreCEGUITexture::loadFromMemory(const void* buffPtr, uint buffWidth, uint buffHeight, PixelFormat pixelFormat)
  OgreCEGUITexture.cpp, Line 167
      d_ogre_texture = TextureManager::getSingleton().loadRawData(getUniqueName(), "General", odc, buffWidth, buffHeight, pixelFormat ==     
      CEGUI::Texture::PF_RGB ? PF_R8G8B8 : PF_A8R8G8B8, TEX_TYPE_2D, 0, 1.0f);


Otherwise you must use the CEGUI 0.4.1 release if you want it to work out-of-the-box wise.

But I can only recommend that you go straight to 0.5.0 using either Eihort or modifying Dagon, as the 0.5.0 release has some api breaks, architecture changes and a lot of changes in layoutfiles.

Kind regards
Martin Bang Andesen

Posted: Thu Feb 08, 2007 11:49
by mba
... and I'm sorry to say there are no precompiled sdk's of Eihort yet, so if you can't compile it yourself either dagon or eihort, I think you must settle with ogre 1.2.5 + cegui 0.4.1

Posted: Thu Feb 08, 2007 13:08
by Rackle
mba is referring to this post and this wiki entry from the Ogre site, for upgrading Ogre v1.2 to use Cegui v0.5. I haven't starting using the latest Ogre version (still with v1.2) but I'm using the latest Cegui version from SVN.

Posted: Thu Feb 08, 2007 22:18
by Ender0910
Thanks for the replies everyone!

So I think I'm going to give CEGUI 0.4 a swing for now (and do a giant Eihort + CEGUI 0.5 upgrade in the future when everything's stable and happy)

Currently, I get this error when I try to run my application:

Code: Select all

The procedure entry point ?getSceneManager@Root@Ogre@@QAEPAVSceneManager@2@W4SceneType@2@@Z could not be located in the dynamic link library OgreMain_d.dll


Any suggestions on how to fix?
Thanks again! 8)

Posted: Thu Feb 08, 2007 23:05
by mba
I think you should take this to the ogre forums instead, there you'll most likely get a helpful reply on that issue.

kind regards
Martin

Posted: Fri Feb 09, 2007 11:31
by Rackle
Sounds like ogremain.lib is not at the proper version. I would clean the entire solution and rebuild everything.