Lightmetrica  0.0.1.50dbee3 (yosakoi)
 All Classes Functions Variables Typedefs Enumerations Enumerator
Public Member Functions | List of all members
ObjMesh Class Referencefinal

Public Member Functions

 LM_COMPONENT_IMPL_DEF ("obj")
 
virtual bool Load (const ConfigNode &node, const Assets &assets) override
 
virtual int NumVertices () const override
 
virtual int NumFaces () const override
 
virtual const Math::Float * Positions () const override
 
virtual const Math::Float * Normals () const override
 
virtual const Math::Float * TexCoords () const override
 
virtual const unsigned int * Faces () const override
 
- Public Member Functions inherited from TriangleMesh
 LM_ASSET_INTERFACE_DEF ("triangle_mesh","triangle_meshes")
 
 LM_ASSET_NO_DEPENDENCIES ()
 
- Public Member Functions inherited from Asset
LM_PUBLIC_API std::string ID () const
 
LM_HIDDEN_API void SetID (const std::string &id)
 
- Public Member Functions inherited from Component
virtual std::string ComponentInterfaceTypeName () const =0
 
virtual std::string ComponentImplTypeName () const =0
 
- Public Member Functions inherited from SIMDAlignedType
void * operator new (std::size_t size) throw (std::bad_alloc)
 
void operator delete (void *p)
 

Detailed Description

Obj mesh. Triangle mesh implementation for Wavefront obj files. The class partially supports the specification of the Wavefront obj files.

Inheritance diagram for ObjMesh:
TriangleMesh Asset Component SIMDAlignedType

Member Function Documentation

virtual const unsigned int* ObjMesh::Faces ( ) const
inlineoverridevirtual

Get the face array.

Returns
The face array.

Implements TriangleMesh.

bool ObjMesh::Load ( const ConfigNode node,
const Assets assets 
)
overridevirtual

Load an asset. Configure and initialize the asset by the XML elements given by #node. Some assets have references to the other assets, so #assets is also required. Dependent asset must be loaded beforehand.

Parameters
nodeXML node for the configuration.
assetsAsset manager.
trueSucceeded to load.
falseFailed to load.

Implements Asset.

virtual const Math::Float* ObjMesh::Normals ( ) const
inlineoverridevirtual

Get the normal array.

Returns
The normal array.

Implements TriangleMesh.

virtual int ObjMesh::NumFaces ( ) const
inlineoverridevirtual

Get the number of faces.

Returns
The number of faces.

Implements TriangleMesh.

virtual int ObjMesh::NumVertices ( ) const
inlineoverridevirtual

Get the number of vertices.

Returns
The number of vertices.

Implements TriangleMesh.

virtual const Math::Float* ObjMesh::Positions ( ) const
inlineoverridevirtual

Get the position array.

Returns
The position array.

Implements TriangleMesh.

virtual const Math::Float* ObjMesh::TexCoords ( ) const
inlineoverridevirtual

Get the texture coordinates array.

Returns
The texture coordinates array.

Implements TriangleMesh.


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