mirror of
https://notabug.org/scuti/lib3ddevil1
synced 2025-05-31 14:11:42 +05:30
Added function to get mesh headers
This commit is contained in:
@@ -2,7 +2,10 @@
|
||||
#ifndef DEVIL1GEO_H
|
||||
#define DEVIL1GEO_H
|
||||
#include <stdint.h>
|
||||
#pragma pack(1)
|
||||
#include <stdbool.h>
|
||||
|
||||
|
||||
#pragma pack(push, 1)
|
||||
struct Header {
|
||||
unsigned char numMesh;
|
||||
unsigned char unknownNumberB;
|
||||
@@ -12,7 +15,7 @@ struct Header {
|
||||
uint64_t unknownOffset;
|
||||
};
|
||||
|
||||
struct MeshHeaders {
|
||||
struct MeshHeader {
|
||||
int16_t numBatch;
|
||||
int16_t numVertex;
|
||||
uint32_t u; // <format=hex>
|
||||
@@ -39,6 +42,7 @@ struct BoneIndexes {
|
||||
struct BoneWeights {
|
||||
uint16_t weights; // <format=hex>
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
// This is where most of the parsing will be.
|
||||
// this struct is in-order of what the file format will have.
|
||||
@@ -65,5 +69,9 @@ struct Mesh {
|
||||
struct Batch b;
|
||||
};
|
||||
|
||||
void printgheader(struct Header*);
|
||||
|
||||
bool getmeshheaders(struct MeshHeader **, const char *, unsigned int);
|
||||
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user