SuperTuxKart
Loading...
Searching...
No Matches
Classes | Public Member Functions | Static Public Attributes | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
B3DMeshLoader Class Reference
Inheritance diagram for B3DMeshLoader:
Inheritance graph
[legend]

Classes

class  JointInfluence
 
struct  SB3dChunk
 
struct  SB3dChunkHeader
 
struct  SB3dMaterial
 
struct  SB3dTexture
 

Public Member Functions

 B3DMeshLoader (scene::ISceneManager *smgr)
 Constructor.
 
virtual bool isALoadableFileExtension (const io::path &filename) const
 returns true if the file maybe is able to be loaded by this class based on the file extension (e.g.
 
virtual scene::IAnimatedMesh * createMesh (io::IReadFile *file)
 creates/loads an animated mesh from the file.
 

Static Public Attributes

static int m_straight_frame = 0
 

Private Types

typedef core::array< core::array< core::array< JointInfluence > > > WeightInfluence
 

Private Member Functions

SP::SPMeshtoSPM (scene::CSkinnedMesh *mesh)
 
void computeWeightInfluence (scene::CSkinnedMesh::SJoint *joint, unsigned &index, WeightInfluence &wi)
 
void addSPAnimation (SP::SPMesh *spm, scene::CSkinnedMesh::SJoint *joint, unsigned &index, unsigned frame)
 
bool load ()
 
bool readChunkNODE (scene::CSkinnedMesh::SJoint *InJoint)
 
bool readChunkMESH (scene::CSkinnedMesh::SJoint *InJoint)
 
bool readChunkVRTS (scene::CSkinnedMesh::SJoint *InJoint)
 
bool readChunkTRIS (scene::SSkinMeshBuffer *MeshBuffer, u32 MeshBufferID, s32 Vertices_Start)
 
bool readChunkBONE (scene::CSkinnedMesh::SJoint *InJoint)
 
bool readChunkKEYS (scene::CSkinnedMesh::SJoint *InJoint)
 
bool readChunkANIM ()
 
bool readChunkTEXS ()
 
bool readChunkBRUS ()
 
void loadTextures (SB3dMaterial &material, scene::IMeshBuffer *mb)
 
void readString (core::stringc &newstring)
 
void readFloats (f32 *vec, u32 count)
 

Static Private Member Functions

static bool sortJointInfluenceFunc (const JointInfluence &a, const JointInfluence &b)
 

Private Attributes

std::unordered_map< scene::IMeshBuffer *, std::pair< std::string, std::string > > m_texture_string
 
core::array< SB3dChunkB3dStack
 
core::array< SB3dMaterialMaterials
 
core::array< SB3dTextureTextures
 
core::array< s32 > AnimatedVertices_VertexID
 
core::array< s32 > AnimatedVertices_BufferID
 
core::array< video::S3DVertex2TCoords > BaseVertices
 
scene::ISceneManager * SceneManager
 
scene::CSkinnedMesh * AnimatedMesh
 
io::IReadFile * B3DFile
 
u32 VerticesStart
 
bool NormalsInFile
 
bool HasVertexColors
 
bool ShowWarning
 

Member Function Documentation

◆ createMesh()

scene::IAnimatedMesh * B3DMeshLoader::createMesh ( io::IReadFile *  f)
virtual

creates/loads an animated mesh from the file.

Returns
Pointer to the created mesh. Returns 0 if loading failed. If you no longer need the mesh, you should call IAnimatedMesh::drop(). See IReferenceCounted::drop() for more information.

◆ isALoadableFileExtension()

bool B3DMeshLoader::isALoadableFileExtension ( const io::path &  filename) const
virtual

returns true if the file maybe is able to be loaded by this class based on the file extension (e.g.

".bsp")


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