Time for action — starting the project and configuring the IDE
As with any other library, we need to configure our IDE before we can use it with Ogre 3D.
- Create a new empty project.
- Create a new file for the code and name it
main.cpp
. - Add the main function:
int main (void) { return 0; }
- Include
ExampleApplication.h
at the top of the following source file:#include "Ogre\ExampleApplication.h":
- Add
PathToYourOgreSDK\include\
to the include path of your project. - Add
PathToYourOgreSDK\boost_1_42
to the include path of your project. - Add
PathToYourOgreSDK\boost_1_42\lib
to your library path. - Add a new class to the
main.cpp
.class Example1 : public ExampleApplication { public: void createScene() { } };
- Add the following code at the top of your main function: ...
Get Ogre 3D 1.7 now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.