Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

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

xekon
Just popping in
Just popping in
Posts: 14
Joined: Thu Jan 21, 2010 00:07

Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby xekon » Wed Feb 03, 2010 22:25

Here is a complete working example using Ogre 1.7 and CEGUI 0.7 Branch SVN. Feel free to sticky this, I hope it helps others.
Many THANKS to CrazyEddie for his help and the Developer Documents as well. http://www.cegui.org.uk/docs/current/

I have updated Xavire's Practical Application Cegui example to use the new Ogre 1.7 and Cegui 0.7:
PracticalApp_CEGUI DOWNLOAD: http://www.megaupload.com/?d=J7FRMCPS

wiki source (old example, don't download here): http://test.ogitor.org/tiki/Practical+A ... +More+Meat
wiki source (old example, don't download here): http://www.ogre3d.org/wiki/index.php/Pr ... _More_Meat

You will need Ogre 1.7 SVN: https://svn.ogre3d.org/svnroot/ogre/branches/v1-7
Cegui 0.7 Branch SVN: https://crayzedsgui.svn.sourceforge.net ... nches/v0-7
(turtoise SVN: http://tortoisesvn.net/downloads)

Cegui Dependencies: http://www.cegui.org.uk/wiki/index.php/ ... oads_0.7.1
(Extract to the Cegui folder, IE: cegui\dependencies)

You will also need a copy of "premake.exe" to put in your cegui\projects\premake folder

Next you need to configure cegui for OGRE use before you build it (config.lua)
Look for the below values and set them accordingly then save the file (obviously set the paths according to where your ogre folder resides):

Code: Select all

STATIC_BUILD_WITH_DYNAMIC_DEPS = true

OGRE_PATHS = { "E:/dev/ogre/OgreMain", "include", "lib" }
OIS_PATHS = { "E:/dev/ogre/Dependencies", "include/OIS", "lib" }

OPENGL_RENDERER = false
DIRECT3D9_RENDERER = false
DIRECT3D10_RENDERER = false
IRRLICHT_RENDERER = false
OGRE_RENDERER = true

SAMPLES_GL = false
SAMPLES_DX9 = false
SAMPLES_DX10 = false
SAMPLES_IRRLICHT = false
SAMPLES_OGRE = true

then run the corresponding batch build file to build cegui project settings.

After you build cegui, find the "cegui\cegui\include" folder

copy that "include" folder to "ogre\Dependencies\include"

so you will have: "ogre\Dependencies\include\include"

then rename it so that it is: "ogre\Dependencies\include\cegui"

Build Ogre using CMake: http://www.ogre3d.org/wiki/index.php/Bu ... With_CMake

Set an environmental variable for the location of your ogre folder.

Variable name: OGRE_HOME

Variable value: E:\dev\ogre
(obviously set this to the path where your ogre folder resides)

Then in in your PracticalApp_CEGUI project settings goto general section and look for

Output Directory & Intermediate Directory and set them to: $(OGRE_HOME)\build\bin\debug
then in the Debugging Section look for Working Directory and set it to: $(OGRE_HOME)\build\bin\debug

also make a copy of "datafiles" folder to the "ogre\build\bin" folder
so you will have "ogre\build\bin\datafiles"
the "datafiles" folder can be found at: "cegui\datafiles\"

make a copy of resource folder included with PracticalApp_CEGUI to the ogre\build\bin\debug folder
copy all of the .dll files from "cegui\dependencies\bin" to "ogre\build\bin\debug"

You should now be able to build and run this program.
Last edited by xekon on Thu Feb 18, 2010 16:54, edited 8 times in total.

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

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby CrazyEddie » Thu Feb 04, 2010 09:40

Cool. Thanks for writing this up, I'm sure there's many people who will find it helpful :)

I have make the post sticky.

CE.

qweqweqq
Just popping in
Just popping in
Posts: 1
Joined: Sun Feb 14, 2010 19:44

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby qweqweqq » Sun Feb 14, 2010 19:54

Hi there. I've just looked through the renewed tutorial (didn't see the old one version though).
All three programs have the same code anyway, I checked.
And, well, I don't want to be rude, but are you sure about updating it?

For example, in main.cpp you have this line:

Code: Select all

   CEGUI::SchemeManager::getSingleton().loadScheme((CEGUI::utf8*)"TaharezLookSkin.scheme", (CEGUI::utf8*)"GUI");

As you may know, in v0.7 loadScheme was renamed into create

Not only this, it also uses OgreCEGUIRenderer.h, which is not there and named another way.

So, either-or, but the program isn't going to work with new versions, as intended.

xekon
Just popping in
Just popping in
Posts: 14
Joined: Thu Jan 21, 2010 00:07

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby xekon » Thu Feb 18, 2010 16:38

hmm im not using .loadScheme, I have:

Code: Select all

CEGUI::SchemeManager::getSingleton().create( "TaharezLook.scheme" );

also if you look at the top of the file in main.cpp you will see that I am NOT using OgreCEGUIRenderer.h:

Code: Select all

#include "RendererModules/Ogre/CEGUIOgreRenderer.h"

where did you download my example from? did you download it from the megaupload link I provided?

please let me know if you have any further questions

Jamarr
CEGUI MVP
CEGUI MVP
Posts: 812
Joined: Tue Jun 03, 2008 23:59
Location: USA

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby Jamarr » Thu Feb 18, 2010 20:14

I've just looked through the renewed tutorial

pretty sure he was referring to the wiki pages you linked, as they have not been updated.
If somebody helps you by replying to your thread, upvote him/her as a thanks! Make sure to include your CEGUI.log and everything you tried when posting! And remember that we are not magicians!

Nomen
Just popping in
Just popping in
Posts: 1
Joined: Thu Feb 18, 2010 20:10

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby Nomen » Thu Feb 18, 2010 21:22

Hi, I'm new here so go easy on me :p.
I got a question, according to this source: http://www.cegui.org.uk/docs/current/re ... orial.html you need to create a CEGUI::System object and call CEGUI::System::renderGUI every frame, but I can't find these calls anywhere in the source code? Why is that? How does it work?

Edit: after reading the source CEGUIOgreRenderer.h & cpp code for a bit, I think the bootstrap function does these things somehow, *keeps read*

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

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby CrazyEddie » Fri Feb 19, 2010 09:51

Hi,

Go easy on you? :lol:

The tutorial is correct that you need to create the CEGUI::System object and call the renderGUI function. With regards to system creation, you are correct that the bootstrap helper function does this for you, it's actually mentioned towards the bottom of the tutorial: http://www.cegui.org.uk/docs/current/re ... strap_ogre

With regards to calling the System::renderGUI function, the tutorial does say:
the tutorial wrote:For users of the Ogre3D engine, this step is taken care of automatically.

However, this is not particularly helpful in explaining how or why this is the case. Basically, due to the way we hook into the Ogre rendering process - via an Ogre::FrameListener - this function is automatically called as part of the overall Ogre rendering.

As mentioned in another recent thread, this default behaviour can actually be overridden by disabling rendering on the CEGUI::OgreRenderer (which causes our FrameListener to do nothing on subsequent calls), then you are free to call the System::renderGUI function whenever you like (as part of your own custom FrameListener, a RenderQueueListener, or manually at some other time of your choosing). Though for most uses the default should be fine.

HTH

CE.

azrialelf
Just popping in
Just popping in
Posts: 7
Joined: Sun Jul 08, 2007 21:36

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby azrialelf » Thu Oct 28, 2010 04:08

This looks fantastic - However, can anyone give me some instructions on how to configure cegui for OGRE use before building in Xcode? I've tried following the existing tutorials, but they all involve running the Visual Studio .bat file.
I was able to get the Xcode version of CEGUI to build, but not with OgreRenderer.h included, so I can't get it to work with Ogre.

So, more specifically, what would the equivalent steps be for the following chunk of the tutorial in Xcode?

Next you need to configure cegui for OGRE use before you build it (config.lua)
Look for the below values and set them accordingly then save the file (obviously set the paths according to where your ogre folder resides):

Code: Select all
STATIC_BUILD_WITH_DYNAMIC_DEPS = true

OGRE_PATHS = { "E:/dev/ogre/OgreMain", "include", "lib" }
OIS_PATHS = { "E:/dev/ogre/Dependencies", "include/OIS", "lib" }

OPENGL_RENDERER = false
DIRECT3D9_RENDERER = false
DIRECT3D10_RENDERER = false
IRRLICHT_RENDERER = false
OGRE_RENDERER = true

SAMPLES_GL = false
SAMPLES_DX9 = false
SAMPLES_DX10 = false
SAMPLES_IRRLICHT = false
SAMPLES_OGRE = true


then run the corresponding batch build file to build cegui project settings.


Hopefully someone can help out or point me to some kind of documentation of the Xcode User Defined build configurations. If I could just see what the available flags are I think I could figure it out.

Thanks!

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

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby CrazyEddie » Tue Nov 02, 2010 10:17

To build The Ogre renderer with Xcode you basically just have to set the SDK location in the Xcode project, and then either directly build the CEGUIOgreRenderer target, or add it to the 'CEGUI Frameworks' group target so it gets built along with the rest of the frameworks.

Ok, so where do you do this?! Open up the project in Xcode, select the root of the project 'CEGUI' and bring up the inspector. Select the 'Build' options. In the 'Configuration' drop-down, select 'All configurations' and in the 'Show' drop-down, select 'All Settings'. Change the value under Architectures to '$(CEGUI_OGRE_ARCHS)' - this may or may not be required, but since the SDK version of Ogre is i386 only, we assume people will be using this. In the 'Show' drop-down, select 'User-defined Settings'. You will now see a bunch of definitions that are intended to be customised, and one of these is 'CEGUI_OGRE_SDK_PATH', you need to set the value of this to wherever the Ogre SDK is, and the CEGUIOgreRenderer framework should then build.

And that's about it.

HTH

CE.

som-kun
Just popping in
Just popping in
Posts: 1
Joined: Sat Aug 20, 2011 03:13

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby som-kun » Sat Aug 20, 2011 03:35

i'm using your example to the letter using ubuntu 11.04 with cegui 0.7.5 and ogre 1.7.3, but i'm getting this error when i run

/home/andrew/workspace/test/Debug/test: error while loading shared libraries: libCEGUIOgreRenderer-0.7.5.so: cannot open shared object file: No such file or directory

my library search folders are as such
/usr/lib/OIS
/usr/local/lib/OGRE
/usr/local/lib <= the file IS in this folder

and -l libs are
OIS
OgreMain
CEGUIOgreRenderer

any help would be awesome!

kurisu-san
Just popping in
Just popping in
Posts: 3
Joined: Tue Jan 31, 2012 22:50

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby kurisu-san » Wed Feb 01, 2012 18:54

Where can i get this from now that megaupload has been smushed by the feds?

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

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby CrazyEddie » Fri Feb 03, 2012 09:44

I have no idea. Perhaps contacting your nearest FBI office is an option :hammer:

CE.

kurisu-san
Just popping in
Just popping in
Posts: 3
Joined: Tue Jan 31, 2012 22:50

Re: Xavier's PracticalApp_CEGUI update Ogre1.7 & CEGUI 0.7

Postby kurisu-san » Fri Feb 03, 2012 16:48

Haha my nearest FBI office is over 3000 miles away.

I managed to get everything working with the wiki tutorials anyway.

Cheers anyway eddie :)


Return to “Help”

Who is online

Users browsing this forum: No registered users and 9 guests