Ogre 1.00 R1 and using ::setText()

For help with anything that CEGUI doesn't offer straight out-of-the-box, e.g.:
- Implementation of new features, such as new Core classes, widgets, WindowRenderers, etc. ...
- Modification of any existing features for specific purposes
- Integration of CEGUI in new engines or frameworks and writing of new plugins (Renderer, Parser, ...) or modules

Moderators: CEGUI MVP, CEGUI Team

User avatar
Van
Just can't stay away
Just can't stay away
Posts: 225
Joined: Fri Jan 21, 2005 20:29
Contact:

Ogre 1.00 R1 and using ::setText()

Postby Van » Thu Feb 10, 2005 21:39

I am porting to Ogre 1.00 RC1.

My app, which was working prior to the port is now having a linker problem.

First, It appears that I had to replace all the CEGUI::Strings with Ogre::Strings. Is this true? Or am I missing something here too?

Next, I am getting a linker error:

Code: Select all

clsApplicationFL.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall CEGUI::String::String(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (__imp_??0String@CEGUI@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in function "public: virtual bool __thiscall clsApplicationFL::frameEnded(struct Ogre::FrameEvent const &)" (?frameEnded@clsApplicationFL@@UAE_NABUFrameEvent@Ogre@@@Z)
clsCameraDialog.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall CEGUI::String::String(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (__imp_??0String@CEGUI@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)
Debug/GPE.exe : fatal error LNK1120: 1 unresolved externals


on all elements that do anything similar to:

Code: Select all

   mGuiOrtho[i]->setText(mStr);


I am including the following libs:
OgreMain_d.lib
CEGUIBase_d.lib
OgreGUIRenderer_d.lib


What am I missing?

User avatar
Mdobele
Just popping in
Just popping in
Posts: 10
Joined: Wed Jan 12, 2005 12:06
Location: Brisbane / Australia
Contact:

Re: Ogre 1.00 R1 and using ::setText()

Postby Mdobele » Fri Feb 11, 2005 00:41

I have only ever used Ogre::Strings sorry but I can help you with them. When passing them around you can simply go.

Ogre::String MyString( " Some Text " ) ;
CEGUIThing->setText( MyString.c_str() );
Visit the PrimdGames website
www.primedgames.com

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Re: Ogre 1.00 R1 and using ::setText()

Postby CrazyEddie » Fri Feb 11, 2005 09:47

CEGUI is not a part of Ogre, so any CEGUI elements will always use CEGUI::String. No changes have been made in this area, and no changes are planned in this area.

If you need to use an Ogre::String with CEGUI then you use the c_str() method as directed by Mdobele.

As for the linker errors, I woul need to see some of the offending code.

CE.


Return to “Modifications / Integrations / Customisations”

Who is online

Users browsing this forum: No registered users and 22 guests