---
title: CustomMaterial.ClearcoatRoughness
framework: realitykit
role: symbol
role_heading: Structure
path: realitykit/custommaterial/clearcoatroughness-swift.struct
---

# CustomMaterial.ClearcoatRoughness

An object that defines the degree to which an entity’s clear, shiny coating scatters light to create soft highlights.

## Declaration

```swift
struct ClearcoatRoughness
```

## Overview

Overview An entity in RealityKit can display a clearcoat, which is a separate layer of transparent specular highlights used to simulate a clear coating, like on a car or the surface of lacquered objects. Use this object to specify a clearcoat roughness value and indicate how much the clearcoat scatters light that bounces off of it, which softens and disperses the highlights. For information, see clearcoatRoughness.

## Topics

### Creating a clearcoat roughness object

- [init(floatLiteral:)](realitykit/custommaterial/clearcoatroughness-swift.struct/init(floatliteral:).md)
- [init(scale:texture:)](realitykit/custommaterial/clearcoatroughness-swift.struct/init(scale:texture:).md)
- [init(_:)](realitykit/custommaterial/clearcoatroughness-swift.struct/init(_:).md)

### Accessing clearcoat roughness values

- [scale](realitykit/custommaterial/clearcoatroughness-swift.struct/scale.md)
- [texture](realitykit/custommaterial/clearcoatroughness-swift.struct/texture.md)

## Relationships

### Conforms To

- [ExpressibleByFloatLiteral](swift/expressiblebyfloatliteral.md)
