29 #ifndef TRIMESH_LOADER_H 30 #define TRIMESH_LOADER_H 39 #ifndef TRIMESH_LOADER_EXPORT 40 #define TRIMESH_LOADER_API 42 #define TRIMESH_LOADER_API extern 71 #define TL_FVF_NORMAL 4 80 float ambient[4], diffuse[4], specular[4];
TRIMESH_LOADER_API tlTrimesh * tlCreateTrimeshFromObjState(tlObjState *state, unsigned int vertex_format)
Create an a tlTrimesh structure from a tlObjState.
Structure describing a Material (Colors and/or Texture)
Definition: trimeshloader.h:74
unsigned short * faces
pointer to the face (triangle) indices (3 unsigned shorts)
Definition: trimeshloader.h:117
unsigned int vertex_size
size/stride of each vertex, in bytes
Definition: trimeshloader.h:114
unsigned int material_count
number of materials
Definition: trimeshloader.h:132
unsigned int object_count
number of objects
Definition: trimeshloader.h:126
char * name
Name of the Object.
Definition: trimeshloader.h:54
Structure describing an Object (or SubMesh, Batch)
Definition: trimeshloader.h:51
TRIMESH_LOADER_API tlTrimesh * tlLoad3DS(const char *filename, unsigned int vertex_format)
Load a 3DS file in an tlTrimesh structure.
Trimeshloader OBJ parser public header file.
unsigned int vertex_count
number of vertices
Definition: trimeshloader.h:108
Structure describing an Trimesh (index triangle list) containing objects, vertices (point...
Definition: trimeshloader.h:102
float shininess
Shininess.
Definition: trimeshloader.h:83
unsigned int face_index
First face in the index list.
Definition: trimeshloader.h:94
tlObject * objects
list of objects in this trimesh
Definition: trimeshloader.h:123
float * vertices
pointer to the vertex data
Definition: trimeshloader.h:105
struct tlObjState tlObjState
Definition: tlobj.h:46
tlMaterial * materials
list of materials in this trimesh
Definition: trimeshloader.h:129
TRIMESH_LOADER_API void tlTrimeshCreateNormals(tlTrimesh *trimesh)
struct tl3dsState tl3dsState
Structure describing the parsing state.
Definition: tl3ds.h:47
#define TRIMESH_LOADER_API
Definition: trimeshloader.h:40
TRIMESH_LOADER_API tlTrimesh * tlLoadOBJ(const char *filename, unsigned int vertex_format)
Load a OBJ file in an tlTrimesh structure.
char * name
Name of the Material.
Definition: trimeshloader.h:77
TRIMESH_LOADER_API tlTrimesh * tlLoadTrimesh(const char *filename, unsigned int vertex_format)
Load an 3DS or OBJ file in an tlTrimesh structure.
unsigned int face_count
number of faces
Definition: trimeshloader.h:120
tlMaterialReference * material_references
list of references to materials in this trimesh
Definition: trimeshloader.h:135
TRIMESH_LOADER_API void tlDeleteTrimesh(tlTrimesh *trimesh)
Delete an previously loaded tlTrimesh object.
unsigned int face_count
Face count.
Definition: trimeshloader.h:97
unsigned int face_index
First face in the index list.
Definition: trimeshloader.h:57
Structure describing the reference to a Material.
Definition: trimeshloader.h:88
Trimeshloader 3DS parser public header file.
TRIMESH_LOADER_API tlTrimesh * tlCreateTrimeshFrom3dsState(tl3dsState *state, unsigned int vertex_format)
Create an a tlTrimesh structure from a tl3dsState.
unsigned int material_reference_count
number of references to materials
Definition: trimeshloader.h:138
unsigned int vertex_format
format of the vertices
Definition: trimeshloader.h:111
char * name
Name of the Material.
Definition: trimeshloader.h:91
unsigned int face_count
Face count.
Definition: trimeshloader.h:60