kyle-emmerich / blueshift-engine

High performance C++ game engine in early development

Home Page:https://noxastra.com/engine

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Loading BBM format

kyle-emmerich opened this issue · comments

The Blueshift Binary Model format is a simple 3D model format that is designed for minimal runtime processing in order to maximize performance. As such, it may be sent to the GPU almost straight from storage.

The format will begin with a "magic" combination of four bytes:

'B', 'B', 'M', 0x0

The last byte denotes the revision number; the format is not expected to be compatible across revisions as it is compiled from other formats.

After the magic header, the info header will follow. It will be a simple structure, defined as follows:

struct BBMHeader {
    uint64_t SizeInBytes;
    uint16_t NumGroups;
    uint8_t Flags;
};

One may infer that there are more information structures following this one. However, for the sake of brevity, please see the code to see their definitions.

Changing to a more general approach. Stay tuned.