You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
typedef struct ilG_drawable3d {
const char* name;
unsigned int id;
ilG_drawable3d_cb draw;
ilG_drawable3d_bind_cb bind, unbind;
ilG_drawable3d_update_cb update;
void *draw_ctx, *bind_ctx, *unbind_ctx, *update_ctx;
unsigned long long attrs;
} ilG_drawable3d;
A drawable roughly corresponds to one mesh file. There should only ever be one per mesh file, even though an arbitrarily large combination of mesh/material/texture/positionables can be made. There is a one-to-many relationship between drawables and positionables.
Functions
ilG_drawable3d* ilG_drawable3d_fromId(unsigned int id);
Takes a given drawable ID and returns a pointer to the actual struct.
void ilG_drawable3d_assignId(ilG_drawable3d*);
Assigns a drawable an ID.
void ilG_drawable3d_setId(ilG_drawable3d*, unsigned int id);