Print

Introduction

This is a brief, but detailed guide to use the OGRE SDK and the OGRE SDK AppWizard.

Remember: You don't need anything but Visual C++, the OGRE SDK and the AppWizard.

And you don't need to configure any project options. The wizard takes care of that.

If you run into problems using the wizard, please visit Ogre AppWizard on Google.code(external link) or the Ogre AppWizards Forum(external link)

Get It

Get the OGRE SDK for your compiler : Here(external link)
Get the Microsoft DirectX Redistributable : Here(external link)
Get the OGRE SDK AppWizard for your compiler : Here(external link)

Make sure that the AppWizard matches your version of the OGRE SDK!

Install It

OGRE SDK

Very important!

Do not install this into a directory name with spaces in it, like "My Documents" or the like. You are only asking for trouble.

Choose a sensible no-spaces-in-it name, like C:\OgreSDK.

Install the OGRE SDK.

After installation, we are checking that everything is alright. We want the OGRE_HOME environment variable present, and we want it to point to where the OgreSDK is installed.

It happens by default, but we are checking anyway.

Right-Click the "My Computer" icon, go to the Advanced tab and click on the Environment Variables button.

Enviroment_vars.gif

You should see an OGRE_HOME environment variable pointing to your newly installed OGRE SDK.

OGRE AppWizard

OK. Now unzip the OGRE AppWizard to somewhere safe.

Windows 95/98/2000/Me/XP

Jump into the folder, and find the installation script:

Wizard_install.gif

Double-click on it.

Hopefully it is successful:

Wizard_success.gif

Forget about this directory! You don't need to see it again, nor use it.

Just leave it where it is, alright? :-)

You will create new projects from Visual Studio, not from here.

Windows Vista / Windows Seven

Under Vista, you'll need to run a Command Prompt as administrator.
You can do this by going to Start Menu/All Programs/Accessories, then right-clicking on Command Prompt and selecting Run as administrator.

Once the console windows open, navigate to the folder where the script is located, then type its name (eg.: VC8_setup), followed by Enter.

Once the confirmation window has popped, the setup should be finished. Leave the files where they are.

Use it

Now, it is time to fire up Visual Studio.

Create a New Project

Create a new project:

New_project.gif

Locate the OGRE SDK Application Icon, and don't forget to give your project a name and a place to stay!

Again, you are advised to choose a no-spaces-in-it-path. :-)

SDKApp.gif

Follow the Wizard

Click OK and watch the first page of the OGRE SDK Application Wizard:

Appwizard1.gif

Go to the next page - make sure that the post-build copy is checked:
(If you are using the source, make sure the location is set to "'OGRE_SRC' environment variable" and that that environment variable is defined.)

Appwizard2.gif

Click on "Finish" - and watch your new project:

Test1.gif

Build your Project

Now, open the main source file of the project (Test1.cpp in our case) and remove (or comment) the "SET_TERM_HANDLER" line (should be line 39). This line isn't needed anymore.

You are now ready to build your project.

Build your project:

Test1_build.gif

Watch the output window for success:

Build_success.gif

Notice that the exe is copied to the OgreSDK/bin/debug directory.

Run it

Go to your OgreSDK/bin/debug directory and find your creation:

New_creation.gif

Run it goddamnit! biggrin

FAQ

Upon executing, I receive the following error

If you run into problems running this, look at this guide:
Visual Studio Debugging Settings - Shoggoth

OGRE EXCEPTION(7:InternalErrorException):Could not load dynamic libary .\Plugin_PCZSceneManager.dll. System Error: The specified module could not be found.
in DynLib::load at ..\src\OgreDynLib.cpp (line 80)

Try deleting the following two entries from the Plugins.cfg file:

PCZSceneManager.dll
OctreeZone.dll

The setup doesn't run when I double-click the '.js' setup file.

try adding this to the js extension under run. (In 'Folder Options' in File Explorer.)

C:\WINDOWS\System32\WScript.exe "%1" %*

(If this don't work you must specify the target script language with the flag //E:jscript like
C:\WINDOWS\System32\wscript.exe //E:jscript "%1" %* )

or from the run box

C:\WINDOWS\System32\WScript.exe locationofsetupjs

(If this don't work you must specify the target script language with the flag //E:jscript like
C:\WINDOWS\System32\WScript.exe //E:jscript locationofsetupjs )

Note: If WScript fails, try using CScript)


Alias: The_Complete_Blanks_Guide_To_Using_The_OGRE_SDK_AppWizard


Contributors to this page: jacmoe133512 points  .
Page last modified on Wednesday 30 of June, 2010 21:42:53 UTC by jacmoe133512 points .


The content on this page is licensed under the terms of the Creative Commons Attribution-ShareAlike License.
As an exception, any source code contributed within the content is released into the Public Domain.