Defines a basic material with a single color.
new BasicMaterial(
color?,opacity?):BasicMaterial
Creates a basic material.
By default, the material uses opaque black color and opacity 1.
Color = ...
Material color.
number
Material opacity.
BasicMaterial
get color():
Color
Returns the material color.
set color(
color):void
Sets the material color. Component values are copied from the provided color.
Material color.
void
get id():
bigint
Returns the unique identifier of the object.
bigint
get opacity():
number
Returns the material opacity.
number
set opacity(
opacity):void
Sets the material opacity. The value is clamped to the [0, 1] range.
number
Material opacity.
void
clone():
BasicMaterial
Creates a new material with the same properties as this material.
BasicMaterial
copy(
other):this
Copies the properties of another basic material to this material.
BasicMaterial
Source material.
this