Loading...
Searching...
No Matches
Tutorial 8: SpecialFX

This tutorials describes how to do special effects. It shows how to use stencil buffer shadows, the particle system, billboards, dynamic light, and the water surface scene node.

We start like in some tutorials before. Please note that this time, the 'shadows' flag in createDevice() is set to true, for we want to have a dynamic shadow casted from an animated character. If this example runs too slow, set it to false. The Irrlicht Engine checks if your hardware doesn't support the stencil buffer, and disables shadows by itself, but just in case the demo runs slow on your hardware.

#include <irrlicht.h>
#include <iostream>
#include "driverChoice.h"
using namespace irr;
#ifdef _MSC_VER
#pragma comment(lib, "Irrlicht.lib")
#endif
int main()
{
// ask if user would like shadows
char i;
printf("Please press 'y' if you want to use realtime shadows.\n");
std::cin >> i;
const bool shadows = (i == 'y');
// ask user for driver
video::E_DRIVER_TYPE driverType=driverChoiceConsole();
if (driverType==video::EDT_COUNT)
return 1;
driverChoice.h
irrlicht.h
Main header file of the irrlicht, the only file needed to include.
irr::video::E_DRIVER_TYPE
E_DRIVER_TYPE
An enum for all types of drivers the Irrlicht Engine supports.
Definition EDriverTypes.h:15
irr::video::EDT_COUNT
@ EDT_COUNT
No driver, just for counting the elements.
Definition EDriverTypes.h:56
irr
Everything in the Irrlicht Engine can be found in this namespace.
Definition aabbox3d.h:13

Create device and exit if creation failed. We make the stencil flag optional to avoid slow screen modes for runs without shadows.

IrrlichtDevice *device =
createDevice(driverType, core::dimension2d<u32>(640, 480),
16, false, shadows);
if (device == 0)
return 1; // could not create selected driver.
video::IVideoDriver* driver = device->getVideoDriver();
scene::ISceneManager* smgr = device->getSceneManager();
irr::IrrlichtDevice
The Irrlicht device. You can create it with createDevice() or createDeviceEx().
Definition IrrlichtDevice.h:44
irr::IrrlichtDevice::getSceneManager
virtual scene::ISceneManager * getSceneManager()=0
Provides access to the scene manager.
irr::IrrlichtDevice::getVideoDriver
virtual video::IVideoDriver * getVideoDriver()=0
Provides access to the video driver for drawing 3d and 2d geometry.
irr::core::dimension2d
Specifies a 2 dimensional size.
Definition dimension2d.h:21
irr::scene::ISceneManager
The Scene Manager manages scene nodes, mesh recources, cameras and all the other stuff.
Definition ISceneManager.h:151
irr::video::IVideoDriver
Interface to driver which is able to perform 2d and 3d graphics functions.
Definition IVideoDriver.h:257
irr::createDevice
IRRLICHT_API IrrlichtDevice *IRRCALLCONV createDevice(video::E_DRIVER_TYPE deviceType=video::EDT_SOFTWARE, const core::dimension2d< u32 > &windowSize=(core::dimension2d< u32 >(640, 480)), u32 bits=16, bool fullscreen=false, bool stencilbuffer=false, bool vsync=false, IEventReceiver *receiver=0)
Creates an Irrlicht device. The Irrlicht device is the root object for using the engine.

For our environment, we load a .3ds file. It is a small room I modelled with Anim8or and exported into the 3ds format because the Irrlicht Engine does not support the .an8 format. I am a very bad 3d graphic artist, and so the texture mapping is not very nice in this model. Luckily I am a better programmer than artist, and so the Irrlicht Engine is able to create a cool texture mapping for me: Just use the mesh manipulator and create a planar texture mapping for the mesh. If you want to see the mapping I made with Anim8or, uncomment this line. I also did not figure out how to set the material right in Anim8or, it has a specular light color which I don't really like. I'll switch it off too with this code.

scene::IAnimatedMesh* mesh = smgr->getMesh("../../media/room.3ds");
smgr->getMeshManipulator()->makePlanarTextureMapping(mesh->getMesh(0), 0.004f);
scene::ISceneNode* node = 0;
node = smgr->addAnimatedMeshSceneNode(mesh);
node->setMaterialTexture(0, driver->getTexture("../../media/wall.jpg"));
node->getMaterial(0).SpecularColor.set(0,0,0,0);
irr::scene::IAnimatedMesh
Interface for an animated mesh.
Definition IAnimatedMesh.h:63
irr::scene::IAnimatedMesh::getMesh
virtual IMesh * getMesh(s32 frame, s32 detailLevel=255, s32 startFrameLoop=-1, s32 endFrameLoop=-1)=0
Returns the IMesh interface for a frame.
irr::scene::IMeshManipulator::makePlanarTextureMapping
virtual void makePlanarTextureMapping(IMesh *mesh, f32 resolution=0.001f) const =0
Creates a planar texture mapping on the mesh.
irr::scene::ISceneManager::getMesh
virtual IAnimatedMesh * getMesh(const io::path &filename)=0
Get pointer to an animateable mesh. Loads the file if not loaded already.
irr::scene::ISceneManager::addAnimatedMeshSceneNode
virtual IAnimatedMeshSceneNode * addAnimatedMeshSceneNode(IAnimatedMesh *mesh, ISceneNode *parent=0, s32 id=-1, const core::vector3df &position=core::vector3df(0, 0, 0), const core::vector3df &rotation=core::vector3df(0, 0, 0), const core::vector3df &scale=core::vector3df(1.0f, 1.0f, 1.0f), bool alsoAddIfMeshPointerZero=false)=0
Adds a scene node for rendering an animated mesh model.
irr::scene::ISceneManager::getMeshManipulator
virtual IMeshManipulator * getMeshManipulator()=0
Get pointer to the mesh manipulator.
irr::scene::ISceneNode
Scene node interface.
Definition ISceneNode.h:41
irr::scene::ISceneNode::setMaterialTexture
void setMaterialTexture(u32 textureLayer, video::ITexture *texture)
Sets the texture of the specified layer in all materials of this scene node to the new texture.
Definition ISceneNode.h:436
irr::scene::ISceneNode::getMaterial
virtual video::SMaterial & getMaterial(u32 num)
Returns the material based on the zero based index i.
Definition ISceneNode.h:406
irr::video::IVideoDriver::getTexture
virtual ITexture * getTexture(const io::path &filename)=0
Get access to a named texture.
irr::video::SColor::set
void set(u32 a, u32 r, u32 g, u32 b)
Sets all four components of the color at once.
Definition SColor.h:307
irr::video::SMaterial::SpecularColor
SColor SpecularColor
How much specular light (highlights from a light) is reflected.
Definition SMaterial.h:318

Now, for the first special effect: Animated water. It works like this: The WaterSurfaceSceneNode takes a mesh as input and makes it wave like a water surface. And if we let this scene node use a nice material like the EMT_REFLECTION_2_LAYER, it looks really cool. We are doing this with the next few lines of code. As input mesh, we create a hill plane mesh, without hills. But any other mesh could be used for this, you could even use the room.3ds (which would look really strange) if you want to.

mesh = smgr->addHillPlaneMesh( "myHill",
core::dimension2d<f32>(20,20),
core::dimension2d<u32>(40,40), 0, 0,
core::dimension2d<f32>(0,0),
core::dimension2d<f32>(10,10));
node = smgr->addWaterSurfaceSceneNode(mesh->getMesh(0), 3.0f, 300.0f, 30.0f);
node->setPosition(core::vector3df(0,7,0));
node->setMaterialTexture(0, driver->getTexture("../../media/stones.jpg"));
node->setMaterialTexture(1, driver->getTexture("../../media/water.jpg"));
node->setMaterialType(video::EMT_REFLECTION_2_LAYER);
irr::scene::ISceneManager::addWaterSurfaceSceneNode
virtual ISceneNode * addWaterSurfaceSceneNode(IMesh *mesh, f32 waveHeight=2.0f, f32 waveSpeed=300.0f, f32 waveLength=10.0f, ISceneNode *parent=0, s32 id=-1, const core::vector3df &position=core::vector3df(0, 0, 0), const core::vector3df &rotation=core::vector3df(0, 0, 0), const core::vector3df &scale=core::vector3df(1.0f, 1.0f, 1.0f))=0
Adds a scene node for rendering a animated water surface mesh.
irr::scene::ISceneManager::addHillPlaneMesh
virtual IAnimatedMesh * addHillPlaneMesh(const io::path &name, const core::dimension2d< f32 > &tileSize, const core::dimension2d< u32 > &tileCount, video::SMaterial *material=0, f32 hillHeight=0.0f, const core::dimension2d< f32 > &countHills=core::dimension2d< f32 >(0.0f, 0.0f), const core::dimension2d< f32 > &textureRepeatCount=core::dimension2d< f32 >(1.0f, 1.0f))=0
Adds a Hill Plane mesh to the mesh pool.
irr::scene::ISceneNode::setPosition
virtual void setPosition(const core::vector3df &newpos)
Sets the position of the node relative to its parent.
Definition ISceneNode.h:507
irr::scene::ISceneNode::setMaterialType
void setMaterialType(video::E_MATERIAL_TYPE newType)
Sets the material type of all materials in this scene node to a new material type.
Definition ISceneNode.h:448
irr::core::vector3df
vector3d< f32 > vector3df
Typedef for a f32 3d vector.
Definition vector3d.h:445
irr::video::EMT_REFLECTION_2_LAYER
@ EMT_REFLECTION_2_LAYER
A reflecting material with an optional non reflecting texture layer.
Definition EMaterialTypes.h:77

The second special effect is very basic, I bet you saw it already in some Irrlicht Engine demos: A transparent billboard combined with a dynamic light. We simply create a light scene node, let it fly around, and to make it look more cool, we attach a billboard scene node to it.

// create light
node = smgr->addLightSceneNode(0, core::vector3df(0,0,0),
video::SColorf(1.0f, 0.6f, 0.7f, 1.0f), 800.0f);
scene::ISceneNodeAnimator* anim = 0;
anim = smgr->createFlyCircleAnimator (core::vector3df(0,150,0),250.0f);
node->addAnimator(anim);
anim->drop();
// attach billboard to light
node = smgr->addBillboardSceneNode(node, core::dimension2d<f32>(50, 50));
node->setMaterialFlag(video::EMF_LIGHTING, false);
node->setMaterialType(video::EMT_TRANSPARENT_ADD_COLOR);
node->setMaterialTexture(0, driver->getTexture("../../media/particlewhite.bmp"));
irr::IReferenceCounted::drop
bool drop() const
Drops the object. Decrements the reference counter by one.
Definition IReferenceCounted.h:116
irr::scene::ISceneManager::addBillboardSceneNode
virtual IBillboardSceneNode * addBillboardSceneNode(ISceneNode *parent=0, const core::dimension2d< f32 > &size=core::dimension2d< f32 >(10.0f, 10.0f), const core::vector3df &position=core::vector3df(0, 0, 0), s32 id=-1, video::SColor colorTop=0xFFFFFFFF, video::SColor colorBottom=0xFFFFFFFF)=0
Adds a billboard scene node to the scene graph.
irr::scene::ISceneManager::addLightSceneNode
virtual ILightSceneNode * addLightSceneNode(ISceneNode *parent=0, const core::vector3df &position=core::vector3df(0, 0, 0), video::SColorf color=video::SColorf(1.0f, 1.0f, 1.0f), f32 radius=100.0f, s32 id=-1)=0
Adds a dynamic light scene node to the scene graph.
irr::scene::ISceneManager::createFlyCircleAnimator
virtual ISceneNodeAnimator * createFlyCircleAnimator(const core::vector3df &center=core::vector3df(0.f, 0.f, 0.f), f32 radius=100.f, f32 speed=0.001f, const core::vector3df &direction=core::vector3df(0.f, 1.f, 0.f), f32 startPosition=0.f, f32 radiusEllipsoid=0.f)=0
Creates a fly circle animator, which lets the attached scene node fly around a center.
irr::scene::ISceneNodeAnimator
Animates a scene node. Can animate position, rotation, material, and so on.
Definition ISceneNodeAnimator.h:31
irr::scene::ISceneNode::addAnimator
virtual void addAnimator(ISceneNodeAnimator *animator)
Adds an animator which should animate this node.
Definition ISceneNode.h:348
irr::scene::ISceneNode::setMaterialFlag
void setMaterialFlag(video::E_MATERIAL_FLAG flag, bool newvalue)
Sets all material flags at once to a new value.
Definition ISceneNode.h:425
irr::video::SColorf
Class representing a color with four floats.
Definition SColor.h:459
irr::video::EMF_LIGHTING
@ EMF_LIGHTING
Will this material be lighted? Default: true.
Definition EMaterialFlags.h:26
irr::video::EMT_TRANSPARENT_ADD_COLOR
@ EMT_TRANSPARENT_ADD_COLOR
A transparent material.
Definition EMaterialTypes.h:88

The next special effect is a lot more interesting: A particle system. The particle system in the Irrlicht Engine is quite modular and extensible, but yet easy to use. There is a particle system scene node into which you can put a particle emitter, which makes particles come out of nothing. These emitters are quite flexible and usually have lots of parameters like direction, amount, and color of the particles they create.

There are different emitters, for example a point emitter which lets particles pop out at a fixed point. If the particle emitters available in the engine are not enough for you, you can easily create your own ones, you'll simply have to create a class derived from the IParticleEmitter interface and attach it to the particle system using setEmitter(). In this example we create a box particle emitter, which creates particles randomly inside a box. The parameters define the box, direction of the particles, minimal and maximal new particles per second, color, and minimal and maximal lifetime of the particles.

Because only with emitters particle system would be a little bit boring, there are particle affectors which modify particles while they fly around. Affectors can be added to a particle system for simulating additional effects like gravity or wind. The particle affector we use in this example is an affector which modifies the color of the particles: It lets them fade out. Like the particle emitters, additional particle affectors can also be implemented by you, simply derive a class from IParticleAffector and add it with addAffector().

After we set a nice material to the particle system, we have a cool looking camp fire. By adjusting material, texture, particle emitter, and affector parameters, it is also easily possible to create smoke, rain, explosions, snow, and so on.

// create a particle system
scene::IParticleSystemSceneNode* ps =
smgr->addParticleSystemSceneNode(false);
scene::IParticleEmitter* em = ps->createBoxEmitter(
core::aabbox3d<f32>(-7,0,-7,7,1,7), // emitter size
core::vector3df(0.0f,0.06f,0.0f), // initial direction
80,100, // emit rate
video::SColor(0,255,255,255), // darkest color
video::SColor(0,255,255,255), // brightest color
800,2000,0, // min and max age, angle
core::dimension2df(10.f,10.f), // min size
core::dimension2df(20.f,20.f)); // max size
ps->setEmitter(em); // this grabs the emitter
em->drop(); // so we can drop it here without deleting it
scene::IParticleAffector* paf = ps->createFadeOutParticleAffector();
ps->addAffector(paf); // same goes for the affector
paf->drop();
ps->setPosition(core::vector3df(-70,60,40));
ps->setScale(core::vector3df(2,2,2));
ps->setMaterialFlag(video::EMF_LIGHTING, false);
ps->setMaterialFlag(video::EMF_ZWRITE_ENABLE, false);
ps->setMaterialTexture(0, driver->getTexture("../../media/fire.bmp"));
ps->setMaterialType(video::EMT_TRANSPARENT_ADD_COLOR);
irr::core::aabbox3d
Axis aligned bounding box in 3d dimensional space.
Definition aabbox3d.h:22
irr::scene::IParticleAffector
A particle affector modifies particles.
Definition IParticleAffector.h:42
irr::scene::IParticleEmitter
A particle emitter for using with particle systems.
Definition IParticleEmitter.h:46
irr::scene::IParticleSystemSceneNode
A particle system scene node for creating snow, fire, exlosions, smoke...
Definition IParticleSystemSceneNode.h:47
irr::scene::IParticleSystemSceneNode::createFadeOutParticleAffector
virtual IParticleFadeOutAffector * createFadeOutParticleAffector(const video::SColor &targetColor=video::SColor(0, 0, 0, 0), u32 timeNeededToFadeOut=1000)=0
Creates a fade out particle affector.
irr::scene::IParticleSystemSceneNode::addAffector
virtual void addAffector(IParticleAffector *affector)=0
Adds new particle effector to the particle system.
irr::scene::IParticleSystemSceneNode::createBoxEmitter
virtual IParticleBoxEmitter * createBoxEmitter(const core::aabbox3df &box=core::aabbox3df(-10, 28,-10, 10, 30, 10), const core::vector3df &direction=core::vector3df(0.0f, 0.03f, 0.0f), u32 minParticlesPerSecond=5, u32 maxParticlesPerSecond=10, const video::SColor &minStartColor=video::SColor(255, 0, 0, 0), const video::SColor &maxStartColor=video::SColor(255, 255, 255, 255), u32 lifeTimeMin=2000, u32 lifeTimeMax=4000, s32 maxAngleDegrees=0, const core::dimension2df &minStartSize=core::dimension2df(5.0f, 5.0f), const core::dimension2df &maxStartSize=core::dimension2df(5.0f, 5.0f))=0
Creates a box particle emitter.
irr::scene::IParticleSystemSceneNode::setEmitter
virtual void setEmitter(IParticleEmitter *emitter)=0
Sets the particle emitter, which creates the particles.
irr::scene::ISceneManager::addParticleSystemSceneNode
virtual IParticleSystemSceneNode * addParticleSystemSceneNode(bool withDefaultEmitter=true, ISceneNode *parent=0, s32 id=-1, const core::vector3df &position=core::vector3df(0, 0, 0), const core::vector3df &rotation=core::vector3df(0, 0, 0), const core::vector3df &scale=core::vector3df(1.0f, 1.0f, 1.0f))=0
Adds a particle system scene node to the scene graph.
irr::scene::ISceneNode::setScale
virtual void setScale(const core::vector3df &scale)
Sets the relative scale of the scene node.
Definition ISceneNode.h:468
irr::video::SColor
Class representing a 32 bit ARGB color.
Definition SColor.h:202
irr::core::dimension2df
dimension2d< f32 > dimension2df
Typedef for an f32 dimension.
Definition dimension2d.h:210
irr::video::EMF_ZWRITE_ENABLE
@ EMF_ZWRITE_ENABLE
May be written to the zbuffer or is it readonly. Default: true.
Definition EMaterialFlags.h:33

Next we add a volumetric light node, which adds a glowing fake area light to the scene. Like with the billboards and particle systems we also assign a texture for the desired effect, though this time we'll use a texture animator to create the illusion of a magical glowing area effect.

scene::IVolumeLightSceneNode * n = smgr->addVolumeLightSceneNode(0, -1,
32, // Subdivisions on U axis
32, // Subdivisions on V axis
video::SColor(0, 255, 255, 255), // foot color
video::SColor(0, 0, 0, 0)); // tail color
if (n)
{
n->setScale(core::vector3df(56.0f, 56.0f, 56.0f));
n->setPosition(core::vector3df(-120,50,40));
// load textures for animation
core::array<video::ITexture*> textures;
for (s32 g=7; g > 0; --g)
{
core::stringc tmp;
tmp = "../../media/portal";
tmp += g;
tmp += ".bmp";
video::ITexture* t = driver->getTexture( tmp.c_str() );
textures.push_back(t);
}
// create texture animator
scene::ISceneNodeAnimator* glow = smgr->createTextureAnimator(textures, 150);
// add the animator
n->addAnimator(glow);
// drop the animator because it was created with a create() function
glow->drop();
}
irr::core::array
Self reallocating template array (like stl vector) with additional features.
Definition irrArray.h:23
irr::core::array::push_back
void push_back(const T &element)
Adds an element at back of array.
Definition irrArray.h:112
irr::core::string::c_str
const T * c_str() const
Returns character string.
Definition irrString.h:495
irr::scene::ISceneManager::createTextureAnimator
virtual ISceneNodeAnimator * createTextureAnimator(const core::array< video::ITexture * > &textures, s32 timePerFrame, bool loop=true)=0
Creates a texture animator, which switches the textures of the target scene node based on a list of t...
irr::scene::ISceneManager::addVolumeLightSceneNode
virtual IVolumeLightSceneNode * addVolumeLightSceneNode(ISceneNode *parent=0, s32 id=-1, const u32 subdivU=32, const u32 subdivV=32, const video::SColor foot=video::SColor(51, 0, 230, 180), const video::SColor tail=video::SColor(0, 0, 0, 0), const core::vector3df &position=core::vector3df(0, 0, 0), const core::vector3df &rotation=core::vector3df(0, 0, 0), const core::vector3df &scale=core::vector3df(1.0f, 1.0f, 1.0f))=0
adds Volume Lighting Scene Node.
irr::scene::IVolumeLightSceneNode
Definition IVolumeLightSceneNode.h:19
irr::video::ITexture
Interface of a Video Driver dependent Texture.
Definition ITexture.h:99
irr::core::stringc
string< c8 > stringc
Typedef for character strings.
Definition irrString.h:1358
irr::s32
signed int s32
32 bit signed variable.
Definition irrTypes.h:66

As our last special effect, we want a dynamic shadow be casted from an animated character. For this we load a DirectX .x model and place it into our world. For creating the shadow, we simply need to call addShadowVolumeSceneNode(). The color of shadows is only adjustable globally for all shadows, by calling ISceneManager::setShadowColor(). Voila, here is our dynamic shadow.

Because the character is a little bit too small for this scene, we make it bigger using setScale(). And because the character is lighted by a dynamic light, we need to normalize the normals to make the lighting on it correct. This is always necessary if the scale of a dynamic lighted model is not (1,1,1). Otherwise it would get too dark or too bright because the normals will be scaled too.

// add animated character
mesh = smgr->getMesh("../../media/dwarf.x");
scene::IAnimatedMeshSceneNode* anode = 0;
anode = smgr->addAnimatedMeshSceneNode(mesh);
anode->setPosition(core::vector3df(-50,20,-60));
anode->setAnimationSpeed(15);
// add shadow
anode->addShadowVolumeSceneNode();
smgr->setShadowColor(video::SColor(150,0,0,0));
// make the model a little bit bigger and normalize its normals
// because of the scaling, for correct lighting
anode->setScale(core::vector3df(2,2,2));
anode->setMaterialFlag(video::EMF_NORMALIZE_NORMALS, true);
irr::scene::IAnimatedMeshSceneNode
Scene node capable of displaying an animated mesh and its shadow.
Definition IAnimatedMeshSceneNode.h:54
irr::scene::IAnimatedMeshSceneNode::addShadowVolumeSceneNode
virtual IShadowVolumeSceneNode * addShadowVolumeSceneNode(const IMesh *shadowMesh=0, s32 id=-1, bool zfailmethod=true, f32 infinity=1000.0f)=0
Creates shadow volume scene node as child of this node.
irr::scene::IAnimatedMeshSceneNode::setAnimationSpeed
virtual void setAnimationSpeed(f32 framesPerSecond)=0
Sets the speed with which the animation is played.
irr::scene::ISceneManager::setShadowColor
virtual void setShadowColor(video::SColor color=video::SColor(150, 0, 0, 0))=0
Sets the color of stencil buffers shadows drawn by the scene manager.
irr::video::EMF_NORMALIZE_NORMALS
@ EMF_NORMALIZE_NORMALS
Normalizes normals. Default: false.
Definition EMaterialFlags.h:66

Finally we simply have to draw everything, that's all.

scene::ICameraSceneNode* camera = smgr->addCameraSceneNodeFPS();
camera->setPosition(core::vector3df(-50,50,-150));
camera->setFarValue(10000.0f); // this increase a shadow visible range.
// disable mouse cursor
device->getCursorControl()->setVisible(false);
s32 lastFPS = -1;
while(device->run())
if (device->isWindowActive())
{
driver->beginScene(true, true, 0);
smgr->drawAll();
driver->endScene();
const s32 fps = driver->getFPS();
if (lastFPS != fps)
{
core::stringw str = L"Irrlicht Engine - SpecialFX example [";
str += driver->getName();
str += "] FPS:";
str += fps;
device->setWindowCaption(str.c_str());
lastFPS = fps;
}
}
device->drop();
return 0;
}
irr::IrrlichtDevice::run
virtual bool run()=0
Runs the device.
irr::IrrlichtDevice::setWindowCaption
virtual void setWindowCaption(const wchar_t *text)=0
Sets the caption of the window.
irr::IrrlichtDevice::getCursorControl
virtual gui::ICursorControl * getCursorControl()=0
Provides access to the cursor control.
irr::IrrlichtDevice::isWindowActive
virtual bool isWindowActive() const =0
Returns if the window is active.
irr::gui::ICursorControl::setVisible
virtual void setVisible(bool visible)=0
Changes the visible state of the mouse cursor.
irr::scene::ICameraSceneNode
Scene Node which is a (controlable) camera.
Definition ICameraSceneNode.h:24
irr::scene::ICameraSceneNode::setFarValue
virtual void setFarValue(f32 zf)=0
Sets the value of the far clipping plane (default: 2000.0f).
irr::scene::ISceneManager::drawAll
virtual void drawAll()=0
Draws all the scene nodes.
irr::scene::ISceneManager::addCameraSceneNodeFPS
virtual ICameraSceneNode * addCameraSceneNodeFPS(ISceneNode *parent=0, f32 rotateSpeed=100.0f, f32 moveSpeed=0.5f, s32 id=-1, SKeyMap *keyMapArray=0, s32 keyMapSize=0, bool noVerticalMovement=false, f32 jumpSpeed=0.f, bool invertMouse=false, bool makeActive=true)=0
Adds a camera scene node with an animator which provides mouse and keyboard control appropriate for f...
irr::video::IVideoDriver::beginScene
virtual bool beginScene(bool backBuffer=true, bool zBuffer=true, SColor color=SColor(255, 0, 0, 0), const SExposedVideoData &videoData=SExposedVideoData(), core::rect< s32 > *sourceRect=0)=0
Applications must call this method before performing any rendering.
irr::video::IVideoDriver::getFPS
virtual s32 getFPS() const =0
Returns current frames per second value.
irr::video::IVideoDriver::getName
virtual const wchar_t * getName() const =0
Gets name of this video driver.
irr::video::IVideoDriver::endScene
virtual bool endScene()=0
Presents the rendered image to the screen.
irr::core::stringw
string< wchar_t > stringw
Typedef for wide character strings.
Definition irrString.h:1361
- Irrlicht Engine Documentation © 2003-2012 by Nikolaus Gebhardt. Generated on for Irrlicht 3D Engine by Doxygen 1.15.0