Thursday, September 18, 2014

Irrlicht setup

Trying to use Irrlicht with C++ on Windows and MacOS.

1. Setting up on Eclipse (Windows) is pretty straight forward. Just follow the tutorial and it can be compiled.

2. Setting up on XCode 5.x (MacOS) had some trouble. Finally, found a solution on the forum:

Anyway to start:
  1. Create a new empty project.
  2. Add a target. (You can do this by left clicking the project file in the tree menu on the left, then look for a circle with a plus at the bottom of the window)
      Select Max OS X > Application > Cocoa Application
  3. Now delete the *AppDelegate.m, *AppDelegate.h and *.xib file, you wont need these.
  4. Now create a new file
      I usually select Mac OS X > C and C++ > C++ File. I also usually fill it with the Example 1 tutorial to get the app compiling with some output to start.
  5. Now click on the project in the left tree menu again
  6. In the central part of the screen, click "Build Settings", and change the following settings:
    1. Base SDK: Standard (32/64 bit intel)
    2. Base SDK: Latest Mac OS X
    3. Compiler for C/C++/Objective-C: LLVM GCC 4.2
    4. Header Search Paths: /Path/To/Your/Irrlicht/Folder/include
  7. Now select "Build Phases"
    1. Under "Link Binary With Libraries, click the plus and add Cocoa, Carbon, IOKit, OpenGL, and the libIrrlicht.a file.
    2. under "Compile Sources", select the 'main.m' and then delete the main.m file
  8. Compile!

* Somehow on 1st tutorial, using createDevice(video::EDT_OPENGL is much more faster than using EDT_SOFTWARE.

http://irrlicht.sourceforge.net/forum/viewtopic.php?f=5&t=13890&hilit=xcode&start=60
http://irrlicht3d.org/wiki/index.php?n=Main.InstallingIrrlicht#BuildMacOSX
http://irrlicht3d.org/wiki/index.php?n=Main.Macintosh

No comments:

Post a Comment

Real Time Web Analytics