Irrlicht 3D Engine
irr::scene::ISceneManager Class Referenceabstract

The Scene Manager manages scene nodes, mesh resources, cameras and all the other stuff. More...

#include <ISceneManager.h>

+ Inheritance diagram for irr::scene::ISceneManager:

Public Member Functions

virtual IAnimatedMeshSceneNodeaddAnimatedMeshSceneNode (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. More...
 
virtual IAnimatedMeshaddArrowMesh (const io::path &name, video::SColor vtxColorCylinder=0xFFFFFFFF, video::SColor vtxColorCone=0xFFFFFFFF, u32 tesselationCylinder=4, u32 tesselationCone=8, f32 height=1.f, f32 cylinderHeight=0.6f, f32 widthCylinder=0.05f, f32 widthCone=0.3f)=0
 add a static arrow mesh to the meshpool More...
 
virtual IBillboardSceneNodeaddBillboardSceneNode (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. More...
 
virtual IBillboardTextSceneNodeaddBillboardTextSceneNode (gui::IGUIFont *font, const wchar_t *text, 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 text scene node, which uses billboards. The node, and the text on it, will scale with distance. More...
 
virtual ICameraSceneNodeaddCameraSceneNode (ISceneNode *parent=0, const core::vector3df &position=core::vector3df(0, 0, 0), const core::vector3df &lookat=core::vector3df(0, 0, 100), s32 id=-1, bool makeActive=true)=0
 Adds a camera scene node to the scene graph and sets it as active camera. More...
 
virtual ICameraSceneNodeaddCameraSceneNodeFPS (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 first person shooters (FPS). More...
 
virtual ICameraSceneNodeaddCameraSceneNodeMaya (ISceneNode *parent=0, f32 rotateSpeed=-1500.f, f32 zoomSpeed=200.f, f32 translationSpeed=1500.f, s32 id=-1, f32 distance=70.f, bool makeActive=true)=0
 Adds a maya style user controlled camera scene node to the scene graph. More...
 
virtual IMeshSceneNodeaddCubeSceneNode (f32 size=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 cube scene node. More...
 
virtual IDummyTransformationSceneNodeaddDummyTransformationSceneNode (ISceneNode *parent=0, s32 id=-1)=0
 Adds a dummy transformation scene node to the scene graph. More...
 
virtual ISceneNodeaddEmptySceneNode (ISceneNode *parent=0, s32 id=-1)=0
 Adds an empty scene node to the scene graph. More...
 
virtual void addExternalMeshLoader (IMeshLoader *externalLoader)=0
 Adds an external mesh loader for extending the engine with new file formats. More...
 
virtual void addExternalSceneLoader (ISceneLoader *externalLoader)=0
 Adds an external scene loader for extending the engine with new file formats. More...
 
virtual IAnimatedMeshaddHillPlaneMesh (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. More...
 
virtual ILightSceneNodeaddLightSceneNode (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. More...
 
virtual IMeshSceneNodeaddMeshSceneNode (IMesh *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 a static mesh. More...
 
virtual IOctreeSceneNodeaddOctreeSceneNode (IAnimatedMesh *mesh, ISceneNode *parent=0, s32 id=-1, s32 minimalPolysPerNode=512, bool alsoAddIfMeshPointerZero=false)=0
 Adds a scene node for rendering using a octree to the scene graph. More...
 
virtual IOctreeSceneNodeaddOctreeSceneNode (IMesh *mesh, ISceneNode *parent=0, s32 id=-1, s32 minimalPolysPerNode=256, bool alsoAddIfMeshPointerZero=false)=0
 Adds a scene node for rendering using a octree to the scene graph. More...
 
virtual IParticleSystemSceneNodeaddParticleSystemSceneNode (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. More...
 
virtual IMeshSceneNodeaddQuake3SceneNode (const IMeshBuffer *meshBuffer, const quake3::IShader *shader, ISceneNode *parent=0, s32 id=-1)=0
 Adds a quake3 scene node to the scene graph. More...
 
virtual ISceneNodeaddSceneNode (const char *sceneNodeTypeName, ISceneNode *parent=0)=0
 Adds a scene node to the scene by name. More...
 
virtual ISceneNodeaddSkyBoxSceneNode (video::ITexture *top, video::ITexture *bottom, video::ITexture *left, video::ITexture *right, video::ITexture *front, video::ITexture *back, ISceneNode *parent=0, s32 id=-1)=0
 Adds a skybox scene node to the scene graph. More...
 
virtual ISceneNodeaddSkyDomeSceneNode (video::ITexture *texture, u32 horiRes=16, u32 vertRes=8, f32 texturePercentage=0.9, f32 spherePercentage=2.0, f32 radius=1000.f, ISceneNode *parent=0, s32 id=-1)=0
 Adds a skydome scene node to the scene graph. More...
 
virtual IAnimatedMeshaddSphereMesh (const io::path &name, f32 radius=5.f, u32 polyCountX=16, u32 polyCountY=16)=0
 add a static sphere mesh to the meshpool More...
 
virtual IMeshSceneNodeaddSphereSceneNode (f32 radius=5.0f, s32 polyCount=16, 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 sphere scene node of the given radius and detail. More...
 
virtual IAnimatedMeshaddTerrainMesh (const io::path &meshname, video::IImage *texture, video::IImage *heightmap, const core::dimension2d< f32 > &stretchSize=core::dimension2d< f32 >(10.0f, 10.0f), f32 maxHeight=200.0f, const core::dimension2d< u32 > &defaultVertexBlockSize=core::dimension2d< u32 >(64, 64))=0
 Adds a static terrain mesh to the mesh pool. More...
 
virtual ITerrainSceneNodeaddTerrainSceneNode (const io::path &heightMapFileName, ISceneNode *parent=0, s32 id=-1, const core::vector3df &position=core::vector3df(0.0f, 0.0f, 0.0f), const core::vector3df &rotation=core::vector3df(0.0f, 0.0f, 0.0f), const core::vector3df &scale=core::vector3df(1.0f, 1.0f, 1.0f), video::SColor vertexColor=video::SColor(255, 255, 255, 255), s32 maxLOD=5, E_TERRAIN_PATCH_SIZE patchSize=ETPS_17, s32 smoothFactor=0, bool addAlsoIfHeightmapEmpty=false)=0
 Adds a terrain scene node to the scene graph. More...
 
virtual ITerrainSceneNodeaddTerrainSceneNode (io::IReadFile *heightMapFile, ISceneNode *parent=0, s32 id=-1, const core::vector3df &position=core::vector3df(0.0f, 0.0f, 0.0f), const core::vector3df &rotation=core::vector3df(0.0f, 0.0f, 0.0f), const core::vector3df &scale=core::vector3df(1.0f, 1.0f, 1.0f), video::SColor vertexColor=video::SColor(255, 255, 255, 255), s32 maxLOD=5, E_TERRAIN_PATCH_SIZE patchSize=ETPS_17, s32 smoothFactor=0, bool addAlsoIfHeightmapEmpty=false)=0
 Adds a terrain scene node to the scene graph. More...
 
virtual ITextSceneNodeaddTextSceneNode (gui::IGUIFont *font, const wchar_t *text, video::SColor color=video::SColor(100, 255, 255, 255), ISceneNode *parent=0, const core::vector3df &position=core::vector3df(0, 0, 0), s32 id=-1)=0
 Adds a text scene node, which is able to display 2d text at a position in three dimensional space. More...
 
virtual void addToDeletionQueue (ISceneNode *node)=0
 Adds a scene node to the deletion queue. More...
 
virtual IAnimatedMeshaddVolumeLightMesh (const io::path &name, const u32 SubdivideU=32, const u32 SubdivideV=32, const video::SColor FootColor=video::SColor(51, 0, 230, 180), const video::SColor TailColor=video::SColor(0, 0, 0, 0))=0
 Add a volume light mesh to the meshpool. More...
 
virtual IVolumeLightSceneNodeaddVolumeLightSceneNode (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. More...
 
virtual ISceneNodeaddWaterSurfaceSceneNode (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. More...
 
virtual void clear ()=0
 Clears the whole scene. More...
 
virtual void clearAllRegisteredNodesForRendering ()=0
 Clear all nodes which are currently registered for rendering. More...
 
virtual ISceneNodeAnimatorCollisionResponsecreateCollisionResponseAnimator (ITriangleSelector *world, ISceneNode *sceneNode, const core::vector3df &ellipsoidRadius=core::vector3df(30, 60, 30), const core::vector3df &gravityPerSecond=core::vector3df(0,-10.0f, 0), const core::vector3df &ellipsoidTranslation=core::vector3df(0, 0, 0), f32 slidingValue=0.0005f)=0
 Creates a special scene node animator for doing automatic collision detection and response. More...
 
virtual ISceneNodeAnimatorcreateDeleteAnimator (u32 timeMs)=0
 Creates a scene node animator, which deletes the scene node after some time automatically. More...
 
virtual ISceneNodeAnimatorcreateFlyCircleAnimator (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. More...
 
virtual ISceneNodeAnimatorcreateFlyStraightAnimator (const core::vector3df &startPoint, const core::vector3df &endPoint, u32 timeForWay, bool loop=false, bool pingpong=false)=0
 Creates a fly straight animator, which lets the attached scene node fly or move along a line between two points. More...
 
virtual ISceneNodeAnimatorcreateFollowSplineAnimator (s32 startTime, const core::array< core::vector3df > &points, f32 speed=1.0f, f32 tightness=0.5f, bool loop=true, bool pingpong=false)=0
 Creates a follow spline animator. More...
 
virtual IMeshWritercreateMeshWriter (EMESH_WRITER_TYPE type)=0
 Get a mesh writer implementation if available. More...
 
virtual IMetaTriangleSelectorcreateMetaTriangleSelector ()=0
 Creates a meta triangle selector. More...
 
virtual ISceneManagercreateNewSceneManager (bool cloneContent=false)=0
 Creates a new scene manager. More...
 
virtual ITriangleSelectorcreateOctreeTriangleSelector (IMesh *mesh, ISceneNode *node, s32 minimalPolysPerNode=32)=0
 Creates a Triangle Selector, optimized by an octree. More...
 
virtual ITriangleSelectorcreateOctreeTriangleSelector (IMeshBuffer *meshBuffer, irr::u32 materialIndex, ISceneNode *node, s32 minimalPolysPerNode=32)=0
 Creates a Triangle Selector for a single meshbuffer, optimized by an octree. More...
 
_IRR_DEPRECATED_ ITriangleSelectorcreateOctTreeTriangleSelector (IMesh *mesh, ISceneNode *node, s32 minimalPolysPerNode=32)
 //! Creates a Triangle Selector, optimized by an octree. More...
 
virtual ISceneNodeAnimatorcreateRotationAnimator (const core::vector3df &rotationSpeed)=0
 Creates a rotation animator, which rotates the attached scene node around itself. More...
 
virtual ISceneNodeAnimatorcreateSceneNodeAnimator (const char *typeName, ISceneNode *target=0)=0
 creates a scene node animator based on its type name More...
 
virtual ISkinnedMeshcreateSkinnedMesh ()=0
 Get a skinned mesh, which is not available as header-only code. More...
 
virtual ITriangleSelectorcreateTerrainTriangleSelector (ITerrainSceneNode *node, s32 LOD=0)=0
 Creates a triangle selector which can select triangles from a terrain scene node. More...
 
virtual ISceneNodeAnimatorcreateTextureAnimator (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 textures. More...
 
virtual ITriangleSelectorcreateTriangleSelector (IMesh *mesh, ISceneNode *node, bool separateMeshbuffers=false)=0
 Creates a simple ITriangleSelector, based on a mesh. More...
 
virtual ITriangleSelectorcreateTriangleSelector (const IMeshBuffer *meshBuffer, irr::u32 materialIndex, ISceneNode *node)=0
 Creates a simple ITriangleSelector, based on a meshbuffer. More...
 
virtual ITriangleSelectorcreateTriangleSelector (IAnimatedMeshSceneNode *node, bool separateMeshbuffers=false)=0
 Creates a simple ITriangleSelector, based on an animated mesh scene node. More...
 
virtual ITriangleSelectorcreateTriangleSelectorFromBoundingBox (ISceneNode *node)=0
 Creates a simple dynamic ITriangleSelector, based on a axis aligned bounding box. More...
 
virtual void drawAll ()=0
 Draws all the scene nodes. More...
 
virtual ICameraSceneNodegetActiveCamera () const =0
 Get the current active camera. More...
 
virtual const video::SColorfgetAmbientLight () const =0
 Get ambient color of the scene. More...
 
virtual const c8getAnimatorTypeName (ESCENE_NODE_ANIMATOR_TYPE type)=0
 Returns a typename from a scene node animator type or null if not found. More...
 
virtual E_SCENE_NODE_RENDER_PASS getCurrentRenderPass () const =0
 Get current render pass. More...
 
virtual ISceneNodeAnimatorFactorygetDefaultSceneNodeAnimatorFactory ()=0
 Get the default scene node animator factory which can create all built-in scene node animators. More...
 
virtual ISceneNodeFactorygetDefaultSceneNodeFactory ()=0
 Get the default scene node factory which can create all built in scene nodes. More...
 
virtual io::IFileSystemgetFileSystem ()=0
 Get the active FileSystem. More...
 
virtual const IGeometryCreatorgetGeometryCreator (void) const =0
 Get an instance of a geometry creator. More...
 
virtual gui::IGUIEnvironmentgetGUIEnvironment ()=0
 Get the active GUIEnvironment. More...
 
virtual IAnimatedMeshgetMesh (const io::path &filename, const io::path &alternativeCacheName=io::path(""))=0
 Get pointer to an animateable mesh. Loads the file if not loaded already. More...
 
virtual IAnimatedMeshgetMesh (io::IReadFile *file)=0
 Get pointer to an animateable mesh. Loads the file if not loaded already. More...
 
virtual IMeshCachegetMeshCache ()=0
 Get interface to the mesh cache which is shared between all existing scene managers. More...
 
virtual IMeshLoadergetMeshLoader (u32 index) const =0
 Retrieve the given mesh loader. More...
 
virtual u32 getMeshLoaderCount () const =0
 Returns the number of mesh loaders supported by Irrlicht at this time. More...
 
virtual IMeshManipulatorgetMeshManipulator ()=0
 Get pointer to the mesh manipulator. More...
 
virtual io::IAttributesgetParameters ()=0
 Get interface to the parameters set in this scene. More...
 
virtual u32 getRegisteredSceneNodeAnimatorFactoryCount () const =0
 Get amount of registered scene node animator factories. More...
 
virtual u32 getRegisteredSceneNodeFactoryCount () const =0
 Get amount of registered scene node factories. More...
 
virtual ISceneNodegetRootSceneNode ()=0
 Gets the root scene node. More...
 
virtual ISceneCollisionManagergetSceneCollisionManager ()=0
 Get pointer to the scene collision manager. More...
 
virtual ISceneLoadergetSceneLoader (u32 index) const =0
 Retrieve the given scene loader. More...
 
virtual u32 getSceneLoaderCount () const =0
 Returns the number of scene loaders supported by Irrlicht at this time. More...
 
virtual ISceneNodeAnimatorFactorygetSceneNodeAnimatorFactory (u32 index)=0
 Get scene node animator factory by index. More...
 
virtual ISceneNodeFactorygetSceneNodeFactory (u32 index)=0
 Get a scene node factory by index. More...
 
virtual ISceneNodegetSceneNodeFromId (s32 id, ISceneNode *start=0)=0
 Get the first scene node with the specified id. More...
 
virtual ISceneNodegetSceneNodeFromName (const c8 *name, ISceneNode *start=0)=0
 Get the first scene node with the specified name. More...
 
virtual ISceneNodegetSceneNodeFromType (scene::ESCENE_NODE_TYPE type, ISceneNode *start=0)=0
 Get the first scene node with the specified type. More...
 
virtual E_SCENE_NODE_RENDER_PASS getSceneNodeRenderPass () const =0
 Get current render pass. More...
 
virtual void getSceneNodesFromType (ESCENE_NODE_TYPE type, core::array< scene::ISceneNode * > &outNodes, ISceneNode *start=0)=0
 Get scene nodes by type. More...
 
virtual const c8getSceneNodeTypeName (ESCENE_NODE_TYPE type)=0
 Get typename from a scene node type or null if not found. More...
 
virtual video::SColor getShadowColor () const =0
 Get the current color of shadows. More...
 
virtual video::IVideoDrivergetVideoDriver ()=0
 Get the video driver. More...
 
virtual bool isCulled (const ISceneNode *node) const =0
 Check if node is culled in current view frustum. More...
 
virtual bool loadScene (const io::path &filename, ISceneUserDataSerializer *userDataSerializer=0, ISceneNode *rootNode=0)=0
 Loads a scene. Note that the current scene is not cleared before. More...
 
virtual bool loadScene (io::IReadFile *file, ISceneUserDataSerializer *userDataSerializer=0, ISceneNode *rootNode=0)=0
 Loads a scene. Note that the current scene is not cleared before. More...
 
virtual bool postEventFromUser (const SEvent &event)=0
 Posts an input event to the environment. More...
 
virtual u32 registerNodeForRendering (ISceneNode *node, E_SCENE_NODE_RENDER_PASS pass=ESNRP_AUTOMATIC)=0
 Registers a node for rendering it at a specific time. More...
 
virtual void registerSceneNodeAnimatorFactory (ISceneNodeAnimatorFactory *factoryToAdd)=0
 Adds a scene node animator factory to the scene manager. More...
 
virtual void registerSceneNodeFactory (ISceneNodeFactory *factoryToAdd)=0
 Adds a scene node factory to the scene manager. More...
 
virtual bool saveScene (const io::path &filename, ISceneUserDataSerializer *userDataSerializer=0, ISceneNode *node=0)=0
 Saves the current scene into a file. More...
 
virtual bool saveScene (io::IWriteFile *file, ISceneUserDataSerializer *userDataSerializer=0, ISceneNode *node=0)=0
 Saves the current scene into a file. More...
 
virtual bool saveScene (io::IXMLWriter *writer, const io::path &currentPath, ISceneUserDataSerializer *userDataSerializer=0, ISceneNode *node=0)=0
 Saves the current scene into a file. More...
 
virtual void setActiveCamera (ICameraSceneNode *camera)=0
 Sets the currently active camera. More...
 
virtual void setAmbientLight (const video::SColorf &ambientColor)=0
 Sets ambient color of the scene. More...
 
virtual void setCurrentRenderPass (E_SCENE_NODE_RENDER_PASS nextPass)=0
 Set current render pass. More...
 
virtual void setLightManager (ILightManager *lightManager)=0
 Register a custom callbacks manager which gets callbacks during scene rendering. More...
 
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. More...
 
- Public Member Functions inherited from irr::IReferenceCounted
 IReferenceCounted ()
 Constructor. More...
 
virtual ~IReferenceCounted ()
 Destructor. More...
 
bool drop () const
 Drops the object. Decrements the reference counter by one. More...
 
const c8getDebugName () const
 Returns the debug name of the object. More...
 
s32 getReferenceCount () const
 Get the reference count. More...
 
void grab () const
 Grabs the object. Increments the reference counter by one. More...
 

Additional Inherited Members

- Protected Member Functions inherited from irr::IReferenceCounted
void setDebugName (const c8 *newName)
 Sets the debug name of the object. More...
 

Detailed Description

The Scene Manager manages scene nodes, mesh resources, cameras and all the other stuff.

All Scene nodes can be created only here. There is a always growing list of scene nodes for lots of purposes: Indoor rendering scene nodes like the Octree (addOctreeSceneNode()) or the terrain renderer (addTerrainSceneNode()), different Camera scene nodes (addCameraSceneNode(), addCameraSceneNodeMaya()), scene nodes for Light (addLightSceneNode()), Billboards (addBillboardSceneNode()) and so on. A scene node is a node in the hierarchical scene graph. Every scene node may have children, which are other scene nodes. Children move relative the their parents position. If the parent of a node is not visible, its children won't be visible, too. In this way, it is for example easily possible to attach a light to a moving car or to place a walking character on a moving platform on a moving ship. The SceneManager is also able to load 3d mesh files of different formats. Take a look at getMesh() to find out what formats are supported. If these formats are not enough, use addExternalMeshLoader() to add new formats to the engine.

Definition at line 152 of file ISceneManager.h.

Member Function Documentation

◆ addAnimatedMeshSceneNode()

virtual IAnimatedMeshSceneNode* irr::scene::ISceneManager::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 
)
pure virtual

Adds a scene node for rendering an animated mesh model.

Parameters
meshPointer to the loaded animated mesh to be displayed.
parentParent of the scene node. Can be NULL if no parent.
idId of the node. This id can be used to identify the scene node.
positionPosition of the space relative to its parent where the scene node will be placed.
rotationInitial rotation of the scene node.
scaleInitial scale of the scene node.
alsoAddIfMeshPointerZeroAdd the scene node even if a 0 pointer is passed.
Returns
Pointer to the created scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addArrowMesh()

virtual IAnimatedMesh* irr::scene::ISceneManager::addArrowMesh ( const io::path name,
video::SColor  vtxColorCylinder = 0xFFFFFFFF,
video::SColor  vtxColorCone = 0xFFFFFFFF,
u32  tesselationCylinder = 4,
u32  tesselationCone = 8,
f32  height = 1.f,
f32  cylinderHeight = 0.6f,
f32  widthCylinder = 0.05f,
f32  widthCone = 0.3f 
)
pure virtual

add a static arrow mesh to the meshpool

Parameters
nameName of the mesh
vtxColorCylindercolor of the cylinder
vtxColorConecolor of the cone
tesselationCylinderNumber of quads the cylinder side consists of
tesselationConeNumber of triangles the cone's roof consists of
heightTotal height of the arrow
cylinderHeightTotal height of the cylinder, should be lesser than total height
widthCylinderDiameter of the cylinder
widthConeDiameter of the cone's base, should be not smaller than the cylinder's diameter
Returns
Pointer to the arrow mesh if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addBillboardSceneNode()

virtual IBillboardSceneNode* irr::scene::ISceneManager::addBillboardSceneNode ( ISceneNode parent = 0,
const core::dimension2d< f32 > &  size = core::dimension2df32 >(10.0f, 10.0f),
const core::vector3df position = core::vector3df(0, 0, 0),
s32  id = -1,
video::SColor  colorTop = 0xFFFFFFFF,
video::SColor  colorBottom = 0xFFFFFFFF 
)
pure virtual

Adds a billboard scene node to the scene graph.

A billboard is like a 3d sprite: A 2d element, which always looks to the camera. It is usually used for things like explosions, fire, lensflares and things like that.

Parameters
parentParent scene node of the billboard. Can be null. If the parent moves, the billboard will move too.
sizeSize of the billboard. This size is 2 dimensional because a billboard only has width and height.
positionPosition of the space relative to its parent where the billboard will be placed.
idAn id of the node. This id can be used to identify the node.
colorTopThe color of the vertices at the top of the billboard (default: white).
colorBottomThe color of the vertices at the bottom of the billboard (default: white).
Returns
Pointer to the billboard if successful, otherwise NULL. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addBillboardTextSceneNode()

virtual IBillboardTextSceneNode* irr::scene::ISceneManager::addBillboardTextSceneNode ( gui::IGUIFont font,
const wchar_t *  text,
ISceneNode parent = 0,
const core::dimension2d< f32 > &  size = core::dimension2df32 >(10.0f, 10.0f),
const core::vector3df position = core::vector3df(0, 0, 0),
s32  id = -1,
video::SColor  colorTop = 0xFFFFFFFF,
video::SColor  colorBottom = 0xFFFFFFFF 
)
pure virtual

Adds a text scene node, which uses billboards. The node, and the text on it, will scale with distance.

Parameters
fontThe font to use on the billboard. Pass 0 to use the GUI environment's default font.
textThe text to display on the billboard.
parentThe billboard's parent. Pass 0 to use the root scene node.
sizeThe billboard's width and height.
positionThe billboards position relative to its parent.
idAn id of the node. This id can be used to identify the node.
colorTopThe color of the vertices at the top of the billboard (default: white).
colorBottomThe color of the vertices at the bottom of the billboard (default: white).
Returns
Pointer to the billboard if successful, otherwise NULL. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addCameraSceneNode()

virtual ICameraSceneNode* irr::scene::ISceneManager::addCameraSceneNode ( ISceneNode parent = 0,
const core::vector3df position = core::vector3df(0, 0, 0),
const core::vector3df lookat = core::vector3df(0, 0, 100),
s32  id = -1,
bool  makeActive = true 
)
pure virtual

Adds a camera scene node to the scene graph and sets it as active camera.

This camera does not react on user input like for example the one created with addCameraSceneNodeFPS(). If you want to move or animate it, use animators or the ISceneNode::setPosition(), ICameraSceneNode::setTarget() etc methods. By default, a camera's look at position (set with setTarget()) and its scene node rotation (set with setRotation()) are independent. If you want to be able to control the direction that the camera looks by using setRotation() then call ICameraSceneNode::bindTargetAndRotation(true) on it.

Parameters
positionPosition of the space relative to its parent where the camera will be placed.
lookatPosition where the camera will look at. Also known as target.
parentParent scene node of the camera. Can be null. If the parent moves, the camera will move too.
idid of the camera. This id can be used to identify the camera.
makeActiveFlag whether this camera should become the active one. Make sure you always have one active camera.
Returns
Pointer to interface to camera if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addCameraSceneNodeFPS()

virtual ICameraSceneNode* irr::scene::ISceneManager::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 
)
pure virtual

Adds a camera scene node with an animator which provides mouse and keyboard control appropriate for first person shooters (FPS).

This FPS camera is intended to provide a demonstration of a camera that behaves like a typical First Person Shooter. It is useful for simple demos and prototyping but is not intended to provide a full solution for a production quality game. It binds the camera scene node rotation to the look-at target;

See also
ICameraSceneNode::bindTargetAndRotation(). With this camera, you look with the mouse, and move with cursor keys. If you want to change the key layout, you can specify your own keymap. For example to make the camera be controlled by the cursor keys AND the keys W,A,S, and D, do something like this:
SKeyMap keyMap[8];
keyMap[0].Action = EKA_MOVE_FORWARD;
keyMap[0].KeyCode = KEY_UP;
keyMap[1].Action = EKA_MOVE_FORWARD;
keyMap[1].KeyCode = KEY_KEY_W;
keyMap[2].Action = EKA_MOVE_BACKWARD;
keyMap[2].KeyCode = KEY_DOWN;
keyMap[3].Action = EKA_MOVE_BACKWARD;
keyMap[3].KeyCode = KEY_KEY_S;
keyMap[4].Action = EKA_STRAFE_LEFT;
keyMap[4].KeyCode = KEY_LEFT;
keyMap[5].Action = EKA_STRAFE_LEFT;
keyMap[5].KeyCode = KEY_KEY_A;
keyMap[6].Action = EKA_STRAFE_RIGHT;
keyMap[6].KeyCode = KEY_RIGHT;
keyMap[7].Action = EKA_STRAFE_RIGHT;
keyMap[7].KeyCode = KEY_KEY_D;
camera = sceneManager->addCameraSceneNodeFPS(0, 100, 500, -1, keyMap, 8);
Parameters
parentParent scene node of the camera. Can be null.
rotateSpeedSpeed in degrees with which the camera is rotated. This can be done only with the mouse.
moveSpeedSpeed in units per millisecond with which the camera is moved. Movement is done with the cursor keys.
idid of the camera. This id can be used to identify the camera.
keyMapArrayOptional pointer to an array of a keymap, specifying what keys should be used to move the camera. If this is null, the default keymap is used. You can define actions more then one time in the array, to bind multiple keys to the same action.
keyMapSizeAmount of items in the keymap array.
noVerticalMovementSetting this to true makes the camera only move within a horizontal plane, and disables vertical movement as known from most ego shooters. Default is 'false', with which it is possible to fly around in space, if no gravity is there.
jumpSpeedSpeed with which the camera is moved when jumping.
invertMouseSetting this to true makes the camera look up when the mouse is moved down and down when the mouse is moved up, the default is 'false' which means it will follow the movement of the mouse cursor.
makeActiveFlag whether this camera should become the active one. Make sure you always have one active camera.
Returns
Pointer to the interface of the camera if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addCameraSceneNodeMaya()

virtual ICameraSceneNode* irr::scene::ISceneManager::addCameraSceneNodeMaya ( ISceneNode parent = 0,
f32  rotateSpeed = -1500.f,
f32  zoomSpeed = 200.f,
f32  translationSpeed = 1500.f,
s32  id = -1,
f32  distance = 70.f,
bool  makeActive = true 
)
pure virtual

Adds a maya style user controlled camera scene node to the scene graph.

This is a standard camera with an animator that provides mouse control similar to camera in the 3D Software Maya by Alias Wavefront. The camera does not react on setPosition anymore after applying this animator. Instead use setTarget, to fix the target the camera the camera hovers around. And setDistance to set the current distance from that target, i.e. the radius of the orbit the camera hovers on.

Parameters
parentParent scene node of the camera. Can be null.
rotateSpeedRotation speed of the camera.
zoomSpeedZoom speed of the camera.
translationSpeedTranslationSpeed of the camera.
idid of the camera. This id can be used to identify the camera.
distanceInitial distance of the camera from the object
makeActiveFlag whether this camera should become the active one. Make sure you always have one active camera.
Returns
Returns a pointer to the interface of the camera if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addCubeSceneNode()

virtual IMeshSceneNode* irr::scene::ISceneManager::addCubeSceneNode ( f32  size = 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) 
)
pure virtual

Adds a cube scene node.

Parameters
sizeSize of the cube, uniformly in each dimension.
parentParent of the scene node. Can be 0 if no parent.
idId of the node. This id can be used to identify the scene node.
positionPosition of the space relative to its parent where the scene node will be placed.
rotationInitial rotation of the scene node.
scaleInitial scale of the scene node.
Returns
Pointer to the created test scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addDummyTransformationSceneNode()

virtual IDummyTransformationSceneNode* irr::scene::ISceneManager::addDummyTransformationSceneNode ( ISceneNode parent = 0,
s32  id = -1 
)
pure virtual

Adds a dummy transformation scene node to the scene graph.

This scene node does not render itself, and does not respond to set/getPosition, set/getRotation and set/getScale. Its just a simple scene node that takes a matrix as relative transformation, making it possible to insert any transformation anywhere into the scene graph.

Returns
Pointer to the created scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addEmptySceneNode()

virtual ISceneNode* irr::scene::ISceneManager::addEmptySceneNode ( ISceneNode parent = 0,
s32  id = -1 
)
pure virtual

Adds an empty scene node to the scene graph.

Can be used for doing advanced transformations or structuring the scene graph.

Returns
Pointer to the created scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addExternalMeshLoader()

virtual void irr::scene::ISceneManager::addExternalMeshLoader ( IMeshLoader externalLoader)
pure virtual

Adds an external mesh loader for extending the engine with new file formats.

If you want the engine to be extended with file formats it currently is not able to load (e.g. .cob), just implement the IMeshLoader interface in your loading class and add it with this method. Using this method it is also possible to override built-in mesh loaders with newer or updated versions without the need to recompile the engine.

Parameters
externalLoaderImplementation of a new mesh loader.

◆ addExternalSceneLoader()

virtual void irr::scene::ISceneManager::addExternalSceneLoader ( ISceneLoader externalLoader)
pure virtual

Adds an external scene loader for extending the engine with new file formats.

If you want the engine to be extended with file formats it currently is not able to load (e.g. .vrml), just implement the ISceneLoader interface in your loading class and add it with this method. Using this method it is also possible to override the built-in scene loaders with newer or updated versions without the need to recompile the engine.

Parameters
externalLoaderImplementation of a new mesh loader.

◆ addHillPlaneMesh()

virtual IAnimatedMesh* irr::scene::ISceneManager::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::dimension2df32 >(0.0f, 0.0f),
const core::dimension2d< f32 > &  textureRepeatCount = core::dimension2df32 >(1.0f, 1.0f) 
)
pure virtual

Adds a Hill Plane mesh to the mesh pool.

The mesh is generated on the fly and looks like a plane with some hills on it. It is uses mostly for quick tests of the engine only. You can specify how many hills there should be on the plane and how high they should be. Also you must specify a name for the mesh, because the mesh is added to the mesh pool, and can be retrieved again using ISceneManager::getMesh() with the name as parameter.

Parameters
nameThe name of this mesh which must be specified in order to be able to retrieve the mesh later with ISceneManager::getMesh().
tileSizeSize of a tile of the mesh. (10.0f, 10.0f) would be a good value to start, for example.
tileCountSpecifies how much tiles there will be. If you specify for example that a tile has the size (10.0f, 10.0f) and the tileCount is (10,10), than you get a field of 100 tiles which has the dimension 100.0f x 100.0f.
materialMaterial of the hill mesh.
hillHeightHeight of the hills. If you specify a negative value you will get holes instead of hills. If the height is 0, no hills will be created.
countHillsAmount of hills on the plane. There will be countHills.X hills along the X axis and countHills.Y along the Y axis. So in total there will be countHills.X * countHills.Y hills.
textureRepeatCountDefines how often the texture will be repeated in x and y direction. return Null if the creation failed. The reason could be that you specified some invalid parameters or that a mesh with that name already exists. If successful, a pointer to the mesh is returned. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addLightSceneNode()

virtual ILightSceneNode* irr::scene::ISceneManager::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 
)
pure virtual

Adds a dynamic light scene node to the scene graph.

The light will cast dynamic light on all other scene nodes in the scene, which have the material flag video::MTF_LIGHTING turned on. (This is the default setting in most scene nodes).

Parameters
parentParent scene node of the light. Can be null. If the parent moves, the light will move too.
positionPosition of the space relative to its parent where the light will be placed.
colorDiffuse color of the light. Ambient or Specular colors can be set manually with the ILightSceneNode::getLightData() method.
radiusRadius of the light.
idid of the node. This id can be used to identify the node.
Returns
Pointer to the interface of the light if successful, otherwise NULL. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addMeshSceneNode()

virtual IMeshSceneNode* irr::scene::ISceneManager::addMeshSceneNode ( IMesh 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 
)
pure virtual

Adds a scene node for rendering a static mesh.

Parameters
meshPointer to the loaded static mesh to be displayed.
parentParent of the scene node. Can be NULL if no parent.
idId of the node. This id can be used to identify the scene node.
positionPosition of the space relative to its parent where the scene node will be placed.
rotationInitial rotation of the scene node.
scaleInitial scale of the scene node.
alsoAddIfMeshPointerZeroAdd the scene node even if a 0 pointer is passed.
Returns
Pointer to the created scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addOctreeSceneNode() [1/2]

virtual IOctreeSceneNode* irr::scene::ISceneManager::addOctreeSceneNode ( IAnimatedMesh mesh,
ISceneNode parent = 0,
s32  id = -1,
s32  minimalPolysPerNode = 512,
bool  alsoAddIfMeshPointerZero = false 
)
pure virtual

Adds a scene node for rendering using a octree to the scene graph.

This a good method for rendering scenes with lots of geometry. The octree is built on the fly from the mesh.

Parameters
meshThe mesh containing all geometry from which the octree will be build. If this animated mesh has more than one frames in it, the first frame is taken.
parentParent node of the octree node.
idid of the node. This id can be used to identify the node.
minimalPolysPerNodeSpecifies the minimal polygons contained a octree node. If a node gets less polys than this value it will not be split into smaller nodes.
alsoAddIfMeshPointerZeroAdd the scene node even if a 0 pointer is passed.
Returns
Pointer to the octree if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addOctreeSceneNode() [2/2]

virtual IOctreeSceneNode* irr::scene::ISceneManager::addOctreeSceneNode ( IMesh mesh,
ISceneNode parent = 0,
s32  id = -1,
s32  minimalPolysPerNode = 256,
bool  alsoAddIfMeshPointerZero = false 
)
pure virtual

Adds a scene node for rendering using a octree to the scene graph.

This a good method for rendering scenes with lots of geometry. The octree is built on the fly from the mesh, much faster then a bsp tree.

Parameters
meshThe mesh containing all geometry from which the octree will be build.
parentParent node of the octree node.
idid of the node. This id can be used to identify the node.
minimalPolysPerNodeSpecifies the minimal polygons contained a octree node. If a node gets less polys than this value it will not be split into smaller nodes.
alsoAddIfMeshPointerZeroAdd the scene node even if a 0 pointer is passed.
Returns
Pointer to the octree if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addParticleSystemSceneNode()

virtual IParticleSystemSceneNode* irr::scene::ISceneManager::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) 
)
pure virtual

Adds a particle system scene node to the scene graph.

Parameters
withDefaultEmitterCreates a default working point emitter which emits some particles. Set this to true to see a particle system in action. If set to false, you'll have to set the emitter you want by calling IParticleSystemSceneNode::setEmitter().
parentParent of the scene node. Can be NULL if no parent.
idId of the node. This id can be used to identify the scene node.
positionPosition of the space relative to its parent where the scene node will be placed.
rotationInitial rotation of the scene node.
scaleInitial scale of the scene node.
Returns
Pointer to the created scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addQuake3SceneNode()

virtual IMeshSceneNode* irr::scene::ISceneManager::addQuake3SceneNode ( const IMeshBuffer meshBuffer,
const quake3::IShader shader,
ISceneNode parent = 0,
s32  id = -1 
)
pure virtual

Adds a quake3 scene node to the scene graph.

A Quake3 Scene renders multiple meshes for a specific HighLanguage Shader (Quake3 Style )

Returns
Pointer to the quake3 scene node if successful, otherwise NULL. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addSceneNode()

virtual ISceneNode* irr::scene::ISceneManager::addSceneNode ( const char *  sceneNodeTypeName,
ISceneNode parent = 0 
)
pure virtual

Adds a scene node to the scene by name.

Returns
Pointer to the scene node added by a factory This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addSkyBoxSceneNode()

virtual ISceneNode* irr::scene::ISceneManager::addSkyBoxSceneNode ( video::ITexture top,
video::ITexture bottom,
video::ITexture left,
video::ITexture right,
video::ITexture front,
video::ITexture back,
ISceneNode parent = 0,
s32  id = -1 
)
pure virtual

Adds a skybox scene node to the scene graph.

A skybox is a big cube with 6 textures on it and is drawn around the camera position.

Parameters
topTexture for the top plane of the box.
bottomTexture for the bottom plane of the box.
leftTexture for the left plane of the box.
rightTexture for the right plane of the box.
frontTexture for the front plane of the box.
backTexture for the back plane of the box.
parentParent scene node of the skybox. A skybox usually has no parent, so this should be null. Note: If a parent is set to the skybox, the box will not change how it is drawn.
idAn id of the node. This id can be used to identify the node.
Returns
Pointer to the sky box if successful, otherwise NULL. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addSkyDomeSceneNode()

virtual ISceneNode* irr::scene::ISceneManager::addSkyDomeSceneNode ( video::ITexture texture,
u32  horiRes = 16,
u32  vertRes = 8,
f32  texturePercentage = 0.9,
f32  spherePercentage = 2.0,
f32  radius = 1000.f,
ISceneNode parent = 0,
s32  id = -1 
)
pure virtual

Adds a skydome scene node to the scene graph.

A skydome is a large (half-) sphere with a panoramic texture on the inside and is drawn around the camera position.

Parameters
textureTexture for the dome.
horiResNumber of vertices of a horizontal layer of the sphere.
vertResNumber of vertices of a vertical layer of the sphere.
texturePercentageHow much of the height of the texture is used. Should be between 0 and 1.
spherePercentageHow much of the sphere is drawn. Value should be between 0 and 2, where 1 is an exact half-sphere and 2 is a full sphere.
radiusThe Radius of the sphere
parentParent scene node of the dome. A dome usually has no parent, so this should be null. Note: If a parent is set, the dome will not change how it is drawn.
idAn id of the node. This id can be used to identify the node.
Returns
Pointer to the sky dome if successful, otherwise NULL. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addSphereMesh()

virtual IAnimatedMesh* irr::scene::ISceneManager::addSphereMesh ( const io::path name,
f32  radius = 5.f,
u32  polyCountX = 16,
u32  polyCountY = 16 
)
pure virtual

add a static sphere mesh to the meshpool

Parameters
nameName of the mesh
radiusRadius of the sphere
polyCountXNumber of quads used for the horizontal tiling
polyCountYNumber of quads used for the vertical tiling
Returns
Pointer to the sphere mesh if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addSphereSceneNode()

virtual IMeshSceneNode* irr::scene::ISceneManager::addSphereSceneNode ( f32  radius = 5.0f,
s32  polyCount = 16,
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) 
)
pure virtual

Adds a sphere scene node of the given radius and detail.

Parameters
radiusRadius of the sphere.
polyCountThe number of vertices in horizontal and vertical direction. The total polyCount of the sphere is polyCount*polyCount. This parameter must be less than 256 to stay within the 16-bit limit of the indices of a meshbuffer.
parentParent of the scene node. Can be 0 if no parent.
idId of the node. This id can be used to identify the scene node.
positionPosition of the space relative to its parent where the scene node will be placed.
rotationInitial rotation of the scene node.
scaleInitial scale of the scene node.
Returns
Pointer to the created test scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addTerrainMesh()

virtual IAnimatedMesh* irr::scene::ISceneManager::addTerrainMesh ( const io::path meshname,
video::IImage texture,
video::IImage heightmap,
const core::dimension2d< f32 > &  stretchSize = core::dimension2df32 >(10.0f, 10.0f),
f32  maxHeight = 200.0f,
const core::dimension2d< u32 > &  defaultVertexBlockSize = core::dimension2du32 >(64, 64) 
)
pure virtual

Adds a static terrain mesh to the mesh pool.

The mesh is generated on the fly from a texture file and a height map file. Both files may be huge (8000x8000 pixels would be no problem) because the generator splits the files into smaller textures if necessary. You must specify a name for the mesh, because the mesh is added to the mesh pool, and can be retrieved again using ISceneManager::getMesh() with the name as parameter.

Parameters
meshnameThe name of this mesh which must be specified in order to be able to retrieve the mesh later with ISceneManager::getMesh().
textureTexture for the terrain. Please note that this is not a hardware texture as usual (ITexture), but an IImage software texture. You can load this texture with IVideoDriver::createImageFromFile().
heightmapA grayscaled heightmap image. Like the texture, it can be created with IVideoDriver::createImageFromFile(). The amount of triangles created depends on the size of this texture, so use a small heightmap to increase rendering speed.
stretchSizeParameter defining how big a is pixel on the heightmap.
maxHeightDefines how high a white pixel on the heightmap is.
defaultVertexBlockSizeDefines the initial dimension between vertices.
Returns
Null if the creation failed. The reason could be that you specified some invalid parameters, that a mesh with that name already exists, or that a texture could not be found. If successful, a pointer to the mesh is returned. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addTerrainSceneNode() [1/2]

virtual ITerrainSceneNode* irr::scene::ISceneManager::addTerrainSceneNode ( const io::path heightMapFileName,
ISceneNode parent = 0,
s32  id = -1,
const core::vector3df position = core::vector3df(0.0f, 0.0f, 0.0f),
const core::vector3df rotation = core::vector3df(0.0f, 0.0f, 0.0f),
const core::vector3df scale = core::vector3df(1.0f, 1.0f, 1.0f),
video::SColor  vertexColor = video::SColor(255, 255, 255, 255),
s32  maxLOD = 5,
E_TERRAIN_PATCH_SIZE  patchSize = ETPS_17,
s32  smoothFactor = 0,
bool  addAlsoIfHeightmapEmpty = false 
)
pure virtual

Adds a terrain scene node to the scene graph.

This node implements is a simple terrain renderer which uses a technique known as geo mip mapping for reducing the detail of triangle blocks which are far away. The code for the TerrainSceneNode is based on the terrain renderer by Soconne and the GeoMipMapSceneNode developed by Spintz. They made their code available for Irrlicht and allowed it to be distributed under this licence. I only modified some parts. A lot of thanks go to them.

This scene node is capable of loading terrains and updating the indices at runtime to enable viewing very large terrains very quickly. It uses a CLOD (Continuous Level of Detail) algorithm which updates the indices for each patch based on a LOD (Level of Detail) which is determined based on a patch's distance from the camera.

The patch size of the terrain must always be a size of 2^N+1, i.e. 8+1(9), 16+1(17), etc. The MaxLOD available is directly dependent on the patch size of the terrain. LOD 0 contains all of the indices to draw all the triangles at the max detail for a patch. As each LOD goes up by 1 the step taken, in generating indices increases by -2^LOD, so for LOD 1, the step taken is 2, for LOD 2, the step taken is 4, LOD 3 - 8, etc. The step can be no larger than the size of the patch, so having a LOD of 8, with a patch size of 17, is asking the algorithm to generate indices every 2^8 ( 256 ) vertices, which is not possible with a patch size of 17. The maximum LOD for a patch size of 17 is 2^4 ( 16 ). So, with a MaxLOD of 5, you'll have LOD 0 ( full detail ), LOD 1 ( every 2 vertices ), LOD 2 ( every 4 vertices ), LOD 3 ( every 8 vertices ) and LOD 4 ( every 16 vertices ).

Parameters
heightMapFileNameThe name of the file on disk, to read vertex data from. This should be a gray scale bitmap.
parentParent of the scene node. Can be 0 if no parent.
idId of the node. This id can be used to identify the scene node.
positionThe absolute position of this node.
rotationThe absolute rotation of this node. ( NOT YET IMPLEMENTED )
scaleThe scale factor for the terrain. If you're using a heightmap of size 129x129 and would like your terrain to be 12900x12900 in game units, then use a scale factor of ( core::vector ( 100.0f, 100.0f, 100.0f ). If you use a Y scaling factor of 0.0f, then your terrain will be flat.
vertexColorThe default color of all the vertices. If no texture is associated with the scene node, then all vertices will be this color. Defaults to white.
maxLODThe maximum LOD (level of detail) for the node. Only change if you know what you are doing, this might lead to strange behavior.
patchSizepatch size of the terrain. Only change if you know what you are doing, this might lead to strange behavior.
smoothFactorThe number of times the vertices are smoothed.
addAlsoIfHeightmapEmptyAdd terrain node even with empty heightmap.
Returns
Pointer to the created scene node. Can be null if the terrain could not be created, for example because the heightmap could not be loaded. The returned pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addTerrainSceneNode() [2/2]

virtual ITerrainSceneNode* irr::scene::ISceneManager::addTerrainSceneNode ( io::IReadFile heightMapFile,
ISceneNode parent = 0,
s32  id = -1,
const core::vector3df position = core::vector3df(0.0f, 0.0f, 0.0f),
const core::vector3df rotation = core::vector3df(0.0f, 0.0f, 0.0f),
const core::vector3df scale = core::vector3df(1.0f, 1.0f, 1.0f),
video::SColor  vertexColor = video::SColor(255, 255, 255, 255),
s32  maxLOD = 5,
E_TERRAIN_PATCH_SIZE  patchSize = ETPS_17,
s32  smoothFactor = 0,
bool  addAlsoIfHeightmapEmpty = false 
)
pure virtual

Adds a terrain scene node to the scene graph.

Just like the other addTerrainSceneNode() method, but takes an IReadFile pointer as parameter for the heightmap. For more information take a look at the other function.

Parameters
heightMapFileThe file handle to read vertex data from. This should be a gray scale bitmap.
parentParent of the scene node. Can be 0 if no parent.
idId of the node. This id can be used to identify the scene node.
positionThe absolute position of this node.
rotationThe absolute rotation of this node. ( NOT YET IMPLEMENTED )
scaleThe scale factor for the terrain. If you're using a heightmap of size 129x129 and would like your terrain to be 12900x12900 in game units, then use a scale factor of ( core::vector ( 100.0f, 100.0f, 100.0f ). If you use a Y scaling factor of 0.0f, then your terrain will be flat.
vertexColorThe default color of all the vertices. If no texture is associated with the scene node, then all vertices will be this color. Defaults to white.
maxLODThe maximum LOD (level of detail) for the node. Only change if you know what you are doing, this might lead to strange behavior.
patchSizepatch size of the terrain. Only change if you know what you are doing, this might lead to strange behavior.
smoothFactorThe number of times the vertices are smoothed.
addAlsoIfHeightmapEmptyAdd terrain node even with empty heightmap.
Returns
Pointer to the created scene node. Can be null if the terrain could not be created, for example because the heightmap could not be loaded. The returned pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addTextSceneNode()

virtual ITextSceneNode* irr::scene::ISceneManager::addTextSceneNode ( gui::IGUIFont font,
const wchar_t *  text,
video::SColor  color = video::SColor(100, 255, 255, 255),
ISceneNode parent = 0,
const core::vector3df position = core::vector3df(0, 0, 0),
s32  id = -1 
)
pure virtual

Adds a text scene node, which is able to display 2d text at a position in three dimensional space.

◆ addToDeletionQueue()

virtual void irr::scene::ISceneManager::addToDeletionQueue ( ISceneNode node)
pure virtual

Adds a scene node to the deletion queue.

The scene node is immediately deleted when it's secure. Which means when the scene node does not execute animators and things like that. This method is for example used for deleting scene nodes by their scene node animators. In most other cases, a ISceneNode::remove() call is enough, using this deletion queue is not necessary. See ISceneManager::createDeleteAnimator() for details.

Parameters
nodeNode to delete.

◆ addVolumeLightMesh()

virtual IAnimatedMesh* irr::scene::ISceneManager::addVolumeLightMesh ( const io::path name,
const u32  SubdivideU = 32,
const u32  SubdivideV = 32,
const video::SColor  FootColor = video::SColor(51, 0, 230, 180),
const video::SColor  TailColor = video::SColor(0, 0, 0, 0) 
)
pure virtual

Add a volume light mesh to the meshpool.

Parameters
nameName of the mesh
SubdivideUHorizontal subdivision count
SubdivideVVertical subdivision count
FootColorColor of the bottom of the light
TailColorColor of the top of the light
Returns
Pointer to the volume light mesh if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addVolumeLightSceneNode()

virtual IVolumeLightSceneNode* irr::scene::ISceneManager::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) 
)
pure virtual

adds Volume Lighting Scene Node.

Example Usage: scene::IVolumeLightSceneNode * n = smgr->addVolumeLightSceneNode(0, -1, 32, 32, //Subdivide U/V video::SColor(0, 180, 180, 180), //foot color video::SColor(0, 0, 0, 0) //tail color ); if (n) { n->setScale(core::vector3df(46.0f, 45.0f, 46.0f)); n->getMaterial(0).setTexture(0, smgr->getVideoDriver()->getTexture("lightFalloff.png")); }

Returns
Pointer to the volumeLight if successful, otherwise NULL. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ addWaterSurfaceSceneNode()

virtual ISceneNode* irr::scene::ISceneManager::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) 
)
pure virtual

Adds a scene node for rendering a animated water surface mesh.

Looks really good when the Material type EMT_TRANSPARENT_REFLECTION is used.

Parameters
waveHeightHeight of the water waves.
waveSpeedSpeed of the water waves.
waveLengthLength of a water wave.
meshPointer to the loaded static mesh to be displayed with water waves on it.
parentParent of the scene node. Can be NULL if no parent.
idId of the node. This id can be used to identify the scene node.
positionPosition of the space relative to its parent where the scene node will be placed.
rotationInitial rotation of the scene node.
scaleInitial scale of the scene node.
Returns
Pointer to the created scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ clear()

virtual void irr::scene::ISceneManager::clear ( )
pure virtual

Clears the whole scene.

All scene nodes are removed.

◆ clearAllRegisteredNodesForRendering()

virtual void irr::scene::ISceneManager::clearAllRegisteredNodesForRendering ( )
pure virtual

Clear all nodes which are currently registered for rendering.

Usually you don't have to care about this as drawAll will clear nodes after rendering them. But sometimes you might have to manully reset this. For example when you deleted nodes between registering and rendering.

◆ createCollisionResponseAnimator()

virtual ISceneNodeAnimatorCollisionResponse* irr::scene::ISceneManager::createCollisionResponseAnimator ( ITriangleSelector world,
ISceneNode sceneNode,
const core::vector3df ellipsoidRadius = core::vector3df(30, 60, 30),
const core::vector3df gravityPerSecond = core::vector3df(0,-10.0f, 0),
const core::vector3df ellipsoidTranslation = core::vector3df(0, 0, 0),
f32  slidingValue = 0.0005f 
)
pure virtual

Creates a special scene node animator for doing automatic collision detection and response.

See ISceneNodeAnimatorCollisionResponse for details.

Parameters
worldTriangle selector holding all triangles of the world with which the scene node may collide. You can create a triangle selector with ISceneManager::createTriangleSelector();
sceneNodeSceneNode which should be manipulated. After you added this animator to the scene node, the scene node will not be able to move through walls and is affected by gravity. If you need to teleport the scene node to a new position without it being effected by the collision geometry, then call sceneNode->setPosition(); then animator->setTargetNode(sceneNode);
ellipsoidRadiusRadius of the ellipsoid with which collision detection and response is done. If you have got a scene node, and you are unsure about how big the radius should be, you could use the following code to determine it:
const core::aabbox3d<f32>& box = yourSceneNode->getBoundingBox();
core::vector3df radius = box.MaxEdge - box.getCenter();
gravityPerSecondSets the gravity of the environment, as an acceleration in units per second per second. If your units are equivalent to meters, then core::vector3df(0,-10.0f,0) would give an approximately realistic gravity. You can disable gravity by setting it to core::vector3df(0,0,0).
ellipsoidTranslationBy default, the ellipsoid for collision detection is created around the center of the scene node, which means that the ellipsoid surrounds it completely. If this is not what you want, you may specify a translation for the ellipsoid.
slidingValueDOCUMENTATION NEEDED.
Returns
The animator. Attach it to a scene node with ISceneNode::addAnimator() and the animator will cause it to do collision detection and response. If you no longer need the animator, you should call ISceneNodeAnimator::drop(). See IReferenceCounted::drop() for more information.

◆ createDeleteAnimator()

virtual ISceneNodeAnimator* irr::scene::ISceneManager::createDeleteAnimator ( u32  timeMs)
pure virtual

Creates a scene node animator, which deletes the scene node after some time automatically.

Parameters
timeMsTime in milliseconds, after when the node will be deleted.
Returns
The animator. Attach it to a scene node with ISceneNode::addAnimator() and the animator will animate it. If you no longer need the animator, you should call ISceneNodeAnimator::drop(). See IReferenceCounted::drop() for more information.

◆ createFlyCircleAnimator()

virtual ISceneNodeAnimator* irr::scene::ISceneManager::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 
)
pure virtual

Creates a fly circle animator, which lets the attached scene node fly around a center.

Parameters
centerCenter of the circle.
radiusRadius of the circle.
speedThe orbital speed, in radians per millisecond.
directionSpecifies the upvector used for alignment of the mesh.
startPositionThe position on the circle where the animator will begin. Value is in multiples of a circle, i.e. 0.5 is half way around. (phase)
radiusEllipsoidif radiusEllipsoid != 0 then radius2 from a ellipsoid begin. Value is in multiples of a circle, i.e. 0.5 is half way around. (phase)
Returns
The animator. Attach it to a scene node with ISceneNode::addAnimator() and the animator will animate it. If you no longer need the animator, you should call ISceneNodeAnimator::drop(). See IReferenceCounted::drop() for more information.

◆ createFlyStraightAnimator()

virtual ISceneNodeAnimator* irr::scene::ISceneManager::createFlyStraightAnimator ( const core::vector3df startPoint,
const core::vector3df endPoint,
u32  timeForWay,
bool  loop = false,
bool  pingpong = false 
)
pure virtual

Creates a fly straight animator, which lets the attached scene node fly or move along a line between two points.

Parameters
startPointStart point of the line.
endPointEnd point of the line.
timeForWayTime in milliseconds how long the node should need to move from the start point to the end point.
loopIf set to false, the node stops when the end point is reached. If loop is true, the node begins again at the start.
pingpongFlag to set whether the animator should fly back from end to start again.
Returns
The animator. Attach it to a scene node with ISceneNode::addAnimator() and the animator will animate it. If you no longer need the animator, you should call ISceneNodeAnimator::drop(). See IReferenceCounted::drop() for more information.

◆ createFollowSplineAnimator()

virtual ISceneNodeAnimator* irr::scene::ISceneManager::createFollowSplineAnimator ( s32  startTime,
const core::array< core::vector3df > &  points,
f32  speed = 1.0f,
f32  tightness = 0.5f,
bool  loop = true,
bool  pingpong = false 
)
pure virtual

Creates a follow spline animator.

The animator modifies the position of the attached scene node to make it follow a Hermite spline. It uses a subset of Hermite splines: either cardinal splines (tightness != 0.5) or Catmull-Rom-splines (tightness == 0.5). The animator moves from one control point to the next in 1/speed seconds. This code was sent in by Matthias Gall. If you no longer need the animator, you should call ISceneNodeAnimator::drop(). See IReferenceCounted::drop() for more information.

◆ createMeshWriter()

virtual IMeshWriter* irr::scene::ISceneManager::createMeshWriter ( EMESH_WRITER_TYPE  type)
pure virtual

Get a mesh writer implementation if available.

Note: You need to drop() the pointer after use again, see IReferenceCounted::drop() for details.

◆ createMetaTriangleSelector()

virtual IMetaTriangleSelector* irr::scene::ISceneManager::createMetaTriangleSelector ( )
pure virtual

Creates a meta triangle selector.

A meta triangle selector is nothing more than a collection of one or more triangle selectors providing together the interface of one triangle selector. In this way, collision tests can be done with different triangle soups in one pass.

Returns
The selector, or null if not successful. If you no longer need the selector, you should call ITriangleSelector::drop(). See IReferenceCounted::drop() for more information.

◆ createNewSceneManager()

virtual ISceneManager* irr::scene::ISceneManager::createNewSceneManager ( bool  cloneContent = false)
pure virtual

Creates a new scene manager.

This can be used to easily draw and/or store two independent scenes at the same time. The mesh cache will be shared between all existing scene managers, which means if you load a mesh in the original scene manager using for example getMesh(), the mesh will be available in all other scene managers too, without loading. The original/main scene manager will still be there and accessible via IrrlichtDevice::getSceneManager(). If you need input event in this new scene manager, for example for FPS cameras, you'll need to forward input to this manually: Just implement an IEventReceiver and call yourNewSceneManager->postEventFromUser(), and return true so that the original scene manager doesn't get the event. Otherwise, all input will go to the main scene manager automatically. If you no longer need the new scene manager, you should call ISceneManager::drop(). See IReferenceCounted::drop() for more information.

◆ createOctreeTriangleSelector() [1/2]

virtual ITriangleSelector* irr::scene::ISceneManager::createOctreeTriangleSelector ( IMesh mesh,
ISceneNode node,
s32  minimalPolysPerNode = 32 
)
pure virtual

Creates a Triangle Selector, optimized by an octree.

Triangle selectors can be used for doing collision detection. This triangle selector is optimized for huge amounts of triangle, it organizes them in an octree. Please note that the created triangle selector is not automatically attached to the scene node. You will have to call ISceneNode::setTriangleSelector() for this. To create and attach a triangle selector is done like this:

ITriangleSelector* s = sceneManager->createOctreeTriangleSelector(yourMesh,
yourSceneNode);
yourSceneNode->setTriangleSelector(s);
s->drop();

For more information and examples on this, take a look at the collision tutorial in the SDK.

Parameters
meshMesh of which the triangles are taken.
nodeScene node of which visibility and transformation is used.
minimalPolysPerNodeSpecifies the minimal polygons contained a octree node. If a node gets less polys than this value, it will not be split into smaller nodes.
Returns
The selector, or null if not successful. If you no longer need the selector, you should call ITriangleSelector::drop(). See IReferenceCounted::drop() for more information.

Referenced by createOctTreeTriangleSelector().

◆ createOctreeTriangleSelector() [2/2]

virtual ITriangleSelector* irr::scene::ISceneManager::createOctreeTriangleSelector ( IMeshBuffer meshBuffer,
irr::u32  materialIndex,
ISceneNode node,
s32  minimalPolysPerNode = 32 
)
pure virtual

Creates a Triangle Selector for a single meshbuffer, optimized by an octree.

Triangle selectors can be used for doing collision detection. This triangle selector is optimized for huge amounts of triangle, it organizes them in an octree. Please note that the created triangle selector is not automatically attached to the scene node. You will have to call ISceneNode::setTriangleSelector() for this. To create and attach a triangle selector is done like this:

ITriangleSelector* s = sceneManager->createOctreeTriangleSelector(yourMesh,
yourSceneNode);
yourSceneNode->setTriangleSelector(s);
s->drop();

For more information and examples on this, take a look at the collision tutorial in the SDK.

Parameters
meshBufferMeshbuffer of which the triangles are taken.
materialIndexSetting this value allows the triangle selector to return the material index
nodeScene node of which visibility and transformation is used.
minimalPolysPerNodeSpecifies the minimal polygons contained a octree node. If a node gets less polys than this value, it will not be split into smaller nodes.
Returns
The selector, or null if not successful. If you no longer need the selector, you should call ITriangleSelector::drop(). See IReferenceCounted::drop() for more information.

◆ createOctTreeTriangleSelector()

_IRR_DEPRECATED_ ITriangleSelector* irr::scene::ISceneManager::createOctTreeTriangleSelector ( IMesh mesh,
ISceneNode node,
s32  minimalPolysPerNode = 32 
)
inline

//! Creates a Triangle Selector, optimized by an octree.

Deprecated:
Use createOctreeTriangleSelector instead. This method may be removed by Irrlicht 1.9.

Definition at line 1359 of file ISceneManager.h.

References createOctreeTriangleSelector().

◆ createRotationAnimator()

virtual ISceneNodeAnimator* irr::scene::ISceneManager::createRotationAnimator ( const core::vector3df rotationSpeed)
pure virtual

Creates a rotation animator, which rotates the attached scene node around itself.

Parameters
rotationSpeedSpecifies the speed of the animation in degree per 10 milliseconds.
Returns
The animator. Attach it to a scene node with ISceneNode::addAnimator() and the animator will animate it. If you no longer need the animator, you should call ISceneNodeAnimator::drop(). See IReferenceCounted::drop() for more information.

◆ createSceneNodeAnimator()

virtual ISceneNodeAnimator* irr::scene::ISceneManager::createSceneNodeAnimator ( const char *  typeName,
ISceneNode target = 0 
)
pure virtual

creates a scene node animator based on its type name

Parameters
typeNameType of the scene node animator to add.
targetTarget scene node of the new animator.
Returns
Returns pointer to the new scene node animator or null if not successful. You need to drop this pointer after calling this, see IReferenceCounted::drop() for details.

◆ createSkinnedMesh()

virtual ISkinnedMesh* irr::scene::ISceneManager::createSkinnedMesh ( )
pure virtual

Get a skinned mesh, which is not available as header-only code.

Note: You need to drop() the pointer after use again, see IReferenceCounted::drop() for details.

◆ createTerrainTriangleSelector()

virtual ITriangleSelector* irr::scene::ISceneManager::createTerrainTriangleSelector ( ITerrainSceneNode node,
s32  LOD = 0 
)
pure virtual

Creates a triangle selector which can select triangles from a terrain scene node.

Parameters
nodePointer to the created terrain scene node
LODLevel of detail, 0 for highest detail.
Returns
The selector, or null if not successful. If you no longer need the selector, you should call ITriangleSelector::drop(). See IReferenceCounted::drop() for more information.

◆ createTextureAnimator()

virtual ISceneNodeAnimator* irr::scene::ISceneManager::createTextureAnimator ( const core::array< video::ITexture * > &  textures,
s32  timePerFrame,
bool  loop = true 
)
pure virtual

Creates a texture animator, which switches the textures of the target scene node based on a list of textures.

Parameters
texturesList of textures to use.
timePerFrameTime in milliseconds, how long any texture in the list should be visible.
loopIf set to to false, the last texture remains set, and the animation stops. If set to true, the animation restarts with the first texture.
Returns
The animator. Attach it to a scene node with ISceneNode::addAnimator() and the animator will animate it. If you no longer need the animator, you should call ISceneNodeAnimator::drop(). See IReferenceCounted::drop() for more information.

◆ createTriangleSelector() [1/3]

virtual ITriangleSelector* irr::scene::ISceneManager::createTriangleSelector ( IMesh mesh,
ISceneNode node,
bool  separateMeshbuffers = false 
)
pure virtual

Creates a simple ITriangleSelector, based on a mesh.

Triangle selectors can be used for doing collision detection. Don't use this selector for a huge amount of triangles like in Quake3 maps. Instead, use for example ISceneManager::createOctreeTriangleSelector(). Please note that the created triangle selector is not automatically attached to the scene node. You will have to call ISceneNode::setTriangleSelector() for this. To create and attach a triangle selector is done like this:

ITriangleSelector* s = sceneManager->createTriangleSelector(yourMesh,
yourSceneNode);
yourSceneNode->setTriangleSelector(s);
s->drop();
Parameters
meshMesh of which the triangles are taken.
nodeScene node of which transformation is used.
separateMeshbuffersWhen true it's possible to get information which meshbuffer got hit in collision tests. But has a slight speed cost.
Returns
The selector, or null if not successful. If you no longer need the selector, you should call ITriangleSelector::drop(). See IReferenceCounted::drop() for more information.

◆ createTriangleSelector() [2/3]

virtual ITriangleSelector* irr::scene::ISceneManager::createTriangleSelector ( const IMeshBuffer meshBuffer,
irr::u32  materialIndex,
ISceneNode node 
)
pure virtual

Creates a simple ITriangleSelector, based on a meshbuffer.

This is a static selector which won't update when the mesh changes.

Parameters
meshBufferTriangles of that meshbuffer are used
materialIndexIf you pass a material index that index can be returned by the triangle selector. \para node: Scene node of which transformation is used.

◆ createTriangleSelector() [3/3]

virtual ITriangleSelector* irr::scene::ISceneManager::createTriangleSelector ( IAnimatedMeshSceneNode node,
bool  separateMeshbuffers = false 
)
pure virtual

Creates a simple ITriangleSelector, based on an animated mesh scene node.

Details of the mesh associated with the node will be extracted internally.

Parameters
nodeThe animated mesh scene node from which to build the selector
separateMeshbuffersWhen true it's possible to get information which meshbuffer got hit in collision tests. But has a slight speed cost.

◆ createTriangleSelectorFromBoundingBox()

virtual ITriangleSelector* irr::scene::ISceneManager::createTriangleSelectorFromBoundingBox ( ISceneNode node)
pure virtual

Creates a simple dynamic ITriangleSelector, based on a axis aligned bounding box.

Triangle selectors can be used for doing collision detection. Every time when triangles are queried, the triangle selector gets the bounding box of the scene node, an creates new triangles. In this way, it works good with animated scene nodes.

Parameters
nodeScene node of which the bounding box, visibility and transformation is used.
Returns
The selector, or null if not successful. If you no longer need the selector, you should call ITriangleSelector::drop(). See IReferenceCounted::drop() for more information.

◆ drawAll()

virtual void irr::scene::ISceneManager::drawAll ( )
pure virtual

Draws all the scene nodes.

This can only be invoked between IVideoDriver::beginScene() and IVideoDriver::endScene(). Please note that the scene is not only drawn when calling this, but also animated by existing scene node animators, culling of scene nodes is done, etc.

◆ getActiveCamera()

virtual ICameraSceneNode* irr::scene::ISceneManager::getActiveCamera ( ) const
pure virtual

Get the current active camera.

Returns
The active camera is returned. Note that this can be NULL, if there was no camera created yet. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getAmbientLight()

virtual const video::SColorf& irr::scene::ISceneManager::getAmbientLight ( ) const
pure virtual

Get ambient color of the scene.

◆ getAnimatorTypeName()

virtual const c8* irr::scene::ISceneManager::getAnimatorTypeName ( ESCENE_NODE_ANIMATOR_TYPE  type)
pure virtual

Returns a typename from a scene node animator type or null if not found.

◆ getCurrentRenderPass()

virtual E_SCENE_NODE_RENDER_PASS irr::scene::ISceneManager::getCurrentRenderPass ( ) const
pure virtual

Get current render pass.

◆ getDefaultSceneNodeAnimatorFactory()

virtual ISceneNodeAnimatorFactory* irr::scene::ISceneManager::getDefaultSceneNodeAnimatorFactory ( )
pure virtual

Get the default scene node animator factory which can create all built-in scene node animators.

Returns
Pointer to the default scene node animator factory This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getDefaultSceneNodeFactory()

virtual ISceneNodeFactory* irr::scene::ISceneManager::getDefaultSceneNodeFactory ( )
pure virtual

Get the default scene node factory which can create all built in scene nodes.

Returns
Pointer to the default scene node factory This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getFileSystem()

virtual io::IFileSystem* irr::scene::ISceneManager::getFileSystem ( )
pure virtual

Get the active FileSystem.

Returns
Pointer to the FileSystem This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getGeometryCreator()

virtual const IGeometryCreator* irr::scene::ISceneManager::getGeometryCreator ( void  ) const
pure virtual

Get an instance of a geometry creator.

The geometry creator provides some helper methods to create various types of basic geometry. This can be useful for custom scene nodes.

◆ getGUIEnvironment()

virtual gui::IGUIEnvironment* irr::scene::ISceneManager::getGUIEnvironment ( )
pure virtual

Get the active GUIEnvironment.

Returns
Pointer to the GUIEnvironment This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getMesh() [1/2]

virtual IAnimatedMesh* irr::scene::ISceneManager::getMesh ( const io::path filename,
const io::path alternativeCacheName = io::path("") 
)
pure virtual

Get pointer to an animateable mesh. Loads the file if not loaded already.

If you want to remove a loaded mesh from the cache again, use removeMesh(). Currently there are the following mesh formats supported:

Format Description
3D Studio (.3ds) Loader for 3D-Studio files which lots of 3D packages are able to export. Only static meshes are currently supported by this importer.
3D World Studio (.smf) Loader for Leadwerks SMF mesh files, a simple mesh format containing static geometry for games. The proprietary .STF texture format is not supported yet. This loader was originally written by Joseph Ellis.
Bliz Basic B3D (.b3d) Loader for blitz basic files, developed by Mark Sibly. This is the ideal animated mesh format for game characters as it is both rigidly defined and widely supported by modeling and animation software. As this format supports skeletal animations, an ISkinnedMesh will be returned by this importer.
Cartography shop 4 (.csm) Cartography Shop is a modeling program for creating architecture and calculating lighting. Irrlicht can directly import .csm files thanks to the IrrCSM library created by Saurav Mohapatra which is now integrated directly in Irrlicht.
COLLADA (.dae, .xml)

COLLADA is an open Digital Asset Exchange Schema for the interactive 3D industry. There are exporters and importers for this format available for most of the big 3d packagesat http://collada.org. Irrlicht can import COLLADA files by using the ISceneManager::getMesh() method. COLLADA files need not contain only one single mesh but multiple meshes and a whole scene setup with lights, cameras and mesh instances, this loader can set up a scene as described by the COLLADA file instead of loading and returning one single mesh. By default, this loader behaves like the other loaders and does not create instances, but it can be switched into this mode by using SceneManager->getParameters()->setAttribute(COLLADA_CREATE_SCENE_INSTANCES, true); Created scene nodes will be named as the names of the nodes in the COLLADA file. The returned mesh is just a dummy object in this mode. Meshes included in the scene will be added into the scene manager with the following naming scheme: "path/to/file/file.dea#meshname". The loading of such meshes is logged. Currently, this loader is able to

   create meshes (made of only polygons), lights, and
   cameras. Materials and animations are currently not
   supported but this will change with future releases.
Delgine DeleD (.dmf) DeleD (delgine.com) is a 3D editor and level-editor combined into one and is specifically designed for 3D game-development. With this loader, it is possible to directly load all geometry is as well as textures and lightmaps from .dmf files. To set texture and material paths, see scene::DMF_USE_MATERIALS_DIRS. It is also possible to flip the alpha texture by setting scene::DMF_FLIP_ALPHA_TEXTURES to true and to set the material transparent reference value by setting scene::DMF_ALPHA_CHANNEL_REF to a float between 0 and
  1. The loader is based on Salvatore Russo's .dmf loader, I just changed some parts of it. Thanks to Salvatore for his work and for allowing me to use his code in Irrlicht and put it under Irrlicht's license. For newer and more enhanced versions of the loader, take a look at delgine.com.
DirectX (.x) Platform independent importer (so not D3D-only) for .x files. Most 3D packages can export these natively and there are several tools for them available, e.g. the Maya exporter included in the DX SDK. .x files can include skeletal animations and Irrlicht is able to play and display them, users can manipulate the joints via the ISkinnedMesh interface. Currently, Irrlicht only supports uncompressed .x files.
Half-Life model (.mdl) This loader opens Half-life 1 models, it was contributed by Fabio Concas and adapted by Thomas Alten.
Irrlicht Mesh (.irrMesh) This is a static mesh format written in XML, native to Irrlicht and written by the irr mesh writer. This format is exported by the CopperCube engine's lightmapper.
LightWave (.lwo) Native to NewTek's LightWave 3D, the LWO format is well known and supported by many exporters. This loader will import LWO2 models including lightmaps, bumpmaps and reflection textures.
Maya (.obj) Most 3D software can create .obj files which contain static geometry without material data. The material files .mtl are also supported. This importer for Irrlicht can load them directly.
Milkshape (.ms3d) .MS3D files contain models and sometimes skeletal animations from the Milkshape 3D modeling and animation software. Like the other skeletal mesh loaders, joints are exposed via the ISkinnedMesh animated mesh type.
My3D (.my3d) .my3D is a flexible 3D file format. The My3DTools contains plug-ins to export .my3D files from several 3D packages. With this built-in importer, Irrlicht can read and display those files directly. This loader was written by Zhuck Dimitry who also created the whole My3DTools package.
OCT (.oct) The oct file format contains 3D geometry and lightmaps and can be loaded directly by Irrlicht. OCT files
can be created by FSRad, Paul Nette's radiosity processor or exported from Blender using OCTTools which can be found in the exporters/OCTTools directory of the SDK. Thanks to Murphy McCauley for creating all this.
OGRE Meshes (.mesh) Ogre .mesh files contain 3D data for the OGRE 3D engine. Irrlicht can read and display them directly with this importer. To define materials for the mesh, copy a .material file named like the corresponding .mesh file where the .mesh file is. (For example ogrehead.material for ogrehead.mesh). Thanks to Christian Stehno who wrote and contributed this loader.
Pulsar LMTools (.lmts) LMTools is a set of tools (Windows & Linux) for creating lightmaps. Irrlicht can directly read .lmts files thanks to
the importer created by Jonas Petersen. Notes for
this version of the loader:
  • It does not recognize/support user data in the *.lmts files.
  • The TGAs generated by LMTools don't work in Irrlicht for some reason (the textures are upside down). Opening and resaving them in a graphics app will solve the problem.
Quake 3 levels (.bsp) Quake 3 is a popular game by IDSoftware, and .pk3 files contain .bsp files and textures/lightmaps describing huge prelighted levels. Irrlicht can read .pk3 and .bsp files directly and thus render Quake 3 levels directly. Written by Nikolaus Gebhardt enhanced by Dean P. Macri with the curved surfaces feature.
Quake 2 models (.md2) Quake 2 models are characters with morph target animation. Irrlicht can read, display and animate them directly with this importer.
Quake 3 models (.md3) Quake 3 models are characters with morph target animation, they contain mount points for weapons and body parts and are typically made of several sections which are manually joined together.
Stanford Triangle (.ply) Invented by Stanford University and known as the native format of the infamous "Stanford Bunny" model, this is a popular static mesh format used by 3D scanning hardware and software. This loader supports extremely large models in both ASCII and binary format, but only has rudimentary material support in the form of vertex colors and texture coordinates.
Stereolithography (.stl) The STL format is used for rapid prototyping and computer-aided manufacturing, thus has no support for materials.

To load and display a mesh quickly, just do this:

SceneManager->addAnimatedMeshSceneNode(
SceneManager->getMesh("yourmesh.3ds"));

If you would like to implement and add your own file format loader to Irrlicht, see addExternalMeshLoader().

Parameters
filenameFilename of the mesh to load.
alternativeCacheNameIn case you want to have the mesh under another name in the cache (to create real copies)
Returns
Null if failed, otherwise pointer to the mesh. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getMesh() [2/2]

virtual IAnimatedMesh* irr::scene::ISceneManager::getMesh ( io::IReadFile file)
pure virtual

Get pointer to an animateable mesh. Loads the file if not loaded already.

Works just as getMesh(const char* filename). If you want to remove a loaded mesh from the cache again, use removeMesh().

Parameters
fileFile handle of the mesh to load.
Returns
NULL if failed and pointer to the mesh if successful. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getMeshCache()

virtual IMeshCache* irr::scene::ISceneManager::getMeshCache ( )
pure virtual

Get interface to the mesh cache which is shared between all existing scene managers.

With this interface, it is possible to manually add new loaded meshes (if ISceneManager::getMesh() is not sufficient), to remove them and to iterate through already loaded meshes.

◆ getMeshLoader()

virtual IMeshLoader* irr::scene::ISceneManager::getMeshLoader ( u32  index) const
pure virtual

Retrieve the given mesh loader.

Parameters
indexThe index of the loader to retrieve. This parameter is an 0-based array index.
Returns
A pointer to the specified loader, 0 if the index is incorrect.

◆ getMeshLoaderCount()

virtual u32 irr::scene::ISceneManager::getMeshLoaderCount ( ) const
pure virtual

Returns the number of mesh loaders supported by Irrlicht at this time.

◆ getMeshManipulator()

virtual IMeshManipulator* irr::scene::ISceneManager::getMeshManipulator ( )
pure virtual

Get pointer to the mesh manipulator.

Returns
Pointer to the mesh manipulator This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getParameters()

virtual io::IAttributes* irr::scene::ISceneManager::getParameters ( )
pure virtual

Get interface to the parameters set in this scene.

String parameters can be used by plugins and mesh loaders. See COLLADA_CREATE_SCENE_INSTANCES and DMF_USE_MATERIALS_DIRS

◆ getRegisteredSceneNodeAnimatorFactoryCount()

virtual u32 irr::scene::ISceneManager::getRegisteredSceneNodeAnimatorFactoryCount ( ) const
pure virtual

Get amount of registered scene node animator factories.

◆ getRegisteredSceneNodeFactoryCount()

virtual u32 irr::scene::ISceneManager::getRegisteredSceneNodeFactoryCount ( ) const
pure virtual

Get amount of registered scene node factories.

◆ getRootSceneNode()

virtual ISceneNode* irr::scene::ISceneManager::getRootSceneNode ( )
pure virtual

Gets the root scene node.

This is the scene node which is parent of all scene nodes. The root scene node is a special scene node which only exists to manage all scene nodes. It will not be rendered and cannot be removed from the scene.

Returns
Pointer to the root scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getSceneCollisionManager()

virtual ISceneCollisionManager* irr::scene::ISceneManager::getSceneCollisionManager ( )
pure virtual

Get pointer to the scene collision manager.

Returns
Pointer to the collision manager This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getSceneLoader()

virtual ISceneLoader* irr::scene::ISceneManager::getSceneLoader ( u32  index) const
pure virtual

Retrieve the given scene loader.

Parameters
indexThe index of the loader to retrieve. This parameter is an 0-based array index.
Returns
A pointer to the specified loader, 0 if the index is incorrect.

◆ getSceneLoaderCount()

virtual u32 irr::scene::ISceneManager::getSceneLoaderCount ( ) const
pure virtual

Returns the number of scene loaders supported by Irrlicht at this time.

◆ getSceneNodeAnimatorFactory()

virtual ISceneNodeAnimatorFactory* irr::scene::ISceneManager::getSceneNodeAnimatorFactory ( u32  index)
pure virtual

Get scene node animator factory by index.

Returns
Pointer to the requested scene node animator factory, or 0 if it does not exist. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getSceneNodeFactory()

virtual ISceneNodeFactory* irr::scene::ISceneManager::getSceneNodeFactory ( u32  index)
pure virtual

Get a scene node factory by index.

Returns
Pointer to the requested scene node factory, or 0 if it does not exist. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getSceneNodeFromId()

virtual ISceneNode* irr::scene::ISceneManager::getSceneNodeFromId ( s32  id,
ISceneNode start = 0 
)
pure virtual

Get the first scene node with the specified id.

Parameters
idThe id to search for
startScene node to start from. All children of this scene node are searched. If null is specified, the root scene node is taken.
Returns
Pointer to the first scene node with this id, and null if no scene node could be found. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getSceneNodeFromName()

virtual ISceneNode* irr::scene::ISceneManager::getSceneNodeFromName ( const c8 name,
ISceneNode start = 0 
)
pure virtual

Get the first scene node with the specified name.

Parameters
nameThe name to search for
startScene node to start from. All children of this scene node are searched. If null is specified, the root scene node is taken.
Returns
Pointer to the first scene node with this id, and null if no scene node could be found. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getSceneNodeFromType()

virtual ISceneNode* irr::scene::ISceneManager::getSceneNodeFromType ( scene::ESCENE_NODE_TYPE  type,
ISceneNode start = 0 
)
pure virtual

Get the first scene node with the specified type.

Parameters
typeThe type to search for
startScene node to start from. All children of this scene node are searched. If null is specified, the root scene node is taken.
Returns
Pointer to the first scene node with this type, and null if no scene node could be found. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ getSceneNodeRenderPass()

virtual E_SCENE_NODE_RENDER_PASS irr::scene::ISceneManager::getSceneNodeRenderPass ( ) const
pure virtual

Get current render pass.

All scene nodes are being rendered in a specific order. First lights, cameras, sky boxes, solid geometry, and then transparent stuff. During the rendering process, scene nodes may want to know what the scene manager is rendering currently, because for example they registered for rendering twice, once for transparent geometry and once for solid. When knowing what rendering pass currently is active they can render the correct part of their geometry.

◆ getSceneNodesFromType()

virtual void irr::scene::ISceneManager::getSceneNodesFromType ( ESCENE_NODE_TYPE  type,
core::array< scene::ISceneNode * > &  outNodes,
ISceneNode start = 0 
)
pure virtual

Get scene nodes by type.

Parameters
typeType of scene node to find (ESNT_ANY will return all child nodes).
outNodesresults will be added to this array (outNodes is not cleared).
startScene node to start from. This node and all children of this scene node are checked (recursively, so also children of children, etc). If null is specified, the root scene node is taken as start-node.

◆ getSceneNodeTypeName()

virtual const c8* irr::scene::ISceneManager::getSceneNodeTypeName ( ESCENE_NODE_TYPE  type)
pure virtual

Get typename from a scene node type or null if not found.

◆ getShadowColor()

virtual video::SColor irr::scene::ISceneManager::getShadowColor ( ) const
pure virtual

Get the current color of shadows.

◆ getVideoDriver()

virtual video::IVideoDriver* irr::scene::ISceneManager::getVideoDriver ( )
pure virtual

Get the video driver.

Returns
Pointer to the video Driver. This pointer should not be dropped. See IReferenceCounted::drop() for more information.

◆ isCulled()

virtual bool irr::scene::ISceneManager::isCulled ( const ISceneNode node) const
pure virtual

Check if node is culled in current view frustum.

Please note that depending on the used culling method this check can be rather coarse, or slow. A positive result is correct, though, i.e. if this method returns true the node is positively not visible. The node might still be invisible even if this method returns false.

Parameters
nodeThe scene node which is checked for culling.
Returns
True if node is not visible in the current scene, else false.

◆ loadScene() [1/2]

virtual bool irr::scene::ISceneManager::loadScene ( const io::path filename,
ISceneUserDataSerializer userDataSerializer = 0,
ISceneNode rootNode = 0 
)
pure virtual

Loads a scene. Note that the current scene is not cleared before.

The scene is usually loaded from an .irr file, an xml based format, but other scene formats can be added to the engine via ISceneManager::addExternalSceneLoader. .irr files can Be edited with the Irrlicht Engine Editor, irrEdit (http://www.ambiera.com/irredit/) or saved directly by the engine using ISceneManager::saveScene().

Parameters
filenameName of the file to load from.
userDataSerializerIf you want to load user data possibily saved in that file for some scene nodes in the file, implement the ISceneUserDataSerializer interface and provide it as parameter here. Otherwise, simply specify 0 as this parameter.
rootNodeNode which is taken as the root node of the scene. Pass 0 to add the scene directly to the scene manager (which is also the default).
Returns
True if successful.

◆ loadScene() [2/2]

virtual bool irr::scene::ISceneManager::loadScene ( io::IReadFile file,
ISceneUserDataSerializer userDataSerializer = 0,
ISceneNode rootNode = 0 
)
pure virtual

Loads a scene. Note that the current scene is not cleared before.

The scene is usually loaded from an .irr file, an xml based format, but other scene formats can be added to the engine via ISceneManager::addExternalSceneLoader. .irr files can Be edited with the Irrlicht Engine Editor, irrEdit (http://www.ambiera.com/irredit/) or saved directly by the engine using ISceneManager::saveScene().

Parameters
fileFile where the scene is loaded from.
userDataSerializerIf you want to load user data saved in that file for some scene nodes in the file, implement the ISceneUserDataSerializer interface and provide it as parameter here. Otherwise, simply specify 0 as this parameter.
rootNodeNode which is taken as the root node of the scene. Pass 0 to add the scene directly to the scene manager (which is also the default).
Returns
True if successful.

◆ postEventFromUser()

virtual bool irr::scene::ISceneManager::postEventFromUser ( const SEvent event)
pure virtual

Posts an input event to the environment.

Usually you do not have to use this method, it is used by the internal engine.

◆ registerNodeForRendering()

virtual u32 irr::scene::ISceneManager::registerNodeForRendering ( ISceneNode node,
E_SCENE_NODE_RENDER_PASS  pass = ESNRP_AUTOMATIC 
)
pure virtual

Registers a node for rendering it at a specific time.

This method should only be used by SceneNodes when they get a ISceneNode::OnRegisterSceneNode() call.

Parameters
nodeNode to register for drawing. Usually scene nodes would set 'this' as parameter here because they want to be drawn.
passSpecifies when the node wants to be drawn in relation to the other nodes. For example, if the node is a shadow, it usually wants to be drawn after all other nodes and will use ESNRP_SHADOW for this. See scene::E_SCENE_NODE_RENDER_PASS for details.
Returns
scene will be rendered ( passed culling )

◆ registerSceneNodeAnimatorFactory()

virtual void irr::scene::ISceneManager::registerSceneNodeAnimatorFactory ( ISceneNodeAnimatorFactory factoryToAdd)
pure virtual

Adds a scene node animator factory to the scene manager.

Use this to extend the scene manager with new scene node animator types which it should be able to create automatically, for example when loading data from xml files.

◆ registerSceneNodeFactory()

virtual void irr::scene::ISceneManager::registerSceneNodeFactory ( ISceneNodeFactory factoryToAdd)
pure virtual

Adds a scene node factory to the scene manager.

Use this to extend the scene manager with new scene node types which it should be able to create automatically, for example when loading data from xml files.

◆ saveScene() [1/3]

virtual bool irr::scene::ISceneManager::saveScene ( const io::path filename,
ISceneUserDataSerializer userDataSerializer = 0,
ISceneNode node = 0 
)
pure virtual

Saves the current scene into a file.

Scene nodes with the option isDebugObject set to true are not being saved. The scene is usually written to an .irr file, an xml based format. .irr files can Be edited with the Irrlicht Engine Editor, irrEdit (http://www.ambiera.com/irredit/). To load .irr files again, see ISceneManager::loadScene().

Parameters
filenameName of the file.
userDataSerializerIf you want to save some user data for every scene node into the file, implement the ISceneUserDataSerializer interface and provide it as parameter here. Otherwise, simply specify 0 as this parameter.
nodeNode which is taken as the top node of the scene. This node and all of its descendants are saved into the scene file. Pass 0 or the scene manager to save the full scene (which is also the default).
Returns
True if successful.

◆ saveScene() [2/3]

virtual bool irr::scene::ISceneManager::saveScene ( io::IWriteFile file,
ISceneUserDataSerializer userDataSerializer = 0,
ISceneNode node = 0 
)
pure virtual

Saves the current scene into a file.

Scene nodes with the option isDebugObject set to true are not being saved. The scene is usually written to an .irr file, an xml based format. .irr files can Be edited with the Irrlicht Engine Editor, irrEdit (http://www.ambiera.com/irredit/). To load .irr files again, see ISceneManager::loadScene().

Parameters
fileFile where the scene is saved into.
userDataSerializerIf you want to save some user data for every scene node into the file, implement the ISceneUserDataSerializer interface and provide it as parameter here. Otherwise, simply specify 0 as this parameter.
nodeNode which is taken as the top node of the scene. This node and all of its descendants are saved into the scene file. Pass 0 or the scene manager to save the full scene (which is also the default).
Returns
True if successful.

◆ saveScene() [3/3]

virtual bool irr::scene::ISceneManager::saveScene ( io::IXMLWriter writer,
const io::path currentPath,
ISceneUserDataSerializer userDataSerializer = 0,
ISceneNode node = 0 
)
pure virtual

Saves the current scene into a file.

Scene nodes with the option isDebugObject set to true are not being saved. The scene is usually written to an .irr file, an xml based format. .irr files can Be edited with the Irrlicht Engine Editor, irrEdit (http://www.ambiera.com/irredit/). To load .irr files again, see ISceneManager::loadScene().

Parameters
writerXMLWriter with which the scene is saved.
currentPathPath which is used for relative file names. Usually the directory of the file written into.
userDataSerializerIf you want to save some user data for every scene node into the file, implement the ISceneUserDataSerializer interface and provide it as parameter here. Otherwise, simply specify 0 as this parameter.
nodeNode which is taken as the top node of the scene. This node and all of its descendants are saved into the scene file. Pass 0 or the scene manager to save the full scene (which is also the default).
Returns
True if successful.

◆ setActiveCamera()

virtual void irr::scene::ISceneManager::setActiveCamera ( ICameraSceneNode camera)
pure virtual

Sets the currently active camera.

The previous active camera will be deactivated.

Parameters
cameraThe new camera which should be active.

◆ setAmbientLight()

virtual void irr::scene::ISceneManager::setAmbientLight ( const video::SColorf ambientColor)
pure virtual

Sets ambient color of the scene.

◆ setCurrentRenderPass()

virtual void irr::scene::ISceneManager::setCurrentRenderPass ( E_SCENE_NODE_RENDER_PASS  nextPass)
pure virtual

Set current render pass.

◆ setLightManager()

virtual void irr::scene::ISceneManager::setLightManager ( ILightManager lightManager)
pure virtual

Register a custom callbacks manager which gets callbacks during scene rendering.

Parameters
[in]lightManagerthe new callbacks manager. You may pass 0 to remove the current callbacks manager and restore the default behavior.

◆ setShadowColor()

virtual void irr::scene::ISceneManager::setShadowColor ( video::SColor  color = video::SColor(150, 0, 0, 0))
pure virtual

Sets the color of stencil buffers shadows drawn by the scene manager.


The documentation for this class was generated from the following file: