Skip to content
Shapemetry

@huukhanhnguyen/model / conventions

conventions

LightingStandard

LightingStandard = { ambient: number; hemisphere: number; hemisphereGround: number; key: number; surfaceColor: number; }

ambient

ambient: number

Ambient floor — shadow lift, never a second wash of fill.

hemisphere

hemisphere: number

Hemisphere fill (sky→ground), the directionless base.

hemisphereGround

hemisphereGround: number

Hemisphere ground colour (0xRRGGBB) — a cool grey so down-faces aren't black.

key

key: number

CameraData-parented key (directional). The dominant SHADING term; kept modest because a top-down view aims it at up-facing faces (N·L → 1).

surfaceColor

surfaceColor: number

The no-material surface colour (0xRRGGBB). A neutral CAD grey, never pure white — white × any real irradiance clips before edges describe the form.


MaterialStandard

MaterialStandard = { metalness: number; opacity: number; roughness: number; }

metalness

metalness: number

0 = dielectric (wood/plastic/paint), 1 = metal. Default dielectric: a metal with no IBL/environment reads as a dark mirror, the classic "why is my material black" surprise.

opacity

opacity: number

Fully opaque unless the material asks otherwise.

roughness

roughness: number

0 = mirror-smooth, 1 = fully diffuse. Default high: an unset material is a matte surface, not a gloss that blows a highlight.


STANDARD_CONVENTIONS

const STANDARD_CONVENTIONS: Convention[]

The T1 conventions that ship with the product — one per VISUAL lane whose DEFAULT can look wrong (a default that renders is where a silent regression hides). The data/structural lanes (tables/views/…) are governed by their schema validate + the functional lane-audit, not by a render convention, so they are deliberately absent here.


CAD_LIGHTING_STANDARD

Re-exports CAD_LIGHTING_STANDARD


ConventionRegistry

Re-exports ConventionRegistry


drawingConvention

Re-exports drawingConvention


LIGHTING_CHECK_ANGLES

Re-exports LIGHTING_CHECK_ANGLES


lightingConvention

Re-exports lightingConvention


materialConvention

Re-exports materialConvention


mergeConventions

Re-exports mergeConventions


PBR_MATERIAL_STANDARD

Re-exports PBR_MATERIAL_STANDARD


textureConvention

Re-exports textureConvention

Last updated: 📖 2 min readEdit on GitHub