C API: Types¶
Every public type of the headers, by name: what it is, its fields or values, and the calls that take it. The header's comment beside each field or value is its full description.
| Type | What it is |
|---|---|
sona_result |
An enum: SONA_OK, SONA_PENDING, SONA_E_UNSUPPORTED, SONA_E_ORIGIN, SONA_E_LICENCE, SONA_E_APP and more; taken by sona_result_name, sona_complete, sona_open, sona_abi_query and more |
sona_error_info |
The last error on a ctx: code, message and what to do about it. A struct with code, message, fix; taken by sona_last_error |
sona_allocator |
A struct with alloc, free, user; taken by sona_lipsync_create |
sona_budget |
Memory budget in bytes. A struct with total, assets, clips, faces, source_cache, gpu_idle; a field of sona_config |
sona_jobs |
A host job system. A struct with user, workers, run; a field of sona_config |
sona_http_request |
A struct with method, url, headers, body, body_len, timeout_ms; a field of sona_http |
sona_http |
A struct with user, send; taken by sona_http_platform |
sona_read_kind |
An enum: SONA_READ_ASSET, SONA_READ_DATA; a field of sona_source |
sona_source |
A host-written source. A struct with user, read, cancel, destroy; a field of sona_source_desc |
sona_source_desc |
A struct with kind, location, custom; a field of sona_config |
sona_config |
A struct with abi, app_id, licence, licence_len, sources, source_count, http, allocator and more; taken by sona_config_defaults, sona_open |
sona_xsdk |
An Xbox 360 title's avatars, renderer and display (sona_xsdk.h); made by sona_xsdk_open |
sona_xsdk_config |
A struct with size, folder, tv, max_avatars, memory_mb, workers, clear, log_level and more; taken by sona_xsdk_defaults, sona_xsdk_open |
sona_abi_info |
The ABI of the library that is loaded, for hosts and bindings that load it at run time: abi is its SONA_ABI, oldest_abi the oldest SONA_ABI a caller may be built against and still load it (nothing breaks for two minor versions), and its version as numbers. A struct with abi, oldest_abi, major, minor, patch; taken by sona_abi_query |
sona_event |
A struct with type, avatar, code, message, fix; taken by sona_poll_event |
sona_avatar_state |
An enum: SONA_AVATAR_QUEUED, SONA_AVATAR_LOADING, SONA_AVATAR_READY, SONA_AVATAR_FAILED, SONA_AVATAR_REMOVED; taken by sona_avatar_state_of |
sona_placement |
A struct with position, turn_deg, scale; taken by sona_avatar_move |
sona_add_options |
A struct with place, clip, loop, speed, start_at, visible, priority; taken by sona_add_defaults, sona_avatar_add, sona_avatar_add_base64, sona_avatar_add_state and more |
sona_play_options |
A struct with loop, speed, from; taken by sona_avatar_play, sona_avatar_crossfade, sona_avatar_queue, sona_avatar_play_stock |
sona_layer_options |
A struct with mode, flags, loop, weight, fade_seconds, speed, from, additive_ref and more; taken by sona_layer_defaults, sona_avatar_layer_play, sona_avatar_layer_blend, sona_avatar_layer_machine |
sona_layer_info |
A struct with kind, mode, state, clip, weight, time, normalized, ready and more; taken by sona_avatar_layer_info |
sona_blend_sample |
A struct with clip, x, y, speed; a field of sona_blend_space_desc |
sona_blend_space_desc |
A struct with dims, param_x, param_y, samples, sample_count, flags, smooth_seconds; taken by sona_blend_space_defaults, sona_blend_space_create |
sona_state_desc |
A struct with name, clip, blend, loop, speed; a field of sona_state_machine_desc |
sona_transition_desc |
A struct with from, to, fade_seconds, exit_time, condition_count, conditions; a field of sona_state_machine_desc |
sona_state_machine_desc |
A struct with state_count, states, transitions, transition_count, initial; taken by sona_state_machine_defaults, sona_state_machine_create |
sona_clip_info |
A struct with key, id, seconds, prop, caption; taken by sona_clip_get |
sona_view |
The camera, in doubles: the maths runs in double and stores float matrices only at the end, as the web SDK does. A struct with eye, target, fov_deg, near_z, far_z, width, height; taken by sona_view_defaults, sona_update, sona_draw, sona_snapshot and more |
sona_frame_stats |
A struct with ms, cpu_ms, drawn, culled, draw_calls, built; taken by sona_update |
sona_scene_stats |
A struct with fps, ms_per_frame, p95_ms, cpu_ms_per_frame, avatars, ready, queued, drawn and more; taken by sona_stats |
sona_lod_options |
Each sona_update gives every avatar in view a step by its height on screen in pixels: FULL (posed every frame), SAMPLED (posed when the clip reaches a new frame), QUARTER (also at most every 4th frame) and SPRITE (a picture of the avatar baked once per look and turn, drawn as one textured quad; not posed). A struct with full_px, quarter_px, sprite_px, fade_seconds, sprite_angles, sprite_height, max_looks, bake_ms; taken by sona_lod_defaults, sona_lod_set, sona_lod_get |
sona_lod_stats |
A struct with full, sampled, quarter, sprite, fading, looks, bakes, bake_ms; taken by sona_lod_stats_get |
sona_texture |
A struct with key, version, format, width, height, data, bytes; a field of sona_pose_data, sona_shading, sona_prop_data |
sona_material |
Address modes: bit 0 set = U wraps, bit 1 set = V wraps; clear = clamp. A struct with shader_id, flags, params, transparency, color_tex, intensity_tex, decal_tex, color_addr and more; a field of sona_pose_data, sona_prop_data |
sona_mesh |
The runtime vertex, its size set to 76 bytes, in host byte order: +0 float3 position (bind pose, avatar space) +12 uint8 x4 joint index * 3 (the palette's float4 row) +16 uint8 x4 weight (sum 255) +20 uint8 x4 normal, (n * 0.5 + 0.5) * 255; byte 23 is 0 +24 uint8 x4 vertex colour (baked occlusion and alpha) +28 float4 uv0.xy, uv1.xy +44 float4 uv2.xy, uv3.xy (the HQ shaders read uv2 only) +60 float4 uv4.xy, uv5.xy. A struct with item, mask, batch, material, pass, palette, vertex_count, index_count and more; a field of sona_pose_data, sona_prop_data |
sona_prop_palette |
A struct with item, playing, palette; a field of sona_pose_data |
sona_pose_data |
A struct with build_version, world, palette, view_joints, mesh_count, meshes, material_count, materials and more; taken by sona_pose |
sona_shading |
The fixed shading inputs, for hosts that rebuild our look in their own shaders. A struct with irradiance, irradiance_gain, ao_gain, bloom_gain, shadow_rows, rim; taken by sona_shading_get |
sona_program |
An enum: SONA_PROG_SHADOW, SONA_PROG_GBUFFER, SONA_PROG_SSAO, SONA_PROG_BRIGHT, SONA_PROG_BLUR, SONA_PROG_PRESENT and more; taken by sona_shader_source |
sona_device_desc |
The host owns the device. A struct with backend, u, instance, physical_device, device, queue, queue_family, api_version and more; taken by sona_renderer_create, sona_renderer_reset |
sona_target |
Where one sona_draw lands. A struct with width, height, u, image, view, format, layout_before, layout_after and more; taken by sona_draw, sona_item_preview_draw, sona_draw_lit, sona_screen_view_draw and more |
sona_draw_options |
A struct with clear, flags, credit_corner; taken by sona_draw, sona_snapshot, sona_item_preview_draw, sona_item_preview_snapshot and more |
sona_preview_options |
A struct with gender, slot, flags, skin, colours, priority, time, margin; taken by sona_preview_defaults, sona_item_preview_add |
sona_quality |
A struct with msaa, flags; taken by sona_quality_defaults, sona_renderer_set_quality, sona_renderer_quality |
sona_tier_options |
A struct with tier, target_fps, avatars; taken by sona_tier_defaults, sona_tier_apply |
sona_picture |
Pictures for 2D games and chat (sprites2d guide). A struct with rgba, width, height; taken by sona_pixel_art, sona_pixel_palette, sona_sticker, sona_sheet_page |
sona_pixel_options |
A struct with height, colours, flags, outline, alpha_cut, palette, palette_count; taken by sona_pixel_defaults, sona_pixel_art |
sona_sticker_options |
A struct with pixels, clip, time, turn_deg, framing, outline_px, outline, shadow_px and more; taken by sona_sticker_defaults, sona_sticker |
sona_sheet_options |
A struct with frames, clip, name, from, to, directions, first_deg, pitch_deg and more; taken by sona_sheet_defaults, sona_sheet_render |
sona_sheet_frame |
One frame of a sheet. A struct with page, x, y, w, h, trim_x, trim_y, cell_w and more; taken by sona_sheet_frame_get |
sona_asset_ref |
A struct with id, mask, colours; a field of sona_manifest |
sona_manifest |
A struct with version, weight, height, chin, nose, ears, face, colours and more; taken by sona_manifest_parse, sona_manifest_write, sona_manifest_wear, sona_manifest_unwear and more |
sona_credit |
A struct with text, url, rgba, width, height; taken by sona_credit_get |
sona_section |
The editor's wardrobe and appearance sections. An enum: SONA_SECTION_ANY, SONA_SECTION_COSTUME, SONA_SECTION_SHIRT, SONA_SECTION_TROUSERS, SONA_SECTION_SHOES, SONA_SECTION_HEADWEAR and more; a field of sona_item_info, sona_catalogue_query, sona_random_options and more |
sona_item_info |
One item. A struct with guid, id, kind, gender, section, mask, flags, route and more; taken by sona_catalogue_get |
sona_catalogue_query |
A struct with text, game, slots, section, gender, require, exclude, offset; taken by sona_catalogue_search, sona_filter_search |
sona_custom_item_info |
A struct with id, mask, body, version, flags, template_id, sha256, template_sha256 and more; taken by sona_custom_item_check, sona_custom_item_get, sona_custom_item_find |
sona_paint_spec |
A struct with id, template_id, version, name, description, creator, created, licence and more; taken by sona_custom_item_pack |
sona_mesh_item_spec |
A struct with flags, id, template_id, version, glb, glb_len, name, description and more; taken by sona_mesh_item_spec_defaults, sona_custom_item_pack_mesh |
sona_lipsync_options |
A struct with sample_rate, channels, format, hold_seconds, attack_seconds, release_seconds, gate_db, lead_seconds and more; taken by sona_lipsync_defaults, sona_lipsync_create, sona_lipsync_phonemes, sona_lipsync_text |
sona_lipsync_frame |
A struct with time, mouth, flags, open, level_db, weights, f1, f2; taken by sona_lipsync_read, sona_lipsync_current, sona_mouth_keys_sample |
sona_voice_mouth |
Voice chat: a mouth from an audio level alone (linear RMS, 0..1; scale does not matter), for every remote player. A struct with seed, word, value; taken by sona_voice_mouth_init, sona_voice_mouth_step, sona_avatar_voice, sona_voice_mouths |
sona_headless_options |
A struct with device, backend, adapter, flags, batch_in_flight, wait_seconds; taken by sona_headless_defaults, sona_headless_devices, sona_headless_open |
sona_headless_info |
A struct with backend, software, type, vendor_id, device_id, name, driver; taken by sona_headless_devices, sona_headless_info_get |
sona_render_options |
A struct with width, height, preset, yaw_deg, pitch_deg, zoom, turn_deg, time and more; taken by sona_render_defaults, sona_headless_render, sona_headless_render_manifest, sona_headless_batch and more |
sona_sequence_options |
A struct with frames, fps, turn_deg, flags; taken by sona_sequence_defaults, sona_headless_sequence, sona_headless_record |
sona_video_options |
A struct with format, width, height, fps, loops, quality, background, flags and more; taken by sona_video_defaults, sona_video_open |
sona_skeleton_kind |
The rig's joints under other skeletons' bone names, for retargeting (skeleton maps guide). An enum: SONA_SKELETON_UNITY, SONA_SKELETON_VRM, SONA_SKELETON_VRM0, SONA_SKELETON_UE4, SONA_SKELETON_UE5, SONA_SKELETON_COUNT; a field of sona_export_options |
sona_vrm_expression |
VRM expressions, the presets of VRM 1.0 (VRM 0.x: a i u e o, joy angry sorrow fun, surprised as a custom group, blink, blink_l, blink_r, lookup lookdown lookleft lookright). An enum: SONA_VRM_AA, SONA_VRM_IH, SONA_VRM_OU, SONA_VRM_EE, SONA_VRM_OH, SONA_VRM_HAPPY and more |
sona_export_options |
A struct with format, flags, bone_names, name, version, authors, copyright, contact and more; taken by sona_export_defaults, sona_export_avatar |
sona_export_report |
A struct with meshes, primitives, vertices, triangles, degenerate, textures, expressions, atlas_cells and more; taken by sona_export_avatar |
sona_print_options |
A struct with flags, height_mm, mm_per_metre, min_wall_mm, voxel_mm, close_mm, base_height_mm, base_margin_mm and more; taken by sona_print_defaults, sona_print_avatars, sona_print_triangles |
sona_print_mesh |
The solid. A struct with vertex_count, triangle_count, shells, volume_mm3, area_mm2, positions, colours, indices and more; taken by sona_print_get |
sona_print_report |
What sona_print_check found. A struct with vertices, triangles, edges, boundary_edges, nonmanifold_edges, flipped_edges, nonmanifold_vertices, degenerate and more; taken by sona_print_check |
sona_stock_clip |
A struct with id, name, family, asset_id, caption, tags, body, frames and more; taken by sona_stock_clip_at, sona_stock_clip_get |
sona_idle_options |
A struct with parts, seed, amount, face_px; taken by sona_idle_defaults, sona_avatar_idle, sona_avatar_idle_get, sona_idle_sample |
sona_idle_state |
A struct with blink, gaze, shift, breath; taken by sona_avatar_idle_state, sona_idle_sample |
sona_ik_foot_lock |
Foot locking: a foot the clip plants (down, its ankle at the flat foot's height, and no longer swinging) stays where it landed until the clip lifts the heel, so walk and run clips do not slide while the host moves the avatar no faster than the clip's feet travel; faster, the held foot is dragged after the body just enough for the leg to reach it and slides less than without locking. A struct with flags, weight, max_slide, release_seconds; taken by sona_ik_foot_lock_defaults, sona_avatar_ik_foot_lock |
sona_ik_spine |
Spine assist: a hand target past the arm's reach bends and turns the spine, and the hips a little, towards it. A struct with flags, weight, max_bend_deg, max_twist_deg, hips_share; taken by sona_ik_spine_defaults, sona_avatar_ik_spine |
sona_ik_fingers |
Finger curl per hand, over the clip's: 0 open to 1 closed, per finger, and spread. A struct with flags, curl, spread, weight, fade_seconds; taken by sona_ik_fingers_defaults, sona_avatar_ik_fingers |
sona_ik_eyes |
A struct with flags, max_speed_deg, smoothing, lead_seconds; taken by sona_ik_eyes_defaults, sona_avatar_ik_eyes |
sona_import_options |
A struct with format, key, take, take_index, flags, map, map_count, fps and more; taken by sona_import_defaults, sona_anim_file_load, sona_anim_file_open, sona_clip_import |
sona_import_info |
A struct with format, naming, bones, takes, mapped, frames, fps, seconds and more; taken by sona_clip_import, sona_clip_imported_get, sona_clip_imported_find |
sona_players_config |
A struct with max_players, refresh_s, per_hour, in_flight, timeout_ms, host, client, http and more; taken by sona_players_defaults, sona_players_open |
sona_player_look |
A struct with state, error, placeholder, fetched_at, checked_at, next_check, manifest, version and more; taken by sona_players_look |
sona_player_event |
A struct with type, code, id; taken by sona_players_poll |
sona_players_stats |
A struct with players, watched, in_flight, due, requests, changed, same, not_modified and more; taken by sona_players_stats_get |
sona_random_options |
A struct with body, style, palette, flags, require, exclude, skip_sections, skin_count and more; taken by sona_random_defaults, sona_make_random |
sona_random_report |
A struct with body, seed, set, picked, candidates; taken by sona_make_random |
sona_like_options |
A struct with parts, match, flags, available, available_user; taken by sona_like_defaults, sona_make_dress_like |
sona_like_report |
A struct with count, kept, variants, similar, substitutes, dropped, covered, items; taken by sona_make_dress_like |
sona_outfit_set |
A struct with title, game, name, count, bodies, sections, slots; taken by sona_outfit_set_get |
sona_outfit_issue |
A struct with kind, severity, slots, field, item, other; taken by sona_outfit_check |
sona_outfit_report |
A struct with issues, errors, warnings, body, slots, set, set_items, valid; taken by sona_outfit_check, sona_outfit_fix |
sona_filter_verdict |
A struct with allowed, reason, tag, index, section, source, tags; taken by sona_filter_check |
sona_filter_report |
A struct with count, replaced, hidden, cache, change; taken by sona_filter_manifest, sona_filter_manifest_bytes, sona_avatar_filter_report |
sona_state_info |
A struct with version, has_look, parts, clock; taken by sona_state_info_get |
sona_state_status |
A struct with mode, pending, missing, applied; taken by sona_avatar_state_status |
sona_net_options |
A struct with tick_hz, history, full_after; taken by sona_net_defaults, sona_net_sender_create, sona_net_receiver_create |
sona_net_look |
A struct with version, kind, manifest, id; taken by sona_net_receiver_look |
sona_net_stats |
A struct with packets, bytes, full, newest, oldest, last_bytes, acked; taken by sona_net_sender_stats, sona_net_receiver_stats |
sona_record_options |
A struct with tick_hz, keyframe_ticks, keep_seconds; taken by sona_record_defaults, sona_recorder_create |
sona_replay_info |
A struct with tracks, tick_hz, first_tick, last_tick, frames, seconds; taken by sona_replay_info_get |
sona_lighting |
A struct with flags, key, fill, ambient, environment, specular, rim, shadow and more; taken by sona_lighting_defaults, sona_renderer_set_lighting, sona_renderer_lighting, sona_draw_lit and more |
sona_environment |
A struct with kind, sh, cube_size, cube, skin_red; taken by sona_environment_defaults, sona_renderer_set_environment, sona_environment_irradiance |
sona_host_shadow |
The host's shadow map, sampled by the lit avatars (they receive the host scene's shadows), together with their own map. A struct with flags, matrix, bias, width, height, u, view, layout and more; taken by sona_renderer_set_host_shadow |
sona_shadow_map |
The renderer's own shadow map as its last lit frame with shadows drew it (the avatars only), for the host to shadow its scene with: sample it at the matrix's (u, v) and compare depth as above. A struct with width, height, format, matrix, texel_metres, frame, u, image and more; taken by sona_renderer_shadow_map |
sona_style |
A struct with kind, flags, bands, shade, highlight, outline_px, outline, colour; taken by sona_style_defaults, sona_avatar_set_style, sona_avatar_style, sona_renderer_set_style and more |
sona_placeholder_options |
A struct with flags, delay_seconds, appear_seconds, reveal_seconds, failed_seconds, tint, failed_tint, glow; taken by sona_placeholder_defaults, sona_placeholder_set, sona_placeholder_get |
sona_placeholder_info |
A struct with phase, opacity, height, gender, clip, seconds, sprite; taken by sona_avatar_placeholder_info |
sona_placeholder_stats |
A struct with shown, waiting, loading, revealing, failed, sprites, posed, pose_ms and more; taken by sona_placeholder_stats_get |
sona_overlay |
A straight-alpha RGBA8 picture that every sona_draw on the renderer blends over its target after the credit, on every backend: SRC_ALPHA, ONE_MINUS_SRC_ALPHA (alpha ONE, ONE_MINUS_SRC_ALPHA), nearest sampling, no depth. A struct with width, height, stride, rgba, revision, dirty, rect; taken by sona_renderer_overlay |
sona_screen_action |
An enum: SONA_ACT_NONE, SONA_ACT_UP, SONA_ACT_DOWN, SONA_ACT_LEFT, SONA_ACT_RIGHT, SONA_ACT_ACCEPT and more; a field of sona_screen_event, sona_screen_node |
sona_screen_event |
One input event. A struct with type, action, from, x, y, pointer; taken by sona_screen_input |
sona_screen_theme |
Colours are 0xAARRGGBB. A struct with flags, background, panel, panel_raised, text, text_dim, accent, accent_text and more; taken by sona_screen_theme_defaults, sona_screen_set_theme |
sona_screen_node |
One thing to draw, in paint order. A struct with id, parent, role, state, x, y, w, h and more; taken by sona_screen_nodes |
sona_screen_status |
An enum: SONA_SCREEN_RUNNING, SONA_SCREEN_DONE, SONA_SCREEN_CANCELLED, SONA_SCREEN_FINE_TUNE; taken by sona_screen_update |
sona_quick_options |
A struct with seed, looks, body, flags, catalogue, filter, filter_user, theme and more; taken by sona_quick_defaults, sona_quick_open, sona_quick_look |
sona_wardrobe_options |
A struct with flags, manifest, catalogue, owned, owned_count, outfits, outfit_count, outfit_names and more; taken by sona_wardrobe_defaults, sona_wardrobe_open |
sona_screen_stats |
A struct with presses, taps, changes, shuffles, focus_moves, seconds, action_presses; taken by sona_screen_stats_get |
sona_pick_options |
A struct with flags, max_distance, ignore_count, ignore; taken by sona_pick_defaults, sona_pick_ray, sona_pick_screen, sona_pick_ray_all and more |
sona_body_region |
An enum: SONA_REGION_NONE, SONA_REGION_HEAD, SONA_REGION_NECK, SONA_REGION_TORSO, SONA_REGION_HIPS, SONA_REGION_LEFT_ARM and more; a field of sona_pick_hit |
sona_pick_hit |
A struct with source, flags, avatar_id, avatar, part, section, mask, item and more; taken by sona_pick_ray, sona_pick_screen, sona_pick_ray_all, sona_avatar_pick and more |
sona_prop_part |
A struct with flags, vertex_count, index_count, positions, normals, uvs, colours, indices and more; taken by sona_prop_part_defaults, sona_prop_mesh_create |
sona_prop_load_options |
A struct with flags, scale, scene; taken by sona_prop_load_defaults, sona_prop_mesh_load, sona_prop_mesh_open |
sona_prop_mesh_info |
A struct with kind, flags, parts, vertices, triangles, textures, joints, hand and more; taken by sona_prop_mesh_info_get |
sona_prop_data |
The meshes in the data API's own form (3.11), for hosts that draw props themselves: 76-byte vertices whose joint bytes index sona_prop_frame.mesh_count, meshes, material_count, materials, texture_count, textures, joints; taken by sona_prop_mesh_data |
sona_prop_attach |
A struct with flags, joint, position, rotation, scale, hand, hand_flags, hand_position and more; taken by sona_prop_attach_defaults, sona_avatar_prop_attach, sona_avatar_prop_set, sona_avatar_prop_get |
sona_prop_frame |
A struct with flags, joint, time, world, avatar, hand_error, joints, palette; taken by sona_avatar_prop_frame |
sona_ragdoll_options |
A struct with flags, total_mass, coverage, limits; taken by sona_ragdoll_defaults, sona_avatar_ragdoll |
sona_ragdoll_body |
One body. A struct with joint, parent, shape, no_collide, position, rotation, shape_position, shape_rotation and more; taken by sona_avatar_ragdoll |
sona_ragdoll_state |
A body's world transform and velocities, in sona_avatar_ragdoll's order. A struct with position, rotation, velocity, angular_velocity; taken by sona_avatar_ragdoll_state, sona_avatar_ragdoll_drive |
sona_ragdoll_info |
A struct with mode, weight, blend_left, face_up, hips, lowest, getup_position, getup_turn_deg; taken by sona_avatar_ragdoll_info |
sona_ragdoll_motor |
Powered ragdolls. A struct with rotation, joint_rotation, angular_velocity, world_position, world_rotation, velocity, world_angular_velocity; taken by sona_avatar_ragdoll_motors |
sona_seat |
A struct with kind, position, turn_deg, height, depth, width; taken by sona_seat_defaults |
sona_interaction_desc |
A struct with kind, a, b, position, turn_deg, flags, start_seconds, hold_seconds and more; taken by sona_interaction_defaults, sona_interaction_layout, sona_interaction_start |
sona_interaction_plan |
Where the interaction stands its avatars and where the contacts meet, before it starts (walk them there). A struct with contacts, place, contact, spacing, clearance; taken by sona_interaction_layout |
sona_interaction_status |
A struct with kind, phase, phase_seconds, progress, touching, contact_error, clearance, contact and more; taken by sona_interaction_status_get |
sona_emote |
A struct with count, clips, weights, speed, confidence, expression; taken by sona_emote_from_text, sona_avatar_emote |
sona_award_def |
A developer defines award items for an app (on the devs site, or with sona_award_define and the app's developer key); the game unlocks one for a signed-in player and it joins their 360sona wardrobe. A struct with flags, key, title, description, item, developer_key; taken by sona_award_def_defaults, sona_award_define |
sona_capsule |
A vertical capsule around the posed body, in world space, for collisions: the segment a..b and its radius. A struct with a, b, radius; taken by sona_avatar_capsule |
sona_clip_event |
A struct with kind, mark, clip, time; taken by sona_avatar_clip_events |
sona_layer_event |
A struct with kind, layer, state, from_state, time; taken by sona_avatar_layer_events |
sona_condition |
A struct with param, op, value; a field of sona_transition_desc |
sona_shader_lang |
An enum: SONA_LANG_GLSL_ES300, SONA_LANG_GLSL_330, SONA_LANG_SPIRV, SONA_LANG_HLSL, SONA_LANG_MSL; taken by sona_shader_source |
sona_preset |
An enum: SONA_PRESET_FULL, SONA_PRESET_UPPER, SONA_PRESET_BUST, SONA_PRESET_FACE; taken by sona_camera_preset |
sona_guid |
A struct with b; taken by sona_slot_of, sona_guid_parse, sona_guid_format, sona_manifest_wear and more |
sona_route |
An enum: SONA_ROUTE_REJECTED, SONA_ROUTE_WORN, SONA_ROUTE_BARE, SONA_ROUTE_FACE; taken by sona_slot_of |
sona_body |
An enum: SONA_BODY_MAN, SONA_BODY_WOMAN, SONA_BODY_BOTH; a field of sona_custom_item_info |
sona_phoneme |
A phoneme with its time in seconds: ARPAbet ("AH0"), IPA ("ʃ"), the 15 viseme names ("PP", "aa"), the 22 viseme ids as digits ("21"), or a mouth name ("AI"). A struct with symbol, start, end; taken by sona_lipsync_hint, sona_lipsync_phonemes |
sona_mouth_key |
A mouth from time on. A struct with time, mouth, open, flags; taken by sona_lipsync_phonemes, sona_lipsync_text, sona_mouth_keys_sample |
sona_vrm_face |
The face an expression shows: a shape index per face part, in sona_avatar_expression's order (mouth, left eyebrow, right eyebrow, left eye, right eye; left is the avatar's own left), or 255 for a part it leaves to the others. A struct with expression, parts; taken by sona_vrm_face_default |
sona_bone_map |
One override: the source bone (its full name, or as matched: lower case, no prefix) drives joint (a sona_joint_find name). A struct with source, joint; a field of sona_import_options |
sona_interaction_event |
A struct with kind, phase, time, value; taken by sona_interaction_events |
sona_ctx |
An opaque handle, made by sona_open and freed by sona_close, sona_free; taken by sona_open, sona_close, sona_last_error, sona_app_id and more |
sona_avatar |
An opaque handle, made by sona_avatar_add, sona_avatar_add_base64, sona_item_preview_add and more; taken by sona_avatar_add, sona_avatar_add_base64, sona_avatar_state_of, sona_avatar_id and more |
sona_renderer |
An opaque handle, made by sona_renderer_create, sona_headless_renderer and freed by sona_renderer_destroy; taken by sona_renderer_create, sona_renderer_destroy, sona_draw, sona_renderer_frame_index and more |
sona_request |
one read in flight from a source. An opaque handle; taken by sona_complete |
sona_http_reply |
An opaque handle; taken by sona_http_done |
sona_blend_space |
An opaque handle, made by sona_blend_space_create and freed by sona_blend_space_destroy; taken by sona_avatar_layer_blend, sona_blend_space_create, sona_blend_space_destroy, sona_blend_space_weights |
sona_state_machine |
An opaque handle, made by sona_state_machine_create and freed by sona_state_machine_destroy; taken by sona_avatar_layer_machine, sona_state_machine_create, sona_state_machine_destroy, sona_state_machine_find and more |
sona_sheet |
An opaque handle, made by sona_sheet_render and freed by sona_sheet_free; taken by sona_sheet_render, sona_sheet_free, sona_sheet_page_count, sona_sheet_page and more |
sona_catalogue |
Every item id with its name, slots, game and source, from sona-catalogue.sona_catalogue_load, sona_catalogue_load_memory and freed by sona_catalogue_free; taken by sona_catalogue_load, sona_catalogue_load_memory, sona_catalogue_free, sona_catalogue_count and more |
sona_lipsync |
An opaque handle, made by sona_lipsync_create and freed by sona_lipsync_destroy; taken by sona_lipsync_create, sona_lipsync_destroy, sona_lipsync_reset, sona_lipsync_feed and more |
sona_headless |
A device of the library's own, with no window and no display, for servers, bots and tools: the best GPU, or a software device (lavapipe, llvmpipe) where there is none, so it runs in a container. An opaque handle, made by sona_headless_open and freed by sona_headless_close; taken by sona_headless_open, sona_headless_close, sona_headless_info_get, sona_headless_renderer and more |
sona_video |
An opaque handle, made by sona_video_open; taken by sona_headless_record, sona_video_open, sona_video_frame, sona_video_finish |
sona_print |
An opaque handle, made by sona_print_avatars, sona_print_triangles and freed by sona_print_free; taken by sona_print_avatars, sona_print_triangles, sona_print_get, sona_print_encode and more |
sona_anim_file |
A parsed file: no ctx, nothing retargeted. An opaque handle, made by sona_anim_file_load, sona_anim_file_open and freed by sona_anim_file_free; taken by sona_anim_file_load, sona_anim_file_open, sona_anim_file_free, sona_anim_file_takes and more |
sona_players |
An opaque handle, made by sona_players_open and freed by sona_players_close; taken by sona_players_open, sona_players_close, sona_players_watch, sona_players_unwatch and more |
sona_maker |
A maker indexes a catalogue's outfit rules once: candidate items per body and section, gender variants and matched sets (makers guide). An opaque handle, made by sona_maker_create and freed by sona_maker_free; taken by sona_maker_create, sona_maker_free, sona_make_random, sona_make_dress_like and more |
sona_filter |
Which items a game allows (filters guide): by section, slot, game (the franchise, brand or collection an item comes from), tag, source or id. An opaque handle, made by sona_filter_create, sona_ctx_filter and freed by sona_filter_free; taken by sona_filter_create, sona_filter_free, sona_filter_reset, sona_filter_sections and more |
sona_net_sender |
Network sync: a stream carries one avatar from a sender to one receiver. An opaque handle, made by sona_net_sender_create and freed by sona_net_sender_destroy; taken by sona_net_sender_create, sona_net_sender_destroy, sona_net_sender_look, sona_net_write and more |
sona_net_receiver |
An opaque handle, made by sona_net_receiver_create and freed by sona_net_receiver_destroy; taken by sona_net_receiver_create, sona_net_receiver_destroy, sona_net_read, sona_net_receiver_look and more |
sona_recorder |
Replays (replays, kill-cams, bug reports): a recorder takes avatars' states at each tick into one compact file (the network coding, with a full state every keyframe_ticks so any moment is a short decode away); a replay shows any track at any time on a puppet, so seeking, slow motion, fast forward and reverse are where the host moves the time. An opaque handle, made by sona_recorder_create and freed by sona_recorder_destroy; taken by sona_recorder_create, sona_recorder_destroy, sona_recorder_track, sona_recorder_capture and more |
sona_replay |
An opaque handle, made by sona_replay_open and freed by sona_replay_close; taken by sona_replay_open, sona_replay_close, sona_replay_info_get, sona_replay_track and more |
sona_screen |
Two ready-made screens a game opens and gets an avatar back from (quick creator guide). An opaque handle, made by sona_quick_open, sona_wardrobe_open and freed by sona_screen_destroy; taken by sona_quick_open, sona_wardrobe_open, sona_screen_destroy, sona_screen_kind and more |
sona_prop_mesh |
An opaque handle, made by sona_prop_mesh_create, sona_prop_mesh_load, sona_prop_mesh_open and more; taken by sona_prop_mesh_create, sona_prop_mesh_load, sona_prop_mesh_open, sona_prop_mesh_stock and more |
sona_interaction |
Two avatars of any heights and shapes doing one thing together, or one avatar on a seat. An opaque handle, made by sona_interaction_start; taken by sona_interaction_start, sona_interaction_end, sona_interaction_move, sona_interaction_remove and more |
sona_picture_fn |
One picture of a batch or a sequence. A callback the host supplies: void (*sona_picture_fn)(void *user, uint32_t index, sona_result result, const uint8_t *rgba, uint32_t width, uint32_t height); taken by sona_headless_batch, sona_headless_sequence |
sona_body_options |
A struct with flags, min_cutoff, beta, min_visibility, lost_seconds, return_seconds; taken by sona_body_defaults, sona_body_create |
sona_body_input |
One frame of a body tracker. A struct with flags, time, layout, count, points, visibility, image; taken by sona_body_input_defaults, sona_body_feed |
sona_body_tracker |
An opaque handle, made by sona_body_create and freed by sona_body_destroy; taken by sona_body_create, sona_body_destroy, sona_body_reset, sona_body_feed and more |
sona_editor_options |
A struct with mode, width, height, flags, start, catalogue, seed, title and more; taken by sona_editor_defaults, sona_editor_open |
sona_editor_theme |
Colours are 0xAARRGGBB, straight alpha. A struct with background, panel, raised, text, text_dim, accent, accent_text, focus and more; taken by sona_editor_theme_defaults, sona_editor_open, sona_editor_set_theme |
sona_editor_input |
A struct with kind, code, down, mods, pointer, x, y, value; taken by sona_editor_feed |
sona_editor_control |
A struct with id, role, flags, rect, value, min, max, index and more; taken by sona_editor_control_get, sona_editor_focus_get |
sona_editor_draw_data |
A struct with width, height, revision, vertices, vertex_count, indices, index_count, commands and more; taken by sona_editor_draw_data_get |
sona_editor_texture |
A struct with id, width, height, revision, dirty, dirty_since, rgba; taken by sona_editor_texture_get |
sona_editor |
An opaque handle, made by sona_editor_open and freed by sona_editor_close; taken by sona_editor_open, sona_editor_close, sona_editor_set_theme, sona_editor_resize and more |
sona_npc_options |
A struct with flags, speak, speak_user, line, line_user, look_seconds, idle_emote_seconds; taken by sona_npc_defaults, sona_npc_create |
sona_npc_state |
A struct with state, line, queued; taken by sona_npc_state_get |
sona_npc |
An opaque handle, made by sona_npc_create and freed by sona_npc_destroy; taken by sona_npc_create, sona_npc_destroy, sona_npc_say, sona_npc_emote and more |
sona_track_options |
A struct with flags, face_min_cutoff, face_beta, head_min_cutoff, head_beta, head_gain, head_limit_deg, neck_share and more; taken by sona_track_defaults, sona_track_create, sona_track_set_options |
sona_track_face_input |
One frame of a face tracker. A struct with flags, time, layout, count, weights, head_rotation; taken by sona_track_face_input_defaults, sona_track_face_feed |
sona_track_face_state |
What the tracker makes of the frames so far. A struct with tracking, time, weight, expression, mood, head, weights; taken by sona_track_face_get |
sona_track_calibration |
Neutral face. A struct with frames, neutral, head; taken by sona_track_calibrate_end, sona_track_calibration_set, sona_track_calibration_get |
sona_tracker |
An opaque handle, made by sona_track_create and freed by sona_track_destroy; taken by sona_track_create, sona_track_destroy, sona_track_set_options, sona_track_reset and more |
sona_xr_options |
A struct with flags, user_height, step_distance; taken by sona_xr_defaults, sona_xr_create |
sona_xr_input |
A struct with flags, time, head, left_hand, right_hand, floor_y; taken by sona_xr_input_defaults, sona_xr_feed |
sona_xr_body |
An opaque handle, made by sona_xr_create and freed by sona_xr_destroy; taken by sona_xr_create, sona_xr_destroy, sona_xr_feed, sona_xr_calibrate and more |
sona_source_kind |
The kind of a source in sona_source_desc: SONA_SOURCE_CUSTOM, _GATE, _DIR, _CONSOLE |
sona_event_type |
The kind of a sona_event: SONA_EVENT_READY, _FAILED, _ERROR and the rest |
sona_clip_event_kind |
The kind of a sona_clip_event: a clip starting, looping or ending, a footfall, a mark |
sona_layer_event_kind |
The kind of a sona_layer_event on an animation layer |
sona_tex_format |
The pixel format of a sona_texture in the data API |
sona_pass |
Which pass a mesh draws in: SONA_PASS_OPAQUE or SONA_PASS_TRANSPARENT |
sona_backend |
A graphics API: Vulkan, Direct3D 11, Direct3D 12, OpenGL, OpenGL ES, Metal or Xenos |
sona_corner |
A corner of the target, for the credit badge: SONA_CORNER_BOTTOM_RIGHT (0), _BOTTOM_LEFT, _TOP_RIGHT, _TOP_LEFT |
sona_face_record |
One face record of a manifest: an item id and four words |
sona_paint_image |
An RGBA8 picture for sona_paint_spec: pixels, width and height |
sona_paint_surface |
One surface of a painted item: its colour, regions and decal pictures (NULL rgba: none) |
sona_device_kind |
What a headless renderer may open: SONA_DEVICE_AUTO, _GPU or _SOFTWARE |
sona_video_format |
What a sona_video writes: a PNG sequence, GIF, MP4 or WebM |
sona_anim_format |
The format of an animation file: SONA_ANIM_AUTO, _GLTF, _FBX or _BVH |
sona_rig_naming |
How an imported file names its bones, for retargeting onto the avatar rig |
sona_player_state |
What is known of another player's avatar: waiting, fresh, stale, private or none |
sona_player_event_type |
The kind of a sona_player_event |
sona_like_item |
One item sona_make_dress_like carried across: from, to, the outcome and the section |
sona_filter_change |
One change a content filter made to a manifest: an item replaced (SONA_CONTENT_REPLACED) or hidden (SONA_CONTENT_HIDDEN) |
sona_light |
One of the host's lights in sona_lighting |
sona_style_kind |
An art style: SONA_STYLE_ORIGINAL, _TOON, _FLAT, _SILHOUETTE or _PROMO |
sona_placeholder_phase |
Where a placeholder figure is: none, waiting, loading, revealing or failed |
sona_screen_role |
The role of a sona_screen_node, for drawing it and for screen readers |
sona_ik_ground_fn |
The host's ground query for foot planting: a ray straight down from a point, returning the first hit and its normal |
sona_item_filter_fn |
A filter on catalogue items for the player screens: 1 to offer an item, 0 to leave it out |
sona_editor_vertex |
One vertex of the player editor's UI layer, for a host that draws it itself |
sona_editor_command |
One draw of the editor's UI layer: a texture, a range of indices and a scissor, blended with straight alpha |
sona_editor_filter_fn |
The editor's content filter hook: 0 leaves an item out of every list and every generated look |
sona_editor_look_fn |
The editor's seeded look hook: write look index of seed into the manifest and return 1, or 0 for the editor's own |
sona_editor_sound_fn |
Told when the editor would play one of its sounds |
sona_npc_speak_fn |
The host's text to speech for the NPC kit: mono 16-bit PCM for a line, or 0 to show it without a voice |
sona_npc_line_fn |
Told when the NPC starts and stops saying a line |
sona_blendshape |
The face blendshapes in ARKit's order (SONA_TRACK_BLENDSHAPES of them), the face tracker's input |
sona_track_mood |
The face's moods, the first seven shapes of every part of the avatar's face |
sona_xr_pose |
A pose in world metres, as OpenXR's XrPosef: a position, then a unit quaternion |
sona_xr_status |
What the last sona_xr_apply did, from sona_xr_status_get: tracked poses, eye height, scale, turn, placement, crouch, steps, the eyes' position |
This page as Markdown · All the docs as one file (llms-full.txt)