TilesetStyle

@Serializable
class TilesetStyle(val show: String? = null, val color: String? = null, val meta: Map<String, String> = emptyMap(), val defines: Map<String, String> = emptyMap())

A parsed 3D Tiles 1.0 declarative style document. Carries the raw expressions for show, color, and meta — actual evaluation is delegated to a pluggable TilesetStyleEvaluator so the engine doesn't carry a mini-DSL parser in core.

Spec reference: https://github.com/CesiumGS/3d-tiles/tree/main/specification/Styling.

Typical pipeline:

When no evaluator is registered (the default), every style is a no-op: features render with their material's baseColorFactor and are all visible. The integration surface is structurally complete (parse + plumb), so wiring a real evaluator later is a drop-in.

Constructors

Link copied to clipboard
constructor(show: String? = null, color: String? = null, meta: Map<String, String> = emptyMap(), defines: Map<String, String> = emptyMap())

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

Color expression evaluated against each feature; result overrides the material base colour. Null means "no color expression" (material colour used as-is).

Link copied to clipboard

Optional defines block from the spec — symbolic shorthand expressions the show / color expressions may reference via ${name}. Engine carries these for the evaluator; doesn't expand them itself.

Link copied to clipboard

Arbitrary metadata key→expression pairs the app can evaluate to attach derived values to features (per spec). Engine ignores these; apps use them for picking callbacks, tooltips, analytics.

Link copied to clipboard
val show: String?

Boolean expression evaluated against each feature; false hides the feature. Null means "no show expression" (everything visible).