Properties of Materials in Three.js
Explore the fundamental properties of materials in Three.js to customize the appearance and effects of 3D objects. Understand settings like opacity, transparency, shading, and blending to enhance realism and visual control in your 3D scenes.
We'll cover the following...
Basic properties
The basic properties of the THREE.Material object are listed here (we will see these properties in action in the THREE.MeshBasicMaterial):
-
id: This is used to identify a material and is assigned when we create a material. This starts at0for the first material and is increased by1for each additional material that is created. -
uuid: This is a uniquely generated ID and is used internally. -
name: We can assign a name to a material with this property. This can be used for debugging purposes.
opacity: This defines how transparent an object is. Use this together with thetransparentproperty. The range of this property is from0to1. ...