<!--
{
  "availability" : [
    "macOS: 15.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "RealityKit",
  "identifier" : "/documentation/RealityKit/SpotLightComponent/init(color:intensity:innerAngleInDegrees:outerAngleInDegrees:attenuationRadius:attenuationFalloffExponent:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "RealityKit"
    ],
    "preciseIdentifier" : "s:17RealityFoundation18SpotLightComponentV0A3KitE5color9intensity19innerAngleInDegrees05outerjkL017attenuationRadius0N15FalloffExponentACSo7NSColorC_S5ftcfc::OverloadGroup"
  },
  "title" : "init(color:intensity:innerAngleInDegrees:outerAngleInDegrees:attenuationRadius:attenuationFalloffExponent:)"
}
-->

# init(color:intensity:innerAngleInDegrees:outerAngleInDegrees:attenuationRadius:attenuationFalloffExponent:)

Creates a spotlight with the given parameters.

```
init(color: SpotLightComponent.Color = .white, intensity: Float = 6740.94, innerAngleInDegrees: Float = 45.0, outerAngleInDegrees: Float = 60.0, attenuationRadius: Float = 10.0, attenuationFalloffExponent: Float = 2.0)
```

## Parameters

`color`

The color of the light.

`intensity`

The light’s brightness.

`innerAngleInDegrees`

The angle of the cone that emits light at full intensity, in degrees.

`outerAngleInDegrees`

The angle of the cone beyond which the spotlight’s intensity is zero.

`attenuationRadius`

The distance from the light source where its intensity reaches zero.
Any objects at or beyond this distance do not receive illumination.

`attenuationFalloffExponent`

An exponent value for the light’s intensity falloff-transition curve.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)