<!--
{
  "availability" : [
    "iOS: 10.0.0 -",
    "iPadOS: 10.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.12.0 -",
    "tvOS: 10.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "GameplayKit",
  "identifier" : "/documentation/GameplayKit/GKNoise/init(componentNoises:selectionNoise:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "GameplayKit"
    ],
    "preciseIdentifier" : "c:objc(cs)GKNoise(cm)noiseWithComponentNoises:selectionNoise:"
  },
  "title" : "init(componentNoises:selectionNoise:)"
}
-->

# init(componentNoises:selectionNoise:)

Creates a noise object by combining the specified noise objects, using another noise object to select which regions of the output correspond to which input noise.

```
convenience init(componentNoises noises: [GKNoise], selectionNoise: GKNoise)
```

## Parameters

`noises`

The array of noise objects to combine.

`selectionNoise`

A noise object whose values determine which object from the `noises` array contributes to which region of the generated output.

## Return Value

A new noise object.

## Discussion

This method is equivalent to the [`init(componentNoises:selectionNoise:componentBoundaries:boundaryBlendDistances:)`](/documentation/GameplayKit/GKNoise/init(componentNoises:selectionNoise:componentBoundaries:boundaryBlendDistances:)) method, but automatically determines uniformly spaced boundaries based on the number of noise objects in the `noises` array, and using a blend distance of zero for each boundary. Together with these boundaries, the `selectionNoise` parameter determines which of the input noise objects appears in which region of generated noise.

For example, if the `noises` array contains two noise objects, the boundary value is zero: In regions where the `selectionNoise` field has negative values, the noise created by this method uses values from the first element of the `noises` array, and in regions where the `selectionNoise` field has positive values, the created noise uses values from the second element in the `noises` array.

![](images/com.apple.gameplaykit/media-2556365@2x.png)

---

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)