Builder

class Builder

Builder for creating Material objects from compiled material packages.

The Builder takes a material package (binary blob from the matc compiler) and configures rendering quality and batching options before building the final Material.

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard

Shadow sampling quality affects how soft shadows are rendered.

Functions

Link copied to clipboard
fun build(engine: Engine): Material?

Creates the Material and returns it.

Link copied to clipboard

fun constant(name: String, value: Int): Material.Builder

Specializes a constant parameter specified in the material definition with a concrete value for this material. Once build() is called, this constant cannot be changed. Will panic if the name doesn't correspond to a constant specified in the material definition, or if the type differs.

Link copied to clipboard

Specifies the material data (compiled binary blob); C++'s package, a Kotlin keyword.

Link copied to clipboard

Set the quality of shadow sampling.

Link copied to clipboard

Sets the quality of the indirect light computations.

Link copied to clipboard

Set the batching mode of the instances created from this material.