detphys3d_abi_version | This header's version (DETPHYS3D_ABI_VERSION) | detphys3d.h |
detphys3d_body_desc | Body settings (type DETPHYS3D_BODY_STATIC / KINEMATIC / DYNAMIC, position, integer quaternion, velocity, angular velocity, damping, gravity scale, flags [BULLET, NO_SLEEP, per-axis LOCK_*], tag, first shape). 176 B | detphys3d.h |
detphys3d_body_desc_default | Default body settings (dynamic body) | detphys3d.h |
detphys3d_body_view | Readback (ID, type, flags, tag, shape, integer position x_mm/y_mm/z_mm, floats for drawing). 96 B | detphys3d.h |
detphys3d_hull_info | Information about a registered hull | detphys3d.h |
detphys3d_kinematic | A 3D kinematic table (opaque) | detphys3d_kinematic.h |
detphys3d_kinematic_abi_version | This header's version (DETPHYS3D_KINEMATIC_ABI_VERSION) | detphys3d_kinematic.h |
detphys3d_kinematic_add | Creates a kinematic body with a motion and returns its ID. The shape is body->shape (add more with detphys3d_world_add_shape for a convex compound) | detphys3d_kinematic.h |
detphys3d_kinematic_bind | Gives an existing kinematic body a motion (replacing any previous one; snaps it to the current tick's pose at once and lifts the angular speed limit) | detphys3d_kinematic.h |
detphys3d_kinematic_check | Whether the raw bits of position, orientation, velocity and angular velocity in the world equal the values rebuilt from the functions (returns the number of differing bodies; 0 = all equal) | detphys3d_kinematic.h |
detphys3d_kinematic_clear | Removes all motions (bodies stay in the world; the session calls this before begin) | detphys3d_kinematic.h |
detphys3d_kinematic_create | Creates a kinematic table (NULL = defaults: split up to 4 times, 20 mm). One per world. It may be destroyed before or after the world | detphys3d_kinematic.h |
detphys3d_kinematic_destroy | Destroys it | detphys3d_kinematic.h |
detphys3d_kinematic_get_stats | Split counts and other statistics (the same detphys_kinematic_stats as 2D) | detphys3d_kinematic.h |
detphys3d_kinematic_pose | A pose returned by a callback (position [µm], integer quaternion). 40 B | detphys3d_kinematic.h |
detphys3d_kinematic_pose_at | The motion function's pose (also inside a tick with sub_milli 0–999, for interpolated drawing). The orientation is an integer quaternion scaled by DETPHYS3D_QUAT_ONE and rounded (it follows the continuous rotation, so qw is not always ≥ 0) | detphys3d_kinematic.h |
detphys3d_kinematic_session | Settings for passing a table to a session (the table, flags NO_PRE_UPDATE / NO_SPLIT) | detphys3d_kinematic.h |
detphys3d_kinematic_session_default | Default settings for passing a table to a session | detphys3d_kinematic.h |
detphys3d_kinematic_step | Advances one tick (instead of detphys3d_world_step; fast ticks are split into up to max_subticks pieces, then it updates). Returns the number of pieces | detphys3d_kinematic.h |
detphys3d_kinematic_unbind | Removes a motion (the body stays and keeps moving with its last velocity; set it to 0 with detphys3d_world_set_velocity to stop it) | detphys3d_kinematic.h |
detphys3d_kinematic_update | Snaps to the current tick's pose and sets the velocity and angular velocity that reach the next tick's pose (call after every detphys3d_world_step; calling it again changes nothing) | detphys3d_kinematic.h |
detphys3d_motion_desc | A motion (path DETPHYS3D_PATH_*, ease, flags, positions A / B, initial orientation [integer quaternion], spin axis, spin, orbit, ticks per one way, hold ticks at both ends hold_a_ticks / hold_b_ticks, phase, points, callback). 128 B | detphys3d_kinematic.h |
detphys3d_motion_desc_default | Default motion (FIXED, SMOOTH, spin axis y) | detphys3d_kinematic.h |
detphys3d_motion_point | A POINTS point (position in mm, angle around the spin axis in mrad, ticks to the next point). 24 B | detphys3d_kinematic.h |
detphys3d_shape_desc | One shape (DETPHYS3D_SHAPE_BOX / SPHERE / CAPSULE / HULL, size, center, orientation, material). 88 B | detphys3d.h |
detphys3d_shape_desc_default | Default shape settings (friction 600, density 1000000 = water, restitution 0, × 1000) | detphys3d.h |
detphys3d_snapshot_read_info | Reads an image header (no world needed) | detphys3d.h |
detphys3d_transfer_info | Transfer header (sizes of hulls, registry and image, tick; after a restore, flags [DETPHYS3D_TRANSFER_REBUILT_REGISTRY, REPLACED_HULLS]) | detphys3d.h |
detphys3d_transfer_read_info | Reads a transfer header (and verifies the checksum) | detphys3d.h |
detphys3d_world | A 3D world (opaque) | detphys3d.h |
detphys3d_world_add_body | Creates a body. Returns its ID (a serial number in creation order) | detphys3d.h |
detphys3d_world_add_hull | Builds and registers a convex hull from integer points (units_per_meter, 0 = mm). Returns its index; the same contents return the earlier index | detphys3d.h |
detphys3d_world_add_shape | Adds a shape to a body (compound bodies) | detphys3d.h |
detphys3d_world_apply_angular_impulse | Applies an angular impulse (mN·m·s) | detphys3d.h |
detphys3d_world_apply_force | Applies a force (mN, for the next tick only) | detphys3d.h |
detphys3d_world_apply_impulse | Applies an impulse (mN·s, changes the velocity at once) | detphys3d.h |
detphys3d_world_apply_torque | Applies a torque (mN·m, for the next tick only) | detphys3d.h |
detphys3d_world_body_count | Number of bodies created (removed ones included) | detphys3d.h |
detphys3d_world_body_shapes | Reads the shapes attached to a body | detphys3d.h |
detphys3d_world_create | Creates a world (NULL = defaults). NULL on failure | detphys3d.h |
detphys3d_world_desc | Tick rate, substeps, gravity xyz, 1–32 workers, pool (DETPHYS3D_POOL_OWN / BOX3D / EXTERNAL), flags (NO_SLEEP, NO_CONTINUOUS, SSE2), contact tuning (0 = Box3D's defaults). 88 B | detphys3d.h |
detphys3d_world_desc_default | Default world settings (60 Hz, 4 substeps, gravity (0, −10000, 0) mm/s², 1 worker, the core's pool) | detphys3d.h |
detphys3d_world_destroy | Destroys it | detphys3d.h |
detphys3d_world_engine_hash | Box3D's own state hash (for checking) | detphys3d.h |
detphys3d_world_get_body | Reads one body's current state | detphys3d.h |
detphys3d_world_get_desc | Reads the settings it was created with | detphys3d.h |
detphys3d_world_get_snapshot_stats | Snapshot status | detphys3d.h |
detphys3d_world_get_stats | Bodies, awake count, contacts, hull count and more | detphys3d.h |
detphys3d_world_hash | State hash (FNV-1a 64 over tick, body count and each body's position 3, quaternion 4, velocity 3, angular velocity 3 raw bits) | detphys3d.h |
detphys3d_world_hull_count | Number of registered hulls | detphys3d.h |
detphys3d_world_hull_info | Hull information (vertex, face and triangle counts, radius, checksum) | detphys3d.h |
detphys3d_world_hull_read | Reads a hull's vertices [m] and triangle indices for drawing | detphys3d.h |
detphys3d_world_read_bodies | Reads all bodies into an array (fine to call every frame) | detphys3d.h |
detphys3d_world_read_transforms | Light readback for drawing only (7 floats per body: position xyz [m], quaternion) | detphys3d.h |
detphys3d_world_remove_body | Removes a body (IDs are not reused) | detphys3d.h |
detphys3d_world_set_transform | Sets position and orientation directly (mm, integer quaternion) | detphys3d.h |
detphys3d_world_set_velocity | Sets velocity and angular velocity (mm/s, mrad/s) | detphys3d.h |
detphys3d_world_snapshot_restore | Restores a snapshot (the tick and body list too; registered hulls are kept; restoring a full one always starts a new shape version) | detphys3d.h |
detphys3d_world_snapshot_size | Measures the current snapshot size (default DETPHYS3D_SNAPSHOT_DEFAULT = FULL) | detphys3d.h |
detphys3d_world_snapshot_write | Writes a snapshot into a caller buffer | detphys3d.h |
detphys3d_world_stats | World status | detphys3d.h |
detphys3d_world_step | Advances one tick | detphys3d.h |
detphys3d_world_step_n | Advances count ticks (fewer calls when re-simulating after a rollback) | detphys3d.h |
detphys3d_world_tick | Current tick number | detphys3d.h |
detphys3d_world_transfer_restore | Restores a transfer (written by another world or device; rebuilds the registry or hull table first if they differ) | detphys3d.h |
detphys3d_world_transfer_size | Measures the state to send to another peer (transfer) | detphys3d.h |
detphys3d_world_transfer_write | Writes a transfer (full image + shape registry contents + hull table) | detphys3d.h |
detphys_abi_version | This header's version (DETPHYS_ABI_VERSION). Compare with >= at startup | detphys.h |
detphys_bake_abi_version | Version of this header (DETPHYS_BAKE_ABI_VERSION) | detphys_bake.h |
detphys_bake_alpha | Bake an alpha image (1 byte per pixel), an RGBA image (alpha is the 4th byte) or the bytes of a PNG file (rows top-down; up to 16384 x 16384 px). params may be NULL (the defaults). Always return a result (NULL only when memory runs out) | detphys_bake.h |
detphys_bake_data | The .dnshape bytes (NULL when the bake failed). Valid until the result is destroyed | detphys_bake.h |
detphys_bake_error | Why the bake failed (English, one sentence; empty on success) | detphys_bake.h |
detphys_bake_get_stats | Numbers about the bake (detphys_bake_stats) | detphys_bake.h |
detphys_bake_params | Units per m, pixels per m, alpha threshold, most vertices per piece (3–8), decomposition (DETPHYS_BAKE_STEINER = default, DETPHYS_BAKE_HM = Hertel-Mehlhorn), simplification tolerance (px), smallest bulge of a vertex (mm), smallest island (px), Steiner snap distance (mm) | detphys_bake.h |
detphys_bake_params_default | Default parameters (1000 units per m = mm, 128 px per m, alpha 128 or more is inside, 8 vertices per piece, Steiner, tolerance 1 px) | detphys_bake.h |
detphys_bake_png_alpha | Reads the alpha of a PNG without baking it (call with alpha = NULL to get the size first) | detphys_bake.h |
detphys_bake_read_outline | The simplified outline, for previews (loops and vertices in vertex units) | detphys_bake.h |
detphys_bake_result | A finished bake (opaque) | detphys_bake.h |
detphys_bake_result_destroy | Frees a result | detphys_bake.h |
detphys_bake_stats | Image size, pieces and their vertices, outline loops and vertices, holes filled, specks dropped, vertices removed, Steiner points, bounds, the tolerance used and the largest distance from the traced outline (mm) | detphys_bake.h |
detphys_bake_status | DETPHYS_OK, DETPHYS_BAKE_ERR_IMAGE (−20, the image could not be read), DETPHYS_BAKE_ERR_SHAPE (−21, no shape could be made) or DETPHYS_ERR_ARGUMENT / DETPHYS_ERR_INTERNAL | detphys_bake.h |
detphys_body_abi_version | This header's version | detphys_body.h |
detphys_body_desc | Body settings (type DETPHYS_BODY_STATIC / KINEMATIC / DYNAMIC, position, velocity, damping, flags [DETPHYS_BODY_FLAG_BULLET], tag, first shape) | detphys_body.h |
detphys_body_desc_default | Default body settings (dynamic body) | detphys_body.h |
detphys_body_view | Read-back state (ID, type, flags, tag, shape, integer pose x_mm/y_mm/angle_mrad, floats for drawing) | detphys_body.h |
detphys_build_info | One line of build information (compiler, CPU, floating-point settings, SIMD), for comparison logs | detphys.h |
detphys_debug_abi_version | This header's version | detphys_debug.h |
detphys_debug_body | One body in a 2D recording (raw bits of x, y, cos, sin, vx, vy, w) | detphys_debug.h |
detphys_debug_body3d | One body in a 3D recording (raw bits of x, y, z, qx, qy, qz, qw, vx, vy, vz, wx, wy, wz; hull = hull index; 136 B). Version 3 | detphys_debug.h |
detphys_debug_bundle_info | Bundle header | detphys_debug.h |
detphys_debug_bundle_info_get | Reads a bundle (DNDB) header and the positions of its two recordings | detphys_debug.h |
detphys_debug_cause_name | Cause name ("input", "physics", …) | detphys_debug.h |
detphys_debug_compare | Compares two recordings (first diverging tick, body, field, ULPs, cause, spread) | detphys_debug.h |
detphys_debug_config | Recording settings (dimensions 2 / 3; renamed from reserved in version 3) | detphys_debug.h |
detphys_debug_config_default | Default recording settings (600 ticks, 256 bodies, 32 input words, 16 state words, deep hash and types / shapes) | detphys_debug.h |
detphys_debug_diff | One differing field (body, field, values in A and B, ULPs) | detphys_debug.h |
detphys_debug_export | Writes a range of ticks as DNDR bytes | detphys_debug.h |
detphys_debug_field_name | Field name ("x", "vx", "qw", …) | detphys_debug.h |
detphys_debug_file_bodies | Reads the bodies of a tick (2D recordings only; 3D recordings return DETPHYS_ERR_FORMAT) | detphys_debug.h |
detphys_debug_file_bodies3d | Reads the bodies of a tick of a 3D recording (2D recordings return DETPHYS_ERR_FORMAT). Version 3 | detphys_debug.h |
detphys_debug_file_find_tick | Finds the index of a tick number | detphys_debug.h |
detphys_debug_file_info | Recording header (format_version 1 = 2D, 2 = 3D; 3D recordings have DETPHYS_DEBUG_FILE_3D in flags) | detphys_debug.h |
detphys_debug_file_info_get | Reads a recording (DNDR) header | detphys_debug.h |
detphys_debug_file_tick | Reads the tick at an index | detphys_debug.h |
detphys_debug_record | Records the world's current state (with inputs and state words) | detphys_debug.h |
detphys_debug_record3d | Records a 3D world's current state (into a recorder created with dimensions = 3; the recorded hash equals detphys3d_world_hash). Version 3 | detphys_debug.h |
detphys_debug_recorder_clear | Drops all recorded ticks | detphys_debug.h |
detphys_debug_recorder_init | Uses a caller buffer as a recorder | detphys_debug.h |
detphys_debug_recorder_size | Buffer size needed for a recorder | detphys_debug.h |
detphys_debug_recorder_stats | Recorder statistics | detphys_debug.h |
detphys_debug_recorder_stats_get | Recorder statistics | detphys_debug.h |
detphys_debug_report | Comparison result (cause, first diverging tick, first tick per kind, counts) | detphys_debug.h |
detphys_debug_session_config | Session debug settings | detphys_debug.h |
detphys_debug_session_config_default | Default session debug settings (off, 30-tick range, 4 reports, 10000 ms) | detphys_debug.h |
detphys_debug_session_report | One desync report (status, range, bytes, report, first difference) | detphys_debug.h |
detphys_debug_session_stats | Session debug counters | detphys_debug.h |
detphys_debug_tick | One tick's header (hash, deep hash [Box3D's in 3D], body count, word counts) | detphys_debug.h |
detphys_debug_write_file | Writes bytes to a file (UTF-8 path) | detphys_debug.h |
detphys_eos_abi_version | Version of this header (DETPHYS_EOS_ABI_VERSION) | detphys_eos.h |
detphys_eos_desc | Developer portal values (product ID, sandbox ID, deployment ID, client ID and client secret), product name and version, the name used to log in, cache folder, socket name, login timeout, log level, relay mode, flags | detphys_eos.h |
detphys_eos_desc_default | Default settings | detphys_eos.h |
detphys_eos_last_error | Why the last detphys_eos_link_create failed ("" if it did not) | detphys_eos.h |
detphys_eos_link_create | Creates an EOS transport (detphys_link). The first one initializes EOS and starts logging in with a device ID (the login continues inside detphys_link_poll, so you can call detphys_link_host / detphys_link_join without waiting). One at a time per process | detphys_eos.h |
detphys_eos_sdk_version | Version string of the loaded EOS SDK (to check where the SDK is and that it links) | detphys_eos.h |
detphys_eos_shutdown | Shuts EOS down. Call it once at the end of the process (if a transport still exists it does nothing and returns DETPHYS_LINK_E_STATE; afterwards no more EOS transports can be created in the same process) | detphys_eos.h |
detphys_kinematic | A kinematic table (opaque) | detphys_kinematic.h |
detphys_kinematic_abi_version | This header's version | detphys_kinematic.h |
detphys_kinematic_add | Creates a kinematic body with a motion (with Box2D's angular speed limit lifted) | detphys_kinematic.h |
detphys_kinematic_bind | Gives an existing body a motion | detphys_kinematic.h |
detphys_kinematic_check | Whether the world's values are bit-identical to the ones rebuilt from the functions | detphys_kinematic.h |
detphys_kinematic_clear | Removes all motions (the session calls this before begin) | detphys_kinematic.h |
detphys_kinematic_create | Creates a kinematic table (one per world) | detphys_kinematic.h |
detphys_kinematic_desc | Split settings (max_subticks 1–16, subtick_move_mm) | detphys_kinematic.h |
detphys_kinematic_desc_default | Default table settings (split up to 4 times, 20 mm) | detphys_kinematic.h |
detphys_kinematic_destroy | Destroys it | detphys_kinematic.h |
detphys_kinematic_get_stats | Split counts and other statistics | detphys_kinematic.h |
detphys_kinematic_pose | A pose returned by a callback [µm, µrad] | detphys_kinematic.h |
detphys_kinematic_pose_at | The motion function's pose (also between ticks, for interpolated drawing) | detphys_kinematic.h |
detphys_kinematic_session | Settings for passing a table to a session (flags NO_PRE_UPDATE / NO_SPLIT) | detphys_kinematic.h |
detphys_kinematic_session_default | Default settings for passing a table to a session | detphys_kinematic.h |
detphys_kinematic_stats | Table statistics | detphys_kinematic.h |
detphys_kinematic_step | Advances one tick (instead of detphys_world_step; splits fast ticks, then updates) | detphys_kinematic.h |
detphys_kinematic_unbind | Removes a motion | detphys_kinematic.h |
detphys_kinematic_update | Snaps to the current tick's pose and sets the velocity that reaches the next tick | detphys_kinematic.h |
detphys_link | A link (opaque) | detphys_link.h |
detphys_link_abi_version | The version of this header (DETPHYS_LINK_ABI_VERSION) | detphys_link.h |
detphys_link_close | Leaves the room | detphys_link.h |
detphys_link_create | Creates a link from an implementation table (detphys_link_vtable), to plug in your own transport | detphys_link.h |
detphys_link_create_hub | Creates a link to the test lobby | detphys_link.h |
detphys_link_create_loopback | A link wrapping one side of a loopback | detphys_link.h |
detphys_link_create_relay | Creates a connection interface (detphys_link) through your own relay. Rooms work with detphys_link_host / detphys_link_join | detphys_relay.h |
detphys_link_create_udp | A link over UDP (detphys_udp.h). The role is chosen at creation | detphys_link.h |
detphys_link_destroy | Destroys it (leaves the room) | detphys_link.h |
detphys_link_error | Text for the last failure (with NULL, why creating failed) | detphys_link.h |
detphys_link_get_info | State, role, path, reason, counters, room code | detphys_link.h |
detphys_link_host | Creates a room (become the host). The room code is made, or yours is used | detphys_link.h |
detphys_link_hub | A test lobby (opaque) | detphys_link.h |
detphys_link_hub_create | Creates / destroys a test lobby | detphys_link.h |
detphys_link_hub_desc | Test lobby settings (time per operation, room limit, path to report, datagram limit, per-room transport) | detphys_link.h |
detphys_link_hub_desc_default | Default test lobby settings | detphys_link.h |
detphys_link_hub_pump | Advances the test lobby's time by one | detphys_link.h |
detphys_link_hub_room_count | The number of rooms now | detphys_link.h |
detphys_link_info | State, role, path, reason, round trip, datagram limit, largest datagram sent, counters, kind, room code, descriptions of the other side and yourself | detphys_link.h |
detphys_link_join | Joins a room with a room code (become the guest). Typos are returned before any traffic | detphys_link.h |
detphys_link_poll | Call every frame. Returns the current state | detphys_link.h |
detphys_link_room_desc | Room settings (members, bucket, room code, seed for making a code, timeout) | detphys_link.h |
detphys_link_room_desc_default | Default room settings | detphys_link.h |
detphys_link_state_name | ASCII names of states and reasons (translation keys) | detphys_link.h |
detphys_link_transport | Gets the transport to pass to the session (the link counts what is sent and received) | detphys_link.h |
detphys_link_vtable | An implementation table (send, recv and get_info are required; poll, host, join, wait, error, close and destroy are optional) | detphys_link.h |
detphys_link_wait | Waits until something can be received (headless tests) | detphys_link.h |
detphys_loopback | A loopback (opaque) | detphys_turn.h |
detphys_loopback_create | Creates a loopback joining two peers in one process | detphys_turn.h |
detphys_loopback_desc | Delay, loss and duplication rates, seed | detphys_turn.h |
detphys_loopback_desc_default | Default loopback settings (no delay, no loss) | detphys_turn.h |
detphys_loopback_destroy | Destroys it | detphys_turn.h |
detphys_loopback_get_stats | Sent, dropped, duplicated, delivered counts | detphys_turn.h |
detphys_loopback_pump | Advances time by one (the unit of delay) | detphys_turn.h |
detphys_loopback_stats | Loopback counters | detphys_turn.h |
detphys_loopback_transport | Gets the transport of side 0 or 1 | detphys_turn.h |
detphys_mesh_info | Information about a registered shape | detphys_body.h |
detphys_motion_desc | A motion (path DETPHYS_PATH_*, ease, position, spin, orbit, period, phase, points, callback) | detphys_kinematic.h |
detphys_motion_desc_default | Default motion (FIXED, SMOOTH) | detphys_kinematic.h |
detphys_motion_point | A POINTS point (position, angle, ticks to the next point) | detphys_kinematic.h |
detphys_relay_abi_version | Version of this header (DETPHYS_RELAY_ABI_VERSION) | detphys_relay.h |
detphys_relay_desc | Relay host and port, local port, resend and PING intervals, timeout when nothing arrives | detphys_relay.h |
detphys_relay_desc_default | Default settings for connecting to the relay | detphys_relay.h |
detphys_room_code_make | Makes a room code (six digits) from a seed | detphys_link.h |
detphys_room_code_parse | Checks typed text and normalizes it to six digits (skips full-width digits and separators; format error / check digit error) | detphys_link.h |
detphys_rt_abi_version | This header's version | detphys_rt.h |
detphys_rt_advance | Passes your input and advances one tick (rolling back and re-simulating if needed). Returns ADVANCED / STALLED / SYNC_WAIT / DELAY_WAIT | detphys_rt.h |
detphys_rt_auto_delay | Automatic input delay settings | detphys_rt.h |
detphys_rt_auto_delay_default | Default automatic input delay (off, 0–6, jitter × 1, raise after 500 ms, lower after 3000 ms) | detphys_rt.h |
detphys_rt_config | Settings (session id, shapes, peer, world, input delay 0–30, prediction window 0–60, hash checks, snapshots, workers, network values) | detphys_rt.h |
detphys_rt_config_default | Default settings (delay 0, N 10, hash check every tick, each hash in 2 packets, dyn, 1 worker, 4 bases, time sync at 1 tick, 100 ms keepalive, 5000 ms peer timeout) | detphys_rt.h |
detphys_rt_config_default3d | Fills session settings (snapshot FULL) and 3D world settings with defaults (either may be NULL) | detphys_rt.h |
detphys_rt_confirmed | A confirmed tick record | detphys_rt.h |
detphys_rt_create | Creates a session (creates the world, registers shapes, calls begin) | detphys_rt.h |
detphys_rt_create3d | Creates a 3D session (NULL world settings = defaults). Then poll → advance → next_confirmed as in 2D | detphys_rt.h |
detphys_rt_create3d_kinematic | Same as detphys_rt_create3d, also passing a 3D table | detphys3d_kinematic.h |
detphys_rt_create_kinematic | Same, also passing a kinematic table (moving concave shapes) | detphys_rt.h |
detphys_rt_create_push | Creates a push session (the simplest entry point; with a moving field it also creates the table and destroys it with detphys_rt_destroy). NULL on failure | detphys_rt.h |
detphys_rt_create_push3d | Creates a 3D push session (the simplest entry point; NULL world settings = defaults; with the turntable it also creates the table and destroys it with detphys_rt_destroy). NULL on failure | detphys_rt.h |
detphys_rt_ctx | Values passed to callbacks (world, params, state, tick, peer, re-simulating) | detphys_rt.h |
detphys_rt_ctx3d | Values passed to callbacks (same layout as detphys_rt_ctx; only world is a detphys3d_world*) | detphys_rt.h |
detphys_rt_debug_bundle | Packs a report and both recordings into a bundle | detphys_rt.h |
detphys_rt_debug_count | Number of reports | detphys_rt.h |
detphys_rt_debug_get | Reads a report | detphys_rt.h |
detphys_rt_debug_nudge_at | Test only: shifts the state by 1 ULP after that tick | detphys_rt.h |
detphys_rt_debug_stats | Recording and exchange counters | detphys_rt.h |
detphys_rt_destroy | Destroys it | detphys_rt.h |
detphys_rt_error | Reason when in ERROR | detphys_rt.h |
detphys_rt_frame | Result of advance (tick, input tick, confirmed tick, re-simulated ticks, flags [DETPHYS_RT_FRAME_*; version 7 added DETPHYS_RT_FRAME_TAG_MISMATCH], round trip) | detphys_rt.h |
detphys_rt_get_link_info | Current link and delay status | detphys_rt.h |
detphys_rt_get_resync_info | What was sent / received on resync and rejoin (counts, registry rebuilds, size, restore time). Works for 2D too | detphys_rt.h |
detphys_rt_get_stats | Counters for rollbacks, re-simulation, waits, hash checks, resyncs, bytes and time | detphys_rt.h |
detphys_rt_get_tag_info | Reads what a peer with a mismatching config check sends (the same detphys_tag_info as turn-based). Read it when DETPHYS_RT_FRAME_TAG_MISMATCH is set. Version 7 | detphys_rt.h |
detphys_rt_kinematic | The kinematic table a session is moving (read only; NULL if none) | detphys_rt.h |
detphys_rt_kinematic3d | The 3D table a real-time session is moving (read only; NULL if none) | detphys3d_kinematic.h |
detphys_rt_link_info | Link and delay status | detphys_rt.h |
detphys_rt_next_confirmed | Takes the oldest confirmed tick record (tick, hash), for replays and logs | detphys_rt.h |
detphys_rt_next_input_tick | The tick the next advance's input goes to | detphys_rt.h |
detphys_rt_poll | Reads what arrived; sends acks and resync state | detphys_rt.h |
detphys_rt_read_state | Current game state words | detphys_rt.h |
detphys_rt_resync_info | Resync status (dimensions 2 / 3, sent, received, registry_rebuilds, hull_replacements, last size, tick and time) | detphys_rt.h |
detphys_rt_rule | A rule (1–16 input words, 0–64 state words, params, begin, apply_inputs, after_tick, predict) | detphys_rt.h |
detphys_rt_rule3d | A 3D rule (same layout as detphys_rt_rule; callbacks receive detphys_rt_ctx3d; 72 B) | detphys_rt.h |
detphys_rt_rule_push | Writes only the push rule (to wrap the rule or use your own table; with a moving field put the table in rule.user and call detphys_rt_create_kinematic) | detphys_rt.h |
detphys_rt_rule_push3d | Writes only the 3D push rule (a detphys_rt_rule3d; to wrap the rule or use your own table; with the turntable put a detphys3d_kinematic* in rule.user and call detphys_rt_create3d_kinematic) | detphys_rt.h |
detphys_rt_session | A session (opaque) | detphys_rt.h |
detphys_rt_set_auto_delay | Sets automatic input delay (NULL = off) | detphys_rt.h |
detphys_rt_set_debug | Turns the desync debugger on / off | detphys_rt.h |
detphys_rt_set_link_id | Your link id | detphys_rt.h |
detphys_rt_stats | Session counters | detphys_rt.h |
detphys_rt_world | Current world (including predictions; read it for drawing) | detphys_rt.h |
detphys_rt_world3d | The current 3D world (includes prediction; read it for drawing). For 3D sessions detphys_rt_world returns NULL | detphys_rt.h |
detphys_rule_ctx | Values passed to callbacks (world, params, state, mover, turn, tick, settled) | detphys_turn.h |
detphys_rule_ctx3d | Values passed to callbacks (same layout as detphys_rule_ctx; only world is a detphys3d_world*) | detphys_turn.h |
detphys_rule_push3d_auto_inputs | The samples' automatic inputs (ticks 0..ticks, 3 words per tick), for comparing with the reference hashes | detphys_rt.h |
detphys_rule_push3d_desc | 3D push settings (144 B: box / sphere / hull counts, boxes that can be dropped, seed, floor / wall / player sizes, force, speed, jump, dash, drop interval, object sizes, density and friction, turntable field [NONE 0, TURNTABLE 1], spin and center, predict [DETPHYS_RULE_PUSH_PREDICT_*], table split settings kinematic_*) | detphys_rt.h |
detphys_rule_push3d_desc_default | Default 3D push settings (40 boxes, 8 spheres, 12 hulls, up to 24 dropped boxes per player, seed 0x5EED0036, no turntable [800 mrad/s, center (0, +7 m)], REPEAT prediction) | detphys_rt.h |
detphys_rule_push3d_get_layout | IDs of the bodies and hulls begin creates (floor 0, walls 1–4, players 5 and 6, boxes, spheres, hulls, turntable, then boxes dropped during the match), without creating a session | detphys_rt.h |
detphys_rule_push3d_layout | The body ID layout (turntable table_body, dropped boxes first_dropped), hull IDs (stones hull_types, turntable disc table_hull) and the params size (88 or 104 bytes) | detphys_rt.h |
detphys_rule_push_desc | Push settings (144 B: box and shape counts, seed, floor / wall / player sizes, force, speed, jump, dash, moving field field [GEAR 1, PLATFORM 2, LIFT 4, ALL 7], speed %, drop height, mesh indices, predict [REPEAT / RELEASED], table split settings kinematic_*) | detphys_rt.h |
detphys_rule_push_desc_default | Default push settings (60 boxes, 12 concave shapes, 8 meshes, half floor width 12000 mm, no moving field, REPEAT prediction) | detphys_rt.h |
detphys_rule_push_get_layout | IDs of the bodies begin creates (floor 0, walls 1 and 2, players 3 and 4, boxes, shapes, moving field), without creating a session | detphys_rt.h |
detphys_rule_push_layout | The body ID layout and the params size (88 or 120 bytes) | detphys_rt.h |
detphys_rule_stack_desc | Drop clearance, range, fall line, material, base boxes (1–16) | detphys_turn.h |
detphys_rule_stack_desc_default | Default stacking settings (base 7 m wide, 0.6 m high, top at y = 0; drop clearance 300 mm; x range ±5000 mm; fall line −1000 mm) | detphys_turn.h |
detphys_rule_stack_next | Next shape (mode SEED / INPUT, seed, draw UNIFORM / BAG, per_match, weights, preview 0–8) | detphys_turn.h |
detphys_rule_stack_next_default | Default next-shape settings (SEED, UNIFORM, a different sequence per match, equal weights, 2 shapes ahead) | detphys_turn.h |
detphys_rule_stack_next_shape | With SEED, computes the shape of match m, turn t (no session needed) | detphys_turn.h |
detphys_shape_desc | One shape (DETPHYS_SHAPE_MESH / BOX / CIRCLE, size, offset, material) | detphys_body.h |
detphys_shape_desc_default | Default shape settings (friction 600, density 1000, restitution 0, × 1000) | detphys_body.h |
detphys_snapshot_info | Image header (kind, size, body count, tick, base id) | detphys.h |
detphys_snapshot_read_info | Reads a snapshot image header (no world needed) | detphys.h |
detphys_snapshot_stats | Snapshot statistics (for tuning) | detphys.h |
detphys_tag_info | State of a peer whose config check does not match (136 B, the same as for rt; see the section below) | detphys_turn.h |
detphys_transport | The transport interface (send, recv and user). Implement this for Steam, EOS and so on | detphys_turn.h |
detphys_turn_abi_version | This header's version | detphys_turn.h |
detphys_turn_box | A static box [mm] | detphys_turn.h |
detphys_turn_checkpoint_stats | Guest checkpoint statistics | detphys_turn.h |
detphys_turn_config | Session settings (session id, shapes, peer, first mover, tick limit, world, network values) | detphys_turn.h |
detphys_turn_config_default | Default session settings (up to 900 ticks per turn, 5000 ms peer timeout, 20 ms minimum resend, 250 ms keepalive) | detphys_turn.h |
detphys_turn_create_rule | Creates a session with a rule | detphys_turn.h |
detphys_turn_create_rule3d | Creates a session from a 3D rule and 3D world settings (detphys3d_world_desc, NULL = defaults). The world is rebuilt for every match | detphys_turn.h |
detphys_turn_create_rule3d_kinematic | Same as detphys_turn_create_rule3d, also passing a 3D table (emptied before begin_match of every match) | detphys3d_kinematic.h |
detphys_turn_create_rule_kinematic | Same, also passing a kinematic table (moving concave shapes) | detphys_turn.h |
detphys_turn_create_stack | Creates a session with that rule | detphys_turn.h |
detphys_turn_create_stack_ex | Creates a stacking session (the easy way from C# and others) | detphys_turn.h |
detphys_turn_current | Current turn number | detphys_turn.h |
detphys_turn_current_mover | Current mover | detphys_turn.h |
detphys_turn_debug_bundle | Packs a report and both recordings into a bundle (DNDB) | detphys_turn.h |
detphys_turn_debug_count | Number of reports | detphys_turn.h |
detphys_turn_debug_get | Reads a report (with the list of differences and the spread) | detphys_turn.h |
detphys_turn_debug_nudge_at | Test only: shifts the state by 1 ULP at the start of that turn | detphys_turn.h |
detphys_turn_debug_stats | Recording and exchange counters | detphys_turn.h |
detphys_turn_desc | Settings, input, report and shape for the functions above | detphys_turn.h |
detphys_turn_desc_default | Create a session from stacking-only settings (uses the built-in stacking rule) | detphys_turn.h |
detphys_turn_destroy | Destroys it | detphys_turn.h |
detphys_turn_error | Reason when in ERROR | detphys_turn.h |
detphys_turn_get_checkpoint_stats | Checkpoint counts, sizes and times | detphys_turn.h |
detphys_turn_get_link_stats | Round trip, resends, bytes, … | detphys_turn.h |
detphys_turn_get_status | Current status (turn, match, mover, world replacement counter, time since the last packet, …) | detphys_turn.h |
detphys_turn_get_tag_info | Reads what a peer with a mismatching config check sends (detphys_tag_info) / returns a part's name. Version 9. See the section below | detphys_turn.h |
detphys_turn_kinematic3d | The 3D table a turn-based session is moving (read only; NULL if none) | detphys3d_kinematic.h |
detphys_turn_link_stats | Network statistics | detphys_turn.h |
detphys_turn_mesh | Shape data (.dnshape bytes) | detphys_turn.h |
detphys_turn_next_report | Takes one turn's report (detphys_turn_report) | detphys_turn.h |
detphys_turn_next_result | Takes one finished turn's result (with inputs and state) | detphys_turn.h |
detphys_turn_poll | Reads what arrived, advances up to max_ticks, sends (resends by count; for in-process tests) | detphys_turn.h |
detphys_turn_poll_at | Same, with the engine's monotonic clock [µs] (use this on real networks) | detphys_turn.h |
detphys_turn_read_state | Reads the current match state words | detphys_turn.h |
detphys_turn_result | One turn's result (hashes, bytes, turn, mover, next mover, ticks, flags [DETPHYS_TURN_FLAG_*]) | detphys_turn.h |
detphys_turn_rule | A rule (input and state word counts, params, begin_match, check_input, apply_input, after_tick, end_turn) | detphys_turn.h |
detphys_turn_rule3d | A 3D rule (same layout as detphys_turn_rule; callbacks receive detphys_rule_ctx3d; 80 B) | detphys_turn.h |
detphys_turn_rule_stack | Writes the stacking rule where the input picks the shape (3 input words) | detphys_turn.h |
detphys_turn_rule_stack_ex | Writes the stacking rule (with the next-shape settings) | detphys_turn.h |
detphys_turn_session | A session (opaque) | detphys_turn.h |
detphys_turn_set_checkpoint_kind | Kind of the guest's per-turn checkpoint (FULL default / DYNAMIC / LEGACY) | detphys_turn.h |
detphys_turn_set_debug | Turns the desync debugger on / off (detphys_debug_session_config) | detphys_turn.h |
detphys_turn_set_link_id | Your link id (a different value after a restart) | detphys_turn.h |
detphys_turn_set_peer_timeout | Peer timeout (until PEER_LOST) | detphys_turn.h |
detphys_turn_set_timing | Minimum resend time and keepalive interval | detphys_turn.h |
detphys_turn_state | Current state (DETPHYS_TURN_CONNECTING, WAIT_LOCAL_INPUT, WAIT_REMOTE_INPUT, SIMULATING, WAIT_HASH, WAIT_RESYNC, ERROR, DETPHYS_TURN_PEER_LOST) | detphys_turn.h |
detphys_turn_status | Current status | detphys_turn.h |
detphys_turn_submit | Submits a stacking input (shape, x, angle) | detphys_turn.h |
detphys_turn_submit_words | Submits the mover's input (int32 × input_words) | detphys_turn.h |
detphys_turn_world | Current world (read only) | detphys_turn.h |
detphys_turn_world3d | The current 3D world (read only). For 3D sessions detphys_turn_world returns NULL | detphys_turn.h |
detphys_udp | A socket (opaque) | detphys_udp.h |
detphys_udp_create | Creates a socket (DETPHYS_UDP_LISTEN to listen / DETPHYS_UDP_CONNECT to connect; IPv4) | detphys_udp.h |
detphys_udp_desc | Mode (LISTEN / CONNECT), address, port, buffer sizes | detphys_udp.h |
detphys_udp_desc_default | Default settings | detphys_udp.h |
detphys_udp_destroy | Destroys it | detphys_udp.h |
detphys_udp_get_stats | Sent and received counts and so on | detphys_udp.h |
detphys_udp_last_error | Description of the last failure | detphys_udp.h |
detphys_udp_peer | Current peer address ("a.b.c.d:port") | detphys_udp.h |
detphys_udp_stats | UDP counters | detphys_udp.h |
detphys_udp_transport | Gets the transport to pass to a session | detphys_udp.h |
detphys_udp_wait | Waits until something can be received (for headless tests; engines poll every frame) | detphys_udp.h |
detphys_world | A world (opaque) | detphys.h |
detphys_world_add_body | Creates a body. Returns its ID (creation-order serial number) | detphys_body.h |
detphys_world_add_mesh | Copies and registers a .dnshape. Returns its number (from 0) | detphys_body.h |
detphys_world_add_shape | Adds a shape to a body | detphys_body.h |
detphys_world_apply_force | Applies a force (mN, for the next tick only) | detphys_body.h |
detphys_world_apply_impulse | Applies an impulse (mN·s, changes velocity at once) | detphys_body.h |
detphys_world_awake_count | Awake dynamic bodies (0 = settled) | detphys_body.h |
detphys_world_body_count | Bodies created (including removed ones) | detphys_body.h |
detphys_world_body_shapes | Reads the shapes attached to a body | detphys_body.h |
detphys_world_create | Creates a world (NULL = defaults). Same as detphys_world_create_ex(desc, NULL) | detphys.h |
detphys_world_create_ex | Creates a world with settings and worker settings | detphys.h |
detphys_world_desc | Tick rate, substeps, gravity (mm/s²) | detphys.h |
detphys_world_desc_default | Default world settings (60 Hz, 4 substeps, gravity (0, −10000) mm/s²) | detphys.h |
detphys_world_destroy | Destroys a world | detphys.h |
detphys_world_get_body | Reads one body's current state | detphys_body.h |
detphys_world_get_options | Reads the worker settings used at creation | detphys.h |
detphys_world_get_snapshot_stats | Bases held, shape version, write counts and so on | detphys.h |
detphys_world_hash | State hash (FNV-1a 64 over the tick, body count and raw bits of every body's position, rotation, velocity and angular velocity) | detphys.h |
detphys_world_mesh_count | Number of registered shapes | detphys_body.h |
detphys_world_mesh_info | Shape information (convex polygons, vertices, radius, checksum) | detphys_body.h |
detphys_world_mesh_read | Reads the convex polygons' vertices [m] for drawing | detphys_body.h |
detphys_world_options | Worker count (1–64), pool (DETPHYS_POOL_OWN / BOX2D / EXTERNAL), spin, base slots, engine job functions | detphys.h |
detphys_world_options_default | Default worker settings (1 worker, core pool, spin 4000, 4 bases) | detphys.h |
detphys_world_read_bodies | Reads all bodies into an array (fine every frame; does not affect the simulation) | detphys_body.h |
detphys_world_remove_body | Removes a body (IDs are not compacted) | detphys_body.h |
detphys_world_set_transform | Sets position and angle directly (mm, mrad) | detphys_body.h |
detphys_world_set_velocity | Sets velocity (mm/s, mrad/s) | detphys_body.h |
detphys_world_snapshot_restore | Restores a snapshot (the tick and the body list come back too; restoring a full one always starts a new shape version, so the next dyn takes a new base) | detphys.h |
detphys_world_snapshot_size | Counts the size of a snapshot of the current state (dyn / full) | detphys.h |
detphys_world_snapshot_write | Writes a snapshot into a caller buffer (takes a base here if a dyn has none) | detphys.h |
detphys_world_step | Advances one tick | detphys.h |
detphys_world_tick | Current tick number (0 right after creation) | detphys.h |