mirror of
https://notabug.org/scuti/lib3ddevil1
synced 2025-05-31 14:11:42 +05:30
Added getmesh function
This commit is contained in:
@@ -52,7 +52,7 @@ struct BatchData {
|
||||
};
|
||||
|
||||
struct VertexData {
|
||||
// following structs should in an array of size numVertex
|
||||
// following structs should in an array of size 'numVertex'
|
||||
struct Coordinate *positions;
|
||||
struct Coordinate *normals;
|
||||
struct UVs *u;
|
||||
@@ -60,15 +60,13 @@ struct VertexData {
|
||||
struct BoneWeights *bw;
|
||||
};
|
||||
|
||||
// This is where most of the parsing will be.
|
||||
// this struct is in-order of what the file format will have.
|
||||
struct Batch {
|
||||
struct BatchData *bd;
|
||||
struct VertexData vd;
|
||||
struct BatchData *bd; // pointer to region in file data
|
||||
struct VertexData vd; // collection of pointers to regions in file data
|
||||
};
|
||||
|
||||
struct Mesh {
|
||||
// may contain multiple batches
|
||||
// array of batches
|
||||
struct Batch *b;
|
||||
};
|
||||
|
||||
@@ -85,10 +83,9 @@ void printcoordinate(struct Coordinate*, unsigned int);
|
||||
// ** = 'pass by reference' of a pointer to struct
|
||||
bool getmeshheader(struct MeshHeader**, unsigned int i, const char * const);
|
||||
|
||||
// ** = 'pass by reference' of a pointer to struct
|
||||
bool getmeshbatch(struct Batch*,
|
||||
unsigned int offset,
|
||||
const char * const);
|
||||
bool getmeshbatch(struct Batch*, unsigned int offset, const char * const);
|
||||
|
||||
bool getmesh(struct Mesh*, unsigned int i, const char* filename);
|
||||
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user