Material class
The material appearance of a Primitive.
Constructors
- Material({String? name, PBRMetallicRoughness? pbrMetallicRoughness, NormalTextureInfo? normalTexture, OcclusionTextureInfo? occlusionTexture, TextureInfo? emissiveTexture, Vector3? emissiveFactor, AlphaMode alphaMode = AlphaMode.opaque, double alphaCutoff = 0.5, bool doubleSided = false, dynamic extensions, dynamic extras, KHRMaterialSpecular? khrMaterialSpecular, KHRMaterialIor? khrMaterialIor, KHRMaterialTransmission? khrMaterialTransmission, KHRMaterialSheen? khrMaterialSheen, KHRMaterialVolume? khrMaterialVolume, KHRMaterialAnisotropy? khrMaterialAnisotropy, KHRMaterialDispersion? khrMaterialDispersion, KHRMaterialEmissiveStrength? khrMaterialEmissiveStrength, KHRMaterialIridescence? khrMaterialIridescence, KHRMaterialUnlit? khrMaterialUnlit})
Properties
- alphaCutoff ↔ double
-
Specifies the cutoff threshold when in AlphaMode.mask. If the alpha
value is greater than or equal to this value then it is rendered as fully
opaque, otherwise, it is rendered as fully transparent. A value greater
than 1.0 will render the entire material as fully transparent. This value
MUST be ignored for other alpha modes. When alphaMode is not defined, this
value MUST NOT be defined.
getter/setter pair
- alphaMode ↔ AlphaMode
-
The material’s alpha rendering mode enumeration specifying the
interpretation of the alpha value of the base color.
getter/setter pair
- doubleSided ↔ bool
-
Specifies whether the material is double sided. When this value is false,
back-face culling is enabled. When this value is true, back-face culling
is disabled and double-sided lighting is enabled. The back-face MUST have
its normals reversed before the lighting equation is evaluated.
getter/setter pair
- emissiveFactor ↔ Vector3
-
The factors for the emissive color of the material. This value defines
linear multipliers for the sampled texels of the emissive texture.
getter/setter pair
- emissiveTexture ↔ TextureInfo?
-
The emissive texture. It controls the color and intensity of the light
being emitted by the material. This texture contains RGB components
encoded with the sRGB transfer function. If a fourth component (A) is
present, it MUST be ignored. When undefined, the texture MUST be sampled
as having 1.0 in RGB components.
getter/setter pair
- extensions ↔ dynamic
-
JSON object with extension-specific objects.
getter/setter pairinherited
- extras ↔ dynamic
-
Application-specific data.
getter/setter pairinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- khrMaterialAnisotropy ↔ KHRMaterialAnisotropy?
-
KHR_materials_anisotropy
getter/setter pair
- khrMaterialDispersion ↔ KHRMaterialDispersion?
-
KHR_materials_dispersion
getter/setter pair
- khrMaterialEmissiveStrength ↔ KHRMaterialEmissiveStrength?
-
KHR_materials_emissive_strength
getter/setter pair
- khrMaterialIor ↔ KHRMaterialIor?
-
KHR_materials_ior
getter/setter pair
- khrMaterialIridescence ↔ KHRMaterialIridescence?
-
KHR_materials_iridescence
getter/setter pair
- khrMaterialSheen ↔ KHRMaterialSheen?
-
KHR_materials_sheen
getter/setter pair
- khrMaterialSpecular ↔ KHRMaterialSpecular?
-
KHR_materials_specular
getter/setter pair
- khrMaterialTransmission ↔ KHRMaterialTransmission?
-
KHR_materials_transmission
getter/setter pair
- khrMaterialUnlit ↔ KHRMaterialUnlit?
-
KHR_materials_unlit
getter/setter pair
- khrMaterialVolume ↔ KHRMaterialVolume?
-
KHR_materials_volume
getter/setter pair
- name ↔ String?
-
The user-defined name of this object. This is not necessarily unique,
e.g., an accessor and a buffer could have the same name, or two accessors
could even have the same name.
getter/setter pair
- normalTexture ↔ NormalTextureInfo?
-
The tangent space normal texture. The texture encodes RGB components with
linear transfer function. Each texel represents the XYZ components of a
normal vector in tangent space. The normal vectors use the convention
+X is right and +Y is up. +Z points toward the viewer. If a fourth
component (A) is present, it MUST be ignored. When undefined, the material
does not have a tangent space normal texture.
getter/setter pair
- occlusionTexture ↔ OcclusionTextureInfo?
-
The occlusion texture. The occlusion values are linearly sampled from the
R channel. Higher values indicate areas that receive full indirect
lighting and lower values indicate no indirect lighting. If other channels
are present (GBA), they MUST be ignored for occlusion calculations. When
undefined, the material does not have an occlusion texture.
getter/setter pair
- pbrMetallicRoughness ↔ PBRMetallicRoughness?
-
A set of parameter values that are used to define the metallic-roughness
material model from Physically Based Rendering (PBR) methodology.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited