Core and the app · crate

kinogaki-document

Core

Studio's document: the scene, a tree of objects under one root, and the core network each object of a kind naming a context holds.

Repository
Core and the app (kinogaki/studio-core)
Folder
studio/core/document
Source
43 files, 8,481 lines
Tests
14 files, 3,272 lines
depends onused by tests alonedependencies for tests alone are listed below, not drawn

What it is

Studio's document: the scene, a tree of objects under one root, and the core network each object of a kind naming a context holds.

Objects. An object is a name unique beside its siblings, a transform and pivot, the outliner's flags, a tile position at its object level, its children and its body: core's Part, a package's ObjectBody or a Placeholder (an object no installed package reads, kept as its project held it). What a body is beyond that is its kind's (kinds); the document names no kind but the Part.

Sharing. Objects, bodies and networks are shared (Arc) between the document, undo snapshots and workers. Copying a scene copies one map of pointers; editing an object copies that object alone, and editing its network copies that network alone. Scenes compare by pointer first, so an unchanged snapshot costs nothing to compare.

The document (Document): the scene with its frame range, undo history and gestures, where the user is (Location), the selections and the packages' session slots. Document::transact is the one way the scene changes.

Packages. What is installed is core/network's registry (kinogaki_network::registry::install): one install per package admits its contexts, node types and data types there and its object kinds, stored values, slots and formats with them, which the document reads from the installed packages.

Depends on

CrateRepositoryAsWhat it is
kinogaki-animCore and the appnormalStudio's animation channels.
kinogaki-color-serviceCore and the appnormalStudio's color service: the OpenColorIO config (lib-color's built-in ACES 2.0 CG config, or a file), the working space, and the viewer's display, view, look, exposure and gamma.
kinogaki-core-packageCore and the appnormalCore's own SDK package (kinogaki.core): what Studio holds whatever plugins are installed.
kinogaki-mathlib-mathnormalKinogaki's vectors, points, matrices, quaternions and deterministic elementary functions.
kinogaki-networkCore and the appnormalStudio's core networks (design: core-owned networks; "Cooking DAG for nodes is studio core").
kinogaki-render-apiSDKnormalKinogaki's render interface: what a host (Studio) sends a render engine and what comes back, with no GPU or OS API.
kinogaki-studio-apiSDKnormalKinogaki Studio's headless plugin API.

For its tests alone

CrateRepositoryAsWhat it is
kinogaki-prismlib-prismtestsPrism documents for Kinogaki.
kinogaki-testkitCore and the apptestsKinogaki Studio's core testkit: toy packages written against the SDK alone, so core is tested with no real plugin.

Third-party

CrateVersionLicenceFrozen inAsAlso used by
thiserror2.0.21MIT OR Apache-2.0lib-ui/vendornormalkinogaki-lsystem, kinogaki-network, kinogaki-shared, kinogaki-ui-wgpu

Used by

CrateRepositoryAsWhat it is
kinogaki-editorCore and the appnormalKinogaki Studio's editor: the document and everything the window shows of it, as parts one frame borrows one by one.
kinogaki-image-pipelineCore and the appnormalImagePipeline: what renders become on screen and in files.
kinogaki-projectCore and the appnormalStudio's project files: a document as a Prism document.
kinogaki-sceneCore and the appnormalStudio's scene: the document cooked object by object.
kinogaki-testkitCore and the appnormalKinogaki Studio's core testkit: toy packages written against the SDK alone, so core is tested with no real plugin.

Modules

Public types and traits

At the crate root

Structs DocumentFlagsGridSettingsKindSheetNodePicksObjectPlacePlaceholderPlacementsPlacerProjectSettingsSceneSnapshotTransactionTransform

Enums BodyFlagGridModeLocationOpenedSwatch

Type aliases Worlds

Re-exported from other crates

From kinogaki_network NodeIdObjectId

By module: 45 public types and traits in 22 modules

clipboard ClipCopiedDestinationNetworkAtNodeLinkPasted

document Document

document::history Snapshot

document::location LocationOpened

document::picks NodePicks

document::placements PlacementsPlacer

document::transaction Transaction

kinds CreationKind

object Object

object::body BodyPlaceholder

object::flags FlagFlags

object::sheet KindSheetSwatch

object::transform Transform

paths HolderTarget

paths::follow Reference

paths::op ImageReadOpReadOpReference

scene PlaceSceneWorlds

scene::assets AssetAssetsMainPlace

scene::images ImageAt

scene::tree Duplicated

settings GridModeGridSettingsProjectSettings

time PacePlaybackSceneTimeTimeRange

Besides these, 14 public functions at module level.