Implemented correct initialization of batch and positions array

This commit is contained in:
_
2018-04-07 19:37:43 -07:00
parent cc31734e44
commit fb962d2ffe
3 changed files with 61 additions and 4 deletions

View File

@@ -56,7 +56,6 @@ struct Batch {
uint64_t offsetBoneIndexes; // <format=hex>
uint64_t offsetBoneWeights; // <format=hex>
uint64_t offsets[1]; // <format=hex>
int64_t pos; // set while parsing batch from ftell();
// following structs should in an array of size numVertex
struct Positions *p;
struct Normals *n;
@@ -73,7 +72,17 @@ void printgheader(struct Header*);
void printmeshheader(struct MeshHeader*);
void printmeshbatch(struct Batch*);
void printpositions(struct Positions*, 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**,
struct MeshHeader*,
const char * const);
#endif