An object that defines the degree to which an entity’s clear, shiny
coating scatters light to create soft highlights.
This object specifies clearcoat roughness for entities that have
clearcoat enabled. A clearcoat is a separate layer of transparent
specular highlights used to simulate a clear coating, like on a car or
the surface of lacquered objects. When you enable clearcoat rendering
for a material, RealityKit renders the clearcoat as a separate layer
just above the surface of the entity. You can specify a clearcoat
roughness value to indicate how much the clearcoat scatters light that
bounces off of it, which softens and spreads out the highlights.
Creates a clearcoat roughness object using a single value.
A clearcoat is a separate layer of transparent specular highlights
used to simulate a clear transparent coating, like the paint on a
car, or the surface of lacquered objects. When you enable clearcoat
rendering for a material, RealityKit renders the clearcoat as a
separate layer just above the surface of the entity. You can specify
a clearcoat roughness value for the clearcoat to indicate how much
the clearcoat scatters light that bounces off of it, which softens
and spreads out the highlights.
This initializer creates an object that specifies the clearcoat
roughness for a material using a single value for the entire
material.
- Parameters:
- value: The clearcoat roughness value to use for the entire material.
get · iOS 15.0+
textureSemantic
TypeScript
static get textureSemantic(): TextureResource_Semantic
Swift declaration
static let textureSemantic: TextureResource.Semantic
The intended use of the object’s texture property.
Creates a clearcoat roughness object using a single value or a
texture.
A clearcoat is a separate layer of transparent specular highlights
used to simulate a clear transparent coating, like the paint on a
car, or the surface of lacquered objects. When you enable clearcoat
rendering for a material, RealityKit renders the clearcoat as a
separate layer just above the surface of the entity. You can specify
a clearcoat roughness value for the clearcoat to indicate how much
the clearcoat scatters light that bounces off of it, which softens
and spreads out the highlights.
This initializer creates an object that specifies the clearcoat
roughness for a material using a single value for the entire
material, a UV-mapped image, or both.
If you specify `texture`, RealityKit calculates the clearcoat
roughness for the entity by UV-mapping `texture` onto the entity and
multiplying the value of each mapped pixel by `scale`. If you don’t
specify a `texture`, then RealityKit uses `scale` as the entire
entity’s clearcoat roughness. If you provide a color image for
`texture` rather than a grayscale image, RealityKit only uses the
intensity of the image’s red channel.
- Parameters:
- scale: The clearcoat roughness value for the entire material.
- texture: The clearcoat roughness values as a UV-mapped image.
get · iOS 15.0+
scale
TypeScript
get scale(): number
Swift declaration
var scale: Float
The clearcoat roughness specified as a single value.
set · iOS 15.0+
scale
TypeScript
set scale(value: number)
Swift declaration
var scale: Float
The clearcoat roughness specified as a single value.
get · iOS 15.0+
texture
TypeScript
get texture(): (MaterialParameters_Texture) | null
Swift declaration
var texture: PhysicallyBasedMaterial.Texture?
The clearcoat roughness specified using a UV-mapped image.
set · iOS 15.0+
texture
TypeScript
set texture(value: (MaterialParameters_Texture) | null)
Swift declaration
var texture: PhysicallyBasedMaterial.Texture?
The clearcoat roughness specified using a UV-mapped image.
Creates a clearcoat roughness object from a custom material’s
clearcoat roughness property.
A clearcoat is a separate layer of transparent specular highlights
used to simulate a clear transparent coating, like the paint on a
car, or the surface of lacquered objects. When you enable clearcoat
rendering for a material, RealityKit renders the clearcoat as a
separate layer just above the surface of the entity. You can specify
a clearcoat roughness value for the clearcoat to indicate how much
the clearcoat scatters light that bounces off of it, which softens
and spreads out the highlights.
This initializer creates an object that specifies the clearcoat
roughness for a material that uses the
``CustomMaterial/clearcoatRoughness-swift.property`` property from a
``CustomMaterial`` object.
- Parameters:
- value: The custom material’s clearcoat roughness property.