Skip to main content

Crate brass_foundry

Crate brass_foundry 

Source
Expand description

Build-time geometry compiler for the Brass Poolrooms visual universe.

Applications author three-dimensional Model dies and forge them into compact, colored two-dimensional triangle meshes. Projection, illumination, material response, visibility, and shadows share the exact laws used by Poolrooms’ own mechanisms.

Structs§

Mesh
A compact two-dimensional mesh forged from a three-dimensional die.
Model
An application-authored three-dimensional die.
Pixel
One projected, illuminated vertex in a forged mesh.
RustDialect
Runtime type names used by generated Rust mesh bindings.
Vec3
A point, vector, or normal in the common fixed-camera universe.
Vertex
A model vertex carrying one physically meaningful surface normal.

Enums§

Charge
The three canonical bronze charges.
RustReach
Rust visibility assigned to one emitted mesh binding.

Constants§

BRONZE_BODY
Oxidized-bronze body charge.
BRONZE_GLINT
Polished-bronze highlight charge.
BRONZE_SHADOW
Oxidized-bronze shadow charge.
DARK_AMBIENT
Work-darkened metal ambient response.
DARK_BROAD_SHINE
Work-darkened metal broad-reflection exponent.
DARK_BROAD_WEIGHT
Work-darkened metal broad-reflection weight.
DARK_DIFFUSE_WEIGHT
Work-darkened metal diffuse weight.
DARK_EXPOSURE
Work-darkened bronze output exposure.
DARK_GLINT_SHINE
Work-darkened metal glint exponent.
DARK_GLINT_WEIGHT
Work-darkened metal glint weight.
DARK_REFLECTION_CELL
Largest interpolation cell admitted by the dark-bronze reflection lobe.
DARK_TONE_CEILING
Work-darkened metal response ceiling.
EYE_Z
Fixed perspective eye above the assembly plane, in logical points.
HALF_Y
Down-screen component of the fixed halfway vector.
HALF_Z
Viewer-facing component of the fixed halfway vector.
LIGHT_Y
Down-screen component of the fixed distant illuminant.
LIGHT_Z
Viewer-facing component of the fixed distant illuminant.
METAL_SHINE
Ordinary bare-metal specular exponent.
MIRROR_SHINE
Mirror-polished metal specular exponent.

Functions§

bronze_rgb
Interpolate the canonical bronze charge at one illumination tone.
compile_with
Forge visible facets with an application-supplied material response.
darkened_bronze_rgb
Apply the foundry’s oxide exposure to a bronze response.
darkened_lit
Illuminate work-darkened bronze.
darkened_lit_with_key
Illuminate work-darkened bronze with explicit key visibility.
darkened_metal_tone
Return work-darkened material tone at one point and normal.
darkened_metal_tone_with_key
Return work-darkened tone with explicit geometric key visibility.
depth
Return the painter-order depth of one facet.
emit_rust
Emit one mesh as static Rust data.
emit_rust_as
Emit one mesh using equivalent consumer-owned runtime type names.
forge
Forge a die with one canonical material charge.
lit
Illuminate bare bronze.
lit_with_key
Illuminate bare bronze with explicit key visibility.
material_terms
Return diffuse and Blinn-Phong reflection terms under the fixed key.
metal_tone
Return bare-bronze material tone at one point and normal.
metal_tone_with_key
Return bare-bronze tone with explicit geometric key visibility.
polished_lit
Illuminate mirror-polished ceremonial bronze.
polished_metal_tone
Return mirror-polished material tone at one point and normal.
project
Project one foundry-space point into the assembly plane.
shadow
Forge the directional shadow cast onto one planar receiver.
shadow_source
Forge receiver-independent directional shadow coordinates.
visible
Return whether an oriented facet faces the fixed camera.