SurfaceMaterial constructor
SurfaceMaterial({
- String? name,
- Vector4? baseColor,
- double metallic = 0.0,
- double roughness = 0.5,
- TextureBinding? baseColorTexture,
- TextureBinding? metallicRoughnessTexture,
- TextureBinding? normalTexture,
- double normalScale = 1.0,
- TextureBinding? occlusionTexture,
- double occlusionStrength = 1.0,
- TextureBinding? emissiveTexture,
- Vector3? emissive,
- double emissiveStrength = 1.0,
- SurfaceAlphaMode alphaMode = SurfaceAlphaMode.opaque,
- double alphaCutoff = 0.5,
- bool doubleSided = false,
- bool unlit = false,
- LightingModel? lightingModel,
- Map<
String, Object?> ? extras,
Implementation
SurfaceMaterial({
this.name,
Vector4? baseColor,
this.metallic = 0.0,
this.roughness = 0.5,
this.baseColorTexture,
this.metallicRoughnessTexture,
this.normalTexture,
this.normalScale = 1.0,
this.occlusionTexture,
this.occlusionStrength = 1.0,
this.emissiveTexture,
Vector3? emissive,
this.emissiveStrength = 1.0,
this.alphaMode = SurfaceAlphaMode.opaque,
this.alphaCutoff = 0.5,
this.doubleSided = false,
this.unlit = false,
this.lightingModel,
this.extras,
}) : baseColor = baseColor ?? Vector4(1.0, 1.0, 1.0, 1.0),
emissive = emissive ?? Vector3.zero();