Wellcome to MyWorld engine
MyWorld is an open virtual reality and game engine. It is written and usable in C/C++. It has own abstract layers
for Graphics and Physics. Actually we use Irrlicht for
3D-Rendering and GUI, and ODE for Physics. It is absolutely free even for commercial products.
How to get start with MyWorld read in: Getting started with MyWorld
|

|
|
Home
|
|
Using Irrlicht with Eclipse |
|
|
|
|
Written by Administrator
|
|
Tuesday, 22 November 2005 |
Using Irrlicht with Eclipse
Here I will describe how to use Irrlicht with Eclipse in Linux. The
tutorial how to do that in Windows comming soon. It was pretty simple
to compile a hello world for eclipse windows using cygwin, but I had problems doing
that for Irrlicht, I gues because my cygwin is several years old. I'll
update my cygwin and write this new tutorial in next time.
1. Install and set up eclipse to work with C/C++
Thats very simply:
- Download the last stable version of eclipse http://www.eclipse.org/downloads/index.php (like that: eclipse-SDK-x.x.x-linux-gtk) and the
plugin for C/C++ CDT (the same site, e.g. org.eclipse.cdt-x.x.x-linux.x86).
- Unpack eclipse and copy eclipse
directory to directory of your choice e.g.: home/eugen/bin. Now you unpack CDT and copy its eclipse directory also to home/eugen/bin and just
overwrite everything in it - it is the common way to install
plugins for eclipse.
- Set a shortcut to /home/eugen/bin/eclipse/eclipse
on where you want
(desktop, taskbar, menu). It must be now possible to start eclipse.
The same way you can install eclipse and CDT for windows (you just need
to download the archives for win32 instead linux *lol*). Also to use
C/C++, as mentioned above, you need a builder (make), a compiler
(gcc/g++ http://gcc.gnu.org) and a
debugger (e.g.: gdb). All that things has Linux on default, for Windows
you could either install all them separatly or just install cygwin,
which has all this tools and much more (cygwin is realy very useful, it
provides almost the whole functionality of common bash terminal, with
most of the tools/commands and manuals. May be I write a tutorial about
it later ;-)). I am not sure if one could use another compiler but
gcc/g++ - I think it must be possible too, but it actually does not
apropriate the goals of my own project.
If you still had problems to install it, please consult eclipse's
website, search in google for some tutorials or just ask me and then,
if you finaly managed it, report to me about how I could improve this
tutorial.
2. Converting an Irrlicht example to Eclipse
The simplest and fastest way to get Irrlicht work with eclipse is to
use a ready example.
- Start eclipse
- Go to menu: File > New...
> Project... A
"New Project"-Dialog must appear now:
- choose C++ > Standard Make
C++ Project. And release [Next >] button
- type in for Project name: irr_eclipse,
- uncheck the Use default checkbox and
- select the Directory for our project
(e.g. Irrlicht example 2 - where ever it is) by using [Browse...]
button: e.g. /home/eugen/work/cpp/irrlicht-0.12.0/examples/02.Quake3Map
(or like that)
- now click [Finish].
- "Open Assotiated Perspective" dialog appears, click [Yes].
- Go to "C/C++Projects" Panel (on the left). You should see irr_eclipse project now. Go in it
and choose main.cpp. If
nothing is understriked red in editor view, it is a good sign ;-)
- Eclipse builds automaticly, if not, then choose menu Project
> Build All
- There are several ways to start application, one of them is (use
it by first start, because it creates a kind of run profile or like
that):
- Go to "C/C++Projects" Panel
(on the left) > irr_eclipse > Binaries > example
- right click on example,
go to Run as > Run Local C/C++
Application
- In dialog choose: GDB
Debugger (!!! Not
double click !!! but [OK])
- By next time it must be possible to use green run symbol on the
toolbar
Possible problems:
No output at console:
Go to console panel (on bottom) and close
it! Try now to start your application. Sometimes it helps to
press it (green run symbol) twice or three times *lol*
Sometime it helps to do following:
Menu > Run > Run... uncheck connect process input & output to
a terminal, Run
Now do the same but check it *lol*
These and other awkward solutions were found heuristic by
experimenting, so don't wonder ;-) I think all together we could find
more elegant ways. And may be it is a bug, then probably it will be
fixed soon. So don't giv up and help me to improve this tutorial!
This Tutorial was created by Eugen Lofing (C) 2005
|
|
Last Updated ( Tuesday, 22 November 2005 )
|
|