mirror of
https://notabug.org/scuti/lib3ddevil1
synced 2026-06-09 03:43:17 +05:30
Added for loop to accomodate cases with multiple batches
This commit is contained in:
+8
-5
@@ -115,15 +115,18 @@ void extractmeshes(const char *filedata,
|
||||
struct MeshHeader *mh = NULL;
|
||||
struct Batch *b = NULL;
|
||||
unsigned int i;
|
||||
unsigned int j;
|
||||
bool ok;
|
||||
//h -> numMesh
|
||||
for (i = 1; i < 2; i++) {
|
||||
for (i = 0; i < 2; i++) {
|
||||
ok = getmeshheader(&mh, i, filedata);
|
||||
if (ok) {
|
||||
getmeshbatch(&b, mh, filedata);
|
||||
printmeshbatch(b);
|
||||
}
|
||||
}
|
||||
for (j = 0; j < mh -> numBatch; j++) {
|
||||
getmeshbatch(&b, mh, filedata);
|
||||
printmeshbatch(b);
|
||||
} // end for
|
||||
} // end if
|
||||
} // end for
|
||||
}
|
||||
|
||||
int main(int argc, char ** argv) {
|
||||
|
||||
Reference in New Issue
Block a user