5#ifndef __I_MESH_CACHE_H_INCLUDED__
6#define __I_MESH_CACHE_H_INCLUDED__
18 class IAnimatedMeshSceneNode;
Base class of most objects of the Irrlicht Engine.
Interface for an animated mesh.
The mesh cache stores already loaded meshes and provides an interface to them.
_IRR_DEPRECATED_ IAnimatedMesh * getMeshByFilename(const io::path &filename)
Returns a mesh based on its name (often a filename).
virtual void addMesh(const io::path &name, IAnimatedMesh *mesh)=0
Adds a mesh to the internal list of loaded meshes.
virtual s32 getMeshIndex(const IMesh *const mesh) const =0
Returns current index number of the mesh or -1 when not found.
virtual bool isMeshLoaded(const io::path &name)=0
Check if a mesh was already loaded.
virtual bool renameMesh(const IMesh *const mesh, const io::path &name)=0
Renames the loaded mesh.
_IRR_DEPRECATED_ bool setMeshFilename(u32 index, const io::path &filename)
Renames a loaded mesh.
virtual IAnimatedMesh * getMeshByIndex(u32 index)=0
Returns a mesh based on its index number.
virtual ~IMeshCache()
Destructor.
_IRR_DEPRECATED_ const io::path & getMeshFilename(u32 index) const
Get the name of a loaded mesh, based on its index. (Name is often identical to the filename).
virtual bool renameMesh(u32 index, const io::path &name)=0
Renames a loaded mesh.
_IRR_DEPRECATED_ const io::path & getMeshFilename(const IMesh *const mesh) const
Get the name of a loaded mesh, if there is any. (Name is often identical to the filename).
_IRR_DEPRECATED_ bool setMeshFilename(const IMesh *const mesh, const io::path &filename)
Renames a loaded mesh.
virtual u32 getMeshCount() const =0
Returns amount of loaded meshes in the cache.
virtual void clearUnusedMeshes()=0
Clears all meshes that are held in the mesh cache but not used anywhere else.
virtual void removeMesh(const IMesh *const mesh)=0
Removes the mesh from the cache.
virtual const io::SNamedPath & getMeshName(u32 index) const =0
Get the name of a loaded mesh, based on its index.
virtual IAnimatedMesh * getMeshByName(const io::path &name)=0
Returns a mesh based on its name.
virtual void clear()=0
Clears the whole mesh cache, removing all meshes.
virtual const io::SNamedPath & getMeshName(const IMesh *const mesh) const =0
Get the name of the loaded mesh if there is any.
Class which holds the geometry of an object.
#define _IRR_DEPRECATED_
Defines a deprecated macro which generates a warning at compile time.
Everything in the Irrlicht Engine can be found in this namespace.
unsigned int u32
32 bit unsigned variable.
signed int s32
32 bit signed variable.
Used in places where we identify objects by a filename, but don't actually work with the real filenam...
const path & getInternalName() const