Skip to main content

Module render

Module render 

Source
Expand description

Rendering, texture, mesh, material, scene, camera, and presentation contracts.

This namespace intentionally exposes no placeholder renderer or presenter. Stateful rendering and presentation types are admitted only with explicit runtime ownership, synchronization, failure, and lifecycle behavior.

Structs§

Aabb
Axis-aligned bounding box.
Camera
Semantic camera value.
CanvasGridFrame
Parameters for one procedural canvas-grid frame.
FlatColorMaterial
Solid-color material for UI elements and debug geometry.
MaterialId
Stable identity of one material in a Scene. Zero is invalid.
MeshData
Indexed triangle-list mesh snapshot.
MeshVertex
CPU vertex contract used by the first scene compiler.
RenderFrame
Generation-safe lease for one submitted headless target.
Renderer
Runtime-borrowing headless render-to-texture session.
RendererConfig
Configuration for one headless Renderer target ring.
Scene
Caller-owned CPU semantic scene snapshot.
SceneDrawPacket
Per-node draw range produced by compile_scene_packets.
SceneMaterial
Named material entry in a semantic scene.
SceneMesh
Named immutable mesh value in a semantic scene.
SceneMeshId
Stable identity of one mesh in a Scene. Zero is invalid.
SceneNode
One hierarchy node that optionally instances a mesh.
SceneNodeId
Stable identity of one node in a Scene. Zero is invalid.
SurfaceMaterial
Metallic/roughness PBR material for scene geometry.
Texture
Packed RGBA8 texture value reusable by Render, Presenter, Image, and UI.
TextureHandle
Opaque index into the owning Scene’s texture registry.
UnlitMaterial
Textured unlit material for image and video display.

Enums§

AlphaMode
Alpha blending mode for UnlitMaterial and SurfaceMaterial.
CameraProjection
Projection kind for a Camera.
Material
Semantic material value — CPU-side only, no GPU handles.

Functions§

blit
Deep-copy a packed Texture into independent device storage.
clear
Return an independent packed Texture filled with one RGBA8 clear color.
compile_scene
Compile visible scene instances into one deterministic indexed mesh snapshot.
compile_scene_packets
Compile visible scene nodes into a merged MeshData and one SceneDrawPacket per visible node that contributes geometry.
compute_bounds
Recompute and store the tight axis-aligned bounding box for mesh.
create_cube
Create a 3D axis-aligned cube (12 triangles, 24 vertices, size × size × size).
create_fullscreen_quad
Create a fullscreen NDC quad (2 triangles, 4 vertices) in [-1, 1] XY with top-origin image UVs. Used for post-processing passes.
create_quad
Create a centered quad (2 triangles, 4 vertices) with top-origin image UVs.
flip_uvs_y
Flip all vertex UVs vertically (V ← 1 − V).
save_texture_file
Read and save one packed RGBA8 Texture using its path extension.
scale
Scale all vertex positions and normals.
texture_from_file
Decode a still-image file directly into a packed RGBA8 Texture.
texture_from_file_on
Decode a still-image file directly into a packed RGBA8 Texture on a particular runtime.
texture_from_image
Convert one packed RGBA8 HWC image into an independent Texture value.
texture_from_rgba8
Upload one exact packed row-major RGBA8 host image as a Texture.
texture_from_rgba8_on
Upload one exact packed row-major RGBA8 host image as a Texture on a particular runtime.
transform
Apply an affine matrix to all vertex positions and normals.
translate
Translate all vertex positions in-place.
validate_scene
Validate one scene without retaining or uploading it.