set up questions

For help with general CEGUI usage:
- Questions about the usage of CEGUI and its features, if not explained in the documentation.
- Problems with the CMAKE configuration or problems occuring during the build process/compilation.
- Errors or unexpected behaviour.

Moderators: CEGUI MVP, CEGUI Team

fry
Just popping in
Just popping in
Posts: 2
Joined: Thu Oct 16, 2008 15:35

set up questions

Postby fry » Thu Oct 16, 2008 15:47

hello,

I would like to know, what I have to do to compile and run a program using cegui...

what i have done yet:
1. i downloaded the 0.6.1 version and unpacked it
2. in vs2005 options i included the path to the include, lib and bin folder
3. i followed the first tutorial ("The Beginner Guide to Getting CEGUI Rendering") and inserted the code into my directx9 project
4. after error messages saying that the class or namespace is not know, i included "cegui.h"
5. now its saying that "DirectX9Renderer" is not an element of cegui.....


so what am i doing wrong? please, could anyone help me?

User avatar
Kevin
Not too shy to talk
Not too shy to talk
Posts: 29
Joined: Mon May 26, 2008 15:44

Postby Kevin » Thu Oct 16, 2008 17:51

Hello,

It seems that you need to include the file containing the DirectX9Renderer, which is

Code: Select all

\RendererModules\directx9GUIRenderer\d3d9renderer.h


inside the CEGUI folder. So, you should just be able to

Code: Select all

#include<RendererModules/directx9GUIRenderer/d3d9renderer.h>


assuming it can find the other CEGUI include files, like cegui.h (which it seems it can!)

HTH.

fry
Just popping in
Just popping in
Posts: 2
Joined: Thu Oct 16, 2008 15:35

Postby fry » Thu Oct 16, 2008 23:59

hey,

thanks for your reply first!

ok, that "include file" hint was a good one - but then i got about 30 link errors about "cegui (..public: __thiscall CEGUI::String::~String(void)" (__imp_??1String@CEGUI@@QAE@....)
so i took the cegui.h include out (i don't even know if i had to include it..)
and got only 4 errors after it. the first one says that CEGUI::System doesn't have a constructor and point to the following line (copied from the tutorial):

Code: Select all

new CEGUI::System( myRenderer );
another one says "CEGUI::System is an undefined type"...

has anyone another hint for me? what is the main problem - in my opinion i forgot to include something or so...

User avatar
Kevin
Not too shy to talk
Not too shy to talk
Posts: 29
Joined: Mon May 26, 2008 15:44

Postby Kevin » Fri Oct 17, 2008 02:35

Hello again,

You most definitely need to include cegui.h.

The linker errors are suggesting that you are not linking with the necessary .lib files. I'm not sure where it is in VS2005, but in VS2003, it's under Project -> Properties -> Linker -> Input. You need to put under "Additional Dependencies" (in addition to any DirectX libs), CEGUIBase.lib (or CEGUIBase_d.lib) and DirectX9GUIRenderer.lib (or DirectX9GUIRenderer_d.lib).

HTH!

maori
Just can't stay away
Just can't stay away
Posts: 161
Joined: Tue Sep 23, 2008 13:05
Location: Plumstead , UK

Postby maori » Fri Oct 17, 2008 09:53

hiya

just in case you havent done so in your project properties for debug

c++/general/additional depencys add
"$(CEGUI)/include";"$(CEGUI)/dependencies/include";"$(CEGUI)/RendererModules/directx9GUIRenderer"

linker/general/additional lib directorys add something like "$(CEGUI)/lib";"$(CEGUI)/dependencies/lib"

then in linker/general/input additional dependancys add
CEGUIBase_d.lib DirectX9GUIRenderer_d.lib CEGUIFalagardWRBase_d.lib d3d9.lib odbc32.lib odbccp32.lib


for release builds do the same but remove the _d from the libs
the $(CEGUI) comes from adding a enviromental vairiable you could just change that to point to your cegui install path.

dont forget to add the required .dll files to the folder you run your built exe from

hope this helps


Return to “Help”

Who is online

Users browsing this forum: No registered users and 10 guests