mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
* Fix attachments lagging behind their parents (#14818) * Fix animation blending (#14817) * Bring back cool guy as another .x smoke test * Add .x mesh loader unittest * Do bounding box & matrix calculation at proper point in time * Remove obsolete `SAnimatedMesh`
42 lines
1.3 KiB
C++
42 lines
1.3 KiB
C++
// Copyright (C) 2002-2012 Nikolaus Gebhardt
|
|
// This file is part of the "Irrlicht Engine".
|
|
// For conditions of distribution and use, see copyright notice in irrlicht.h
|
|
|
|
#pragma once
|
|
|
|
#include "IMesh.h"
|
|
|
|
namespace irr
|
|
{
|
|
namespace scene
|
|
{
|
|
//! Interface for an animated mesh.
|
|
/** There are already simple implementations of this interface available so
|
|
you don't have to implement this interface on your own if you need to:
|
|
You might want to use irr::scene::SMesh, irr::scene::SMeshBuffer etc.
|
|
*/
|
|
class IAnimatedMesh : public IMesh
|
|
{
|
|
public:
|
|
//! Gets the maximum frame number, 0 if the mesh is static.
|
|
virtual f32 getMaxFrameNumber() const = 0;
|
|
|
|
//! Gets the animation speed of the animated mesh.
|
|
/** \return The number of frames per second to play the
|
|
animation with by default. If the amount is 0,
|
|
it is a static, non animated mesh. */
|
|
virtual f32 getAnimationSpeed() const = 0;
|
|
|
|
//! Sets the animation speed of the animated mesh.
|
|
/** \param fps Number of frames per second to play the
|
|
animation with by default. If the amount is 0,
|
|
it is not animated. The actual speed is set in the
|
|
scene node the mesh is instantiated in.*/
|
|
virtual void setAnimationSpeed(f32 fps) = 0;
|
|
|
|
//! Returns the type of the animated mesh. Useful for safe downcasts.
|
|
E_ANIMATED_MESH_TYPE getMeshType() const = 0;
|
|
};
|
|
|
|
} // end namespace scene
|
|
} // end namespace irr
|