@konitif/physics
v0.285.2
Published
Headless physics backend lifecycle, commands and observations with explicit providers.
Readme
@konitif/physics
Headless physics lifecycle, command and observation contracts with explicit backend providers.
Installation
npm install @konitif/physicsWhat it provides
PhysicsServicefor backend selection, articulated-subject loading, stepping and disposal.NoopPhysicsBackendfor an explicitly inactive simulation boundary.- Data-only collider, simulation and observation profiles.
- Worker protocol contracts and
PhysicsWorkerBackendAdapterthrough a separate entry point.
Authority boundary
The package coordinates a selected backend but includes no physics engine, model asset, scheduler, renderer or domain policy. An admitted command is not proof of a physical effect, and a simulation observation is not evidence of external-system execution. Hosts provide engines, clocks and model-specific rules.
Quick start
import { PhysicsService } from '@konitif/physics';
const physics = new PhysicsService();
await physics.loadSubject({ id: 'fixture', kind: 'custom' });
physics.setJointTarget('slider', { value: 0.5 });
physics.dispose();The default backend records targets but does not simulate. Supply explicit
backendFactories, select a backend and enable the service for real stepping.
PhysicsSubjectSource describes the admitted physical source independently of
its visual projection or domain-specific identity.
Public entry points
| Entry | Purpose |
| --- | --- |
| @konitif/physics | Service lifecycle, backend and physics data contracts. |
| @konitif/physics/worker | Worker protocol and explicit-host transport adapter. |
Reference
See reference/ for the machine-readable capability catalog and
authority diagrams. Profiles describe authored inputs; they do not apply
themselves to a backend.
License
Source-available under PolyForm Noncommercial 1.0.0, not OSI open source. Commercial use requires separate written authorization.
