I'm using:
WinXP sp2, DevC++ v.4, and Irrlicht v.0.8
In the compiler and linker output window, I get:
Code: Select all
In file included from C:\IRRLIC~1.8\include\irrlicht.h:32,
from c:\docume~1\owner\irrlicht\tutori~1\hellow~1.cpp:1:
C:\IRRLIC~1.8\include\aabbox3d.h: In method `void irr::core::aabbox3d<T>::getEdges(irr::core::vector3d<T> *) const':
C:\IRRLIC~1.8\include\aabbox3d.h:217: unknown escape sequence `\I'
C:\IRRLIC~1.8\include\aabbox3d.h:217: unknown escape sequence `\i'
Code: Select all
Line Unit Message
32 c:\irrlic~1.8\include\irrlicht.h from c:\docume~1\owner\irrlicht\tutori~1\hellow~1.cpp:1:
217 c:\irrlic~1.8\include\aabbox3d.h unknown escape sequence `\I'
217 c:\irrlic~1.8\include\aabbox3d.h unknown escape sequence `\i'
I put both in, because I know earlier versions of devc++ didn't have the compiler and linker output window[/code]
And now, my code:
Code: Select all
#include <irrlicht.h>
using namespace irr;
using namespace core;
using namespace scene;
using namespace video;
using namespace io;
using namespace gui;
#pragma comment(lib, "Irrlicht.lib")
int main()
{
IrrlichtDevice *device =
createDevice(EDT_SOFTWARE, dimension2d<s32>(512, 384), 16,
false, false, false, 0);
device->setWindowCaption(L"Hello World! - Irrlicht Engine Demo");
IVideoDriver* driver = device->getVideoDriver();
ISceneManager* smgr = device->getSceneManager();
IGUIEnvironment* guienv = device->getGUIEnvironment();
guienv->addStaticText(L"Hello World! This is the Irrlicht Software engine!",
rect<int>(10,10,200,22), true);
IAnimatedMesh* mesh = smgr->getMesh("../../media/sydney.md2");
IAnimatedMeshSceneNode* node = smgr->addAnimatedMeshSceneNode( mesh );
if (node)
{
node->setMaterialFlag(EMF_LIGHTING, false);
node->setFrameLoop(0, 310);
node->setMaterialTexture( 0, driver->getTexture("../../media/sydney.bmp") );
}
smgr->addCameraSceneNode(0, vector3df(0,30,-40), vector3df(0,5,0));
while(device->run())
{
driver->beginScene(true, true, SColor(0,200,200,200));
smgr->drawAll();
guienv->drawAll();
driver->endScene();
}
device->drop();
return 0;
}