Skip to content
modkitv0.2

model.h

#include <modkit/model.h>72 functions · 6 structs · 1 enums · 8 typedefs · 19 macros

Model loading package glTF/GLB files into drawable geometry.

An OPT-IN package (MODKIT_ENABLE_MODEL, default OFF). It is a pure helper over the spine: a loaded model is just a list of (geometry + material + node-transform) draw items, submitted through mk_pass_draw. It owns no pass machinery and adds no rendering technique shading is the scene-lite lit/unlit material by default; when the pbr package is enabled it builds PBR materials without changing the draw path. mk_model_t m = mk_model_load("assets/duck.glb", 0); ... mk_begin_pass(&mk_pass_3d(clear, view, proj)); mk_model_draw(m, world_mtx); // submits every primitive into the pass mk_end_pass(); ... mk_model_destroy(m); When the package is disabled (MODKIT_HAS_MODEL == 0) these symbols still link via a no-op stub: mk_model_load returns MK_MODEL_INVALID. Supported now: glTF/GLB, external buffers + textures, node transforms, extracted primitive meshes, extracted material slots, animation clips, scene-graph animation, skeletal skinning, and morph targets. OBJ/FBX importers are available through the optional assimp add-on.

Functions

mk_model_aabbfunction

mk_aabb mk_model_aabb(mk_model_t model)

Local-space axis-aligned bounds over all primitives (node transforms applied,.

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value. model transform NOT applied). Zero AABB if the model is invalid/empty.

mk_model_animation_countfunction

uint32_t mk_model_animation_count(mk_model_t model)

Number of animation clips in the model.

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value.

mk_model_animation_durationfunction

float mk_model_animation_duration(mk_model_t model, uint32_t index)

Animation duration in seconds, or 0 when index is out of range.

ParameterTypeDescription
modelmk_model_tValue for model.
indexuint32_tZero-based index.

Returns The resulting value.

mk_model_animation_event_addfunction

bool mk_model_animation_event_add(mk_model_t model, uint32_t animation, float time_sec, const char *name, int32_t payload)

Add model animation event.

ParameterTypeDescription
modelmk_model_tValue for model.
animationuint32_tValue for animation.
time_secfloatValue for time sec.
nameconst char *Stable name.
payloadint32_tValue for payload.

Returns True when the operation succeeds.

mk_model_animation_event_countfunction

uint32_t mk_model_animation_event_count(mk_model_t model, uint32_t animation)

Perform the model animation event count operation.

ParameterTypeDescription
modelmk_model_tValue for model.
animationuint32_tValue for animation.

Returns The resulting value.

mk_model_animation_event_getfunction

bool mk_model_animation_event_get(mk_model_t model, uint32_t animation, uint32_t index, mk_model_animation_marker_t *out)

Get state from the model animation event.

ParameterTypeDescription
modelmk_model_tValue for model.
animationuint32_tValue for animation.
indexuint32_tZero-based index.
outmk_model_animation_marker_t *Value for out.

Returns True when the operation succeeds.

mk_model_animation_events_clearfunction

void mk_model_animation_events_clear(mk_model_t model, uint32_t animation)

Clear the model animation events.

ParameterTypeDescription
modelmk_model_tValue for model.
animationuint32_tValue for animation.

mk_model_animation_findfunction

int32_t mk_model_animation_find(mk_model_t model, const char *name)

Find an animation by name.

ParameterTypeDescription
modelmk_model_tValue for model.
nameconst char *Stable name.

Returns The resulting value.

mk_model_animation_namefunction

const char * mk_model_animation_name(mk_model_t model, uint32_t index)

Animation display name, or NULL when index is out of range.

ParameterTypeDescription
modelmk_model_tValue for model.
indexuint32_tZero-based index.

Returns A borrowed pointer, or NULL when unavailable.

mk_model_copy_lightsfunction

uint32_t mk_model_copy_lights(mk_model_t model, const float transform[16], mk_light_desc *out, uint32_t capacity)

Copy lights for the model.

ParameterTypeDescription
modelmk_model_tValue for model.
transformconst floatValue for transform.
outmk_light_desc *Value for out.
capacityuint32_tValue for capacity.

Returns The resulting value.

mk_model_destroyfunction

void mk_model_destroy(mk_model_t model)

Immediately invalidate a model; its GPU-owned contents retire after queued frames complete.

ParameterTypeDescription
modelmk_model_tValue for model.

mk_model_drawfunction

void mk_model_draw(mk_model_t model, const float transform[16])

Submit every primitive of the model into the active pass.

transform is the model's world matrix (column-major 4x4, NULL => identity); each primitive is

ParameterTypeDescription
modelmk_model_tValue for model.
transformconst floatValue for transform. drawn at transform * node_world. Call between mk_begin_pass/mk_end_pass.

mk_model_draw_exfunction

void mk_model_draw_ex(mk_model_t model, const float transform[16], uint32_t filter)

Like mk_model_draw but only the primitive categories in filter (a bitmask of MK_MODEL_DRAW_*).

Drawn opaque -> transmissive -> blend so they composite correctly. Use MK_MODEL_DRAW_OPAQUE for a transmission-capture pass (exclude the refractive

ParameterTypeDescription
modelmk_model_tValue for model.
transformconst floatValue for transform.
filteruint32_tValue for filter. prims so glass doesn't refract itself). mk_model_draw == filter MK_MODEL_DRAW_ALL.

mk_model_draw_transmissive_layerfunction

void mk_model_draw_transmissive_layer(mk_model_t model, const float transform[16], const float view_mtx[16], uint32_t layer)

Draw one transmissive primitive, sorted back-to-front for the supplied view matrix.

layer is 0-based, where 0 is the farthest transmissive primitive from the camera. This is intentionally narrow: normal model drawing still goes through mk_model_draw().

ParameterTypeDescription
modelmk_model_tValue for model.
transformconst floatValue for transform.
view_mtxconst floatValue for view mtx.
layeruint32_tValue for layer.

mk_model_instance_aabbfunction

mk_aabb mk_model_instance_aabb(mk_model_instance_t instance)

Current local-space bounds for the posed instance.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

Returns The resulting value.

mk_model_instance_action_clear_maskfunction

void mk_model_instance_action_clear_mask(mk_model_instance_t instance, mk_model_action_t action)

Restore full TRS influence for the action.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.

mk_model_instance_action_fade_tofunction

void mk_model_instance_action_fade_to(mk_model_instance_t instance, mk_model_action_t action, float target_weight, float duration_sec)

Linearly animate the current action weight to target_weight.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.
target_weightfloatValue for target weight.
duration_secfloatValue for duration sec.

mk_model_instance_action_is_playingfunction

bool mk_model_instance_action_is_playing(mk_model_instance_t instance, mk_model_action_t action)

Test whether the model instance action is playing.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.

Returns True when the condition holds.

mk_model_instance_action_is_validfunction

bool mk_model_instance_action_is_valid(mk_model_instance_t instance, mk_model_action_t action)

Test whether the model instance action is valid.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.

Returns True when the condition holds.

mk_model_instance_action_playfunction

mk_model_action_t mk_model_instance_action_play(mk_model_instance_t instance, uint32_t animation, uint32_t flags)

Start an independently controlled animation action at time zero, speed 1, and weight 1.

Use MK_MODEL_PLAY_ADDITIVE to apply its rest-pose delta after

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
animationuint32_tValue for animation.
flagsuint32_tValue for flags.

Returns The resulting handle or value. normal blending. Returns MK_MODEL_ACTION_INVALID when no slot is available.

mk_model_instance_action_removefunction

void mk_model_instance_action_remove(mk_model_instance_t instance, mk_model_action_t action)

Remove model instance action.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.

mk_model_instance_action_set_maskfunction

bool mk_model_instance_action_set_mask(mk_model_instance_t instance, mk_model_action_t action, mk_model_mask_t mask)

Copy a reusable mask onto an action.

Returns false for invalid handles or a

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.
maskmk_model_mask_tValue for mask.

Returns True when the operation succeeds. mask created for another model.

mk_model_instance_action_set_playingfunction

void mk_model_instance_action_set_playing(mk_model_instance_t instance, mk_model_action_t action, bool playing)

Set playing on the model instance action.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.
playingboolValue for playing.

mk_model_instance_action_set_speedfunction

void mk_model_instance_action_set_speed(mk_model_instance_t instance, mk_model_action_t action, float speed)

Set speed on the model instance action.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.
speedfloatValue for speed.

mk_model_instance_action_set_timefunction

void mk_model_instance_action_set_time(mk_model_instance_t instance, mk_model_action_t action, float time_sec)

Set time on the model instance action.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.
time_secfloatValue for time sec.

mk_model_instance_action_set_weightfunction

void mk_model_instance_action_set_weight(mk_model_instance_t instance, mk_model_action_t action, float weight)

Set weight on the model instance action.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.
weightfloatValue for weight.

mk_model_instance_action_speedfunction

float mk_model_instance_action_speed(mk_model_instance_t instance, mk_model_action_t action)

Perform the model instance action speed operation.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.

Returns The resulting value.

mk_model_instance_action_timefunction

float mk_model_instance_action_time(mk_model_instance_t instance, mk_model_action_t action)

Perform the model instance action time operation.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.

Returns The resulting value.

mk_model_instance_action_weightfunction

float mk_model_instance_action_weight(mk_model_instance_t instance, mk_model_action_t action)

Perform the model instance action weight operation.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
actionmk_model_action_tValue for action.

Returns The resulting value.

mk_model_instance_clear_animation_eventsfunction

void mk_model_instance_clear_animation_events(mk_model_instance_t instance)

Clear the animation events for the model instance.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

mk_model_instance_consume_root_motionfunction

mk_model_root_motion_t mk_model_instance_consume_root_motion(mk_model_instance_t instance)

Return and reset motion accumulated since the previous consume.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

Returns The resulting handle or value.

mk_model_instance_copy_lightsfunction

uint32_t mk_model_instance_copy_lights(mk_model_instance_t instance, const float transform[16], mk_light_desc *out, uint32_t capacity)

Copy lights for the model instance.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
transformconst floatValue for transform.
outmk_light_desc *Value for out.
capacityuint32_tValue for capacity.

Returns The resulting value.

mk_model_instance_createfunction

mk_model_instance_t mk_model_instance_create(mk_model_t model)

Create an independent posed instance of a loaded model.

Instances own playback

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting handle or value. state and any dynamic vertex buffers needed for skinning/morphing.

mk_model_instance_crossfadefunction

mk_model_action_t mk_model_instance_crossfade(mk_model_instance_t instance, uint32_t animation, float duration_sec, uint32_t flags)

Crossfade all normal actions to a new looping or one-shot normal action.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
animationuint32_tValue for animation.
duration_secfloatValue for duration sec.
flagsuint32_tValue for flags.

Returns The resulting handle or value. Additive actions are left untouched. Faded-out sources are removed.

mk_model_instance_destroyfunction

void mk_model_instance_destroy(mk_model_instance_t instance)

Destroy an instance.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

mk_model_instance_drawfunction

void mk_model_instance_draw(mk_model_instance_t instance, const float transform[16])

Draw the current instance pose.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
transformconst floatValue for transform.

mk_model_instance_draw_exfunction

void mk_model_instance_draw_ex(mk_model_instance_t instance, const float transform[16], uint32_t filter)

Draw ex for the model instance.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
transformconst floatValue for transform.
filteruint32_tValue for filter.

mk_model_instance_draw_transmissive_layerfunction

void mk_model_instance_draw_transmissive_layer(mk_model_instance_t instance, const float transform[16], const float view_mtx[16], uint32_t layer)

Draw transmissive layer for the model instance.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
transformconst floatValue for transform.
view_mtxconst floatValue for view mtx.
layeruint32_tValue for layer.

mk_model_instance_is_validfunction

bool mk_model_instance_is_valid(mk_model_instance_t instance)

Test whether the model instance is valid.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

Returns True when the condition holds.

mk_model_instance_light_countfunction

uint32_t mk_model_instance_light_count(mk_model_instance_t instance)

Perform the model instance light count operation.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

Returns The resulting value.

mk_model_instance_pinfunction

bool mk_model_instance_pin(mk_model_instance_t instance)

Perform the model instance pin operation.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

Returns True when the operation succeeds.

mk_model_instance_playfunction

bool mk_model_instance_play(mk_model_instance_t instance, uint32_t animation, uint32_t flags)

Start playing an animation clip.

Time resets to zero. flags is MK_MODEL_PLAY_*.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
animationuint32_tValue for animation.
flagsuint32_tValue for flags.

Returns True when the operation succeeds. Returns false for invalid instance/model/animation.

mk_model_instance_poll_animation_eventfunction

bool mk_model_instance_poll_animation_event(mk_model_instance_t instance, mk_model_animation_event_t *out)

Poll one queued marker event.

Events are ordered by crossing time within an

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
outmk_model_animation_event_t *Value for out.

Returns True when the operation succeeds. update. Seeking does not enqueue events.

mk_model_instance_primary_actionfunction

mk_model_action_t mk_model_instance_primary_action(mk_model_instance_t instance)

Most recently started normal action, or MK_MODEL_ACTION_INVALID.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

Returns The resulting handle or value.

mk_model_instance_set_root_motionfunction

bool mk_model_instance_set_root_motion(mk_model_instance_t instance, uint32_t node, uint32_t flags)

Enable extraction from an explicit node.

flags is MK_MODEL_ROOT_MOTION_*. Selected components are removed from the rendered pose. Passing zero flags

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
nodeuint32_tValue for node.
flagsuint32_tValue for flags.

Returns True when the operation succeeds. disables extraction.

mk_model_instance_set_speedfunction

void mk_model_instance_set_speed(mk_model_instance_t instance, float speed)

Set the instance-wide playback speed multiplier.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
speedfloatValue for speed.

mk_model_instance_set_timefunction

void mk_model_instance_set_time(mk_model_instance_t instance, float time_sec)

Set current animation time in seconds.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
time_secfloatValue for time sec.

mk_model_instance_stopfunction

void mk_model_instance_stop(mk_model_instance_t instance)

Stop playback, keeping the current pose.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

mk_model_instance_timefunction

float mk_model_instance_time(mk_model_instance_t instance)

Current animation time in seconds.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

Returns The resulting value.

mk_model_instance_transmissive_countfunction

uint32_t mk_model_instance_transmissive_count(mk_model_instance_t instance)

Animated instance transmissive helpers, matching the model-level helpers.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

Returns The resulting value.

mk_model_instance_unpinfunction

void mk_model_instance_unpin(mk_model_instance_t instance)

Perform the model instance unpin operation.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.

mk_model_instance_updatefunction

void mk_model_instance_update(mk_model_instance_t instance, float dt_sec)

Advance playback and update the instance pose/dynamic geometry.

ParameterTypeDescription
instancemk_model_instance_tValue for instance.
dt_secfloatValue for dt sec.

mk_model_is_validfunction

bool mk_model_is_valid(mk_model_t model)

Test whether the model is valid.

ParameterTypeDescription
modelmk_model_tValue for model.

Returns True when the condition holds.

mk_model_light_countfunction

uint32_t mk_model_light_count(mk_model_t model)

Perform the model light count operation.

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value.

mk_model_loadfunction

mk_model_t mk_model_load(const char *path, uint32_t flags)

Load a model from a file path.

Returns MK_MODEL_INVALID on failure (logged).

ParameterTypeDescription
pathconst char *Value for path.
flagsuint32_tValue for flags.

Returns The resulting handle or value. External buffers/images referenced by the file are resolved relative to it.

mk_model_mask_createfunction

mk_model_mask_t mk_model_mask_create(mk_model_t model, float default_weight)

Create model mask.

ParameterTypeDescription
modelmk_model_tValue for model.
default_weightfloatValue for default weight.

Returns The resulting handle or value.

mk_model_mask_destroyfunction

void mk_model_mask_destroy(mk_model_mask_t mask)

Destroy the model mask.

ParameterTypeDescription
maskmk_model_mask_tValue for mask.

mk_model_mask_set_nodefunction

bool mk_model_mask_set_node(mk_model_mask_t mask, uint32_t node, float weight, bool include_descendants)

Set one node's 0..1 weight.

When include_descendants is true, applies to the

ParameterTypeDescription
maskmk_model_mask_tValue for mask.
nodeuint32_tValue for node.
weightfloatValue for weight.
include_descendantsboolValue for include descendants.

Returns True when the operation succeeds. complete node subtree.

mk_model_material_countfunction

uint32_t mk_model_material_count(mk_model_t model)

Number of distinct material slots extracted from the file.

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value.

mk_model_mesh_countfunction

uint32_t mk_model_mesh_count(mk_model_t model)

Number of drawable primitives (one per mesh primitive, after node flatten).

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value.

mk_model_node_countfunction

uint32_t mk_model_node_count(mk_model_t model)

Number of scene/skeleton nodes in the model.

Node indices are stable for the

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value. lifetime of the model and are used by masks and root motion.

mk_model_node_findfunction

int32_t mk_model_node_find(mk_model_t model, const char *name)

Find the first node with an exact name match.

ParameterTypeDescription
modelmk_model_tValue for model.
nameconst char *Stable name.

Returns The resulting value.

mk_model_node_namefunction

const char * mk_model_node_name(mk_model_t model, uint32_t node)

Node display name, or NULL when the index is out of range.

Unnamed nodes

ParameterTypeDescription
modelmk_model_tValue for model.
nodeuint32_tValue for node.

Returns A borrowed pointer, or NULL when unavailable. return an empty string.

mk_model_node_parentfunction

int32_t mk_model_node_parent(mk_model_t model, uint32_t node)

Parent node index, or -1 for a root or invalid node.

ParameterTypeDescription
modelmk_model_tValue for model.
nodeuint32_tValue for node.

Returns The resulting value.

mk_model_pinfunction

bool mk_model_pin(mk_model_t model)

Perform the model pin operation.

ParameterTypeDescription
modelmk_model_tValue for model.

Returns True when the operation succeeds.

mk_model_set_variantfunction

bool mk_model_set_variant(mk_model_t model, int32_t index)

Select a KHR_materials_variants entry.

Pass -1 to restore the glTF default material

ParameterTypeDescription
modelmk_model_tValue for model.
indexint32_tZero-based index.

Returns True when the operation succeeds. bindings. Returns false when the model is invalid or the index is out of range.

mk_model_system_shutdownfunction

void mk_model_system_shutdown(void)

Perform the model system shutdown operation.

mk_model_transmissive_countfunction

uint32_t mk_model_transmissive_count(mk_model_t model)

Count transmissive primitives in the loaded model.

Useful for layered transmission passes where each glass primitive is composited into the capture

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value. one at a time.

mk_model_unpinfunction

void mk_model_unpin(mk_model_t model)

Perform the model unpin operation.

ParameterTypeDescription
modelmk_model_tValue for model.

mk_model_variant_countfunction

uint32_t mk_model_variant_count(mk_model_t model)

Number of KHR_materials_variants entries.

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value.

mk_model_variant_indexfunction

int32_t mk_model_variant_index(mk_model_t model)

Current selected variant index, or -1 for the glTF default material bindings.

ParameterTypeDescription
modelmk_model_tValue for model.

Returns The resulting value.

mk_model_variant_namefunction

const char * mk_model_variant_name(mk_model_t model, uint32_t index)

Variant display name, or NULL when index is out of range.

ParameterTypeDescription
modelmk_model_tValue for model.
indexuint32_tZero-based index.

Returns A borrowed pointer, or NULL when unavailable.

Structs

mk_modelstruct

Data for model.

FieldTypeDescription
iduint32_tThe ID.

mk_model_actionstruct

Instance-owned animation action handle.

Pass the owning instance to every action function; handles are generational and become invalid when removed.

FieldTypeDescription
instance_iduint32_tThe instance ID.
iduint32_tThe ID.

mk_model_animation_eventstruct

Event emitted by a playing action after mk_model_instance_update.

FieldTypeDescription
actionmk_model_action_tThe action.
animationuint32_tThe animation.
time_secfloatThe time sec.
namecharThe name.
payloadint32_tThe payload.

mk_model_animation_markerstruct

Runtime marker attached to a source animation clip.

FieldTypeDescription
time_secfloatThe time sec.
namecharThe name.
payloadint32_tThe payload.

mk_model_instancestruct

Data for model instance.

FieldTypeDescription
iduint32_tThe ID.

mk_model_root_motionstruct

Data for model root motion.

FieldTypeDescription
translationmk_vec3The translation.
yawfloatThe yaw.

Enums

mk_model_flagsenum

Load flags (bitfield).

ValueDescription
MK_MODEL_NONESelects none.
MK_MODEL_UNLITuse unlit materials instead of Blinn-Phong lit
MK_MODEL_FLIP_UVflip texture V (for assets authored for D3D-style UVs)

Typedefs

mk_model_action_ttypedef

typedef struct mk_model_action mk_model_action_t

Instance-owned animation action handle.

Pass the owning instance to every action function; handles are generational and become invalid when removed.

mk_model_animation_event_ttypedef

typedef struct mk_model_animation_event mk_model_animation_event_t

Event emitted by a playing action after mk_model_instance_update.

mk_model_animation_marker_ttypedef

typedef struct mk_model_animation_marker mk_model_animation_marker_t

Runtime marker attached to a source animation clip.

mk_model_flags_ttypedef

typedef enum mk_model_flags mk_model_flags_t

Load flags (bitfield).

mk_model_instance_ttypedef

typedef struct mk_model_instance mk_model_instance_t

Data for model instance.

mk_model_mask_ttypedef

typedef struct mk_model_mask* mk_model_mask_t

Reusable, model-bound weighted node mask.

Assigning a mask to an action copies its weights, so the mask may be changed or destroyed afterward.

mk_model_root_motion_ttypedef

typedef struct mk_model_root_motion mk_model_root_motion_t

Data for model root motion.

mk_model_ttypedef

typedef struct mk_model mk_model_t

Data for model.

Macros

MK_MODEL_ACTION_INVALIDdefine

MK_MODEL_ACTION_INVALID

Invalid sentinel for model action.

MK_MODEL_ANIMATION_EVENT_NAME_MAXdefine

MK_MODEL_ANIMATION_EVENT_NAME_MAX

Maximum supported model animation event name max.

MK_MODEL_DRAW_ALLdefine

MK_MODEL_DRAW_ALL

Constant for model draw all.

MK_MODEL_DRAW_BLENDdefine

MK_MODEL_DRAW_BLEND

alphaMode = BLEND

MK_MODEL_DRAW_FORCE_IMMEDIATEdefine

MK_MODEL_DRAW_FORCE_IMMEDIATE

bypass pass-level AUTO_BATCH

MK_MODEL_DRAW_OPAQUEdefine

MK_MODEL_DRAW_OPAQUE

Primitive categories for mk_model_draw_ex (a primitive is exactly one).

opaque, non-transmissive

MK_MODEL_DRAW_TRANSMISSIVEdefine

MK_MODEL_DRAW_TRANSMISSIVE

KHR_materials_transmission.

MK_MODEL_INSTANCE_INVALIDdefine

MK_MODEL_INSTANCE_INVALID

Invalid sentinel for model instance.

MK_MODEL_INVALIDdefine

MK_MODEL_INVALID

Invalid sentinel for model.

MK_MODEL_MASK_INVALIDdefine

MK_MODEL_MASK_INVALID

Invalid sentinel for model mask.

MK_MODEL_MAX_ACTIONSdefine

MK_MODEL_MAX_ACTIONS

Maximum number of simultaneously retained actions on one model instance.

MK_MODEL_PLAY_ADDITIVEdefine

MK_MODEL_PLAY_ADDITIVE

Constant for model play additive.

MK_MODEL_PLAY_LOOPdefine

MK_MODEL_PLAY_LOOP

Constant for model play loop.

MK_MODEL_ROOT_MOTION_ALLdefine

MK_MODEL_ROOT_MOTION_ALL

Constant for model root motion all.

MK_MODEL_ROOT_MOTION_TRANSLATIONdefine

MK_MODEL_ROOT_MOTION_TRANSLATION

Constant for model root motion translation.

MK_MODEL_ROOT_MOTION_Xdefine

MK_MODEL_ROOT_MOTION_X

Constant for model root motion x.

MK_MODEL_ROOT_MOTION_Ydefine

MK_MODEL_ROOT_MOTION_Y

Constant for model root motion y.

MK_MODEL_ROOT_MOTION_YAWdefine

MK_MODEL_ROOT_MOTION_YAW

Constant for model root motion yaw.

MK_MODEL_ROOT_MOTION_Zdefine

MK_MODEL_ROOT_MOTION_Z

Constant for model root motion z.