<!--
{
  "availability" : [
    "iOS: 17.0.0 -",
    "iPadOS: 17.0.0 -",
    "macCatalyst: 17.0.0 -",
    "macOS: 14.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "ShaderGraph-Docs",
  "identifier" : "/documentation/ShaderGraph/Data/Extract",
  "metadataVersion" : "0.1.0",
  "role" : "ShaderGraph Node",
  "symbol" : {
    "kind" : "ShaderGraph Node",
    "modules" : [
      "ShaderGraph"
    ],
    "preciseIdentifier" : "Shader_ND_extract_color3"
  },
  "title" : "Extract"
}
-->

# Extract

Generates a float stream from one channel of a color​N o​r vector​N ​stream.

## Parameter Types

**Extract (color3f):**

|Input  |Type         |
                |-------|-------------|
                |`In`   |Color3<Float>|
                |`Index`|Int32        |

|Output|Type |
                |------|-----|
                |`Out` |Float|

**Extract (vector3h):**

|Input  |Type    |
                |-------|--------|
                |`In`   |Vector3h|
                |`Index`|Int32   |

|Output|Type|
                |------|----|
                |`Out` |Half|

**Extract (vector4f):**

|Input  |Type    |
                |-------|--------|
                |`In`   |Vector4f|
                |`Index`|Int32   |

|Output|Type |
                |------|-----|
                |`Out` |Float|

**Extract (vector2h):**

|Input  |Type    |
                |-------|--------|
                |`In`   |Vector2h|
                |`Index`|Int32   |

|Output|Type|
                |------|----|
                |`Out` |Half|

**Extract (vector2f):**

|Input  |Type    |
                |-------|--------|
                |`In`   |Vector2f|
                |`Index`|Int32   |

|Output|Type |
                |------|-----|
                |`Out` |Float|

**Extract (color4f):**

|Input  |Type         |
                |-------|-------------|
                |`In`   |Color4<Float>|
                |`Index`|Int32        |

|Output|Type |
                |------|-----|
                |`Out` |Float|

**Extract (vector3f):**

|Input  |Type    |
                |-------|--------|
                |`In`   |Vector3f|
                |`Index`|Int32   |

|Output|Type |
                |------|-----|
                |`Out` |Float|

**Extract (vector4h):**

|Input  |Type    |
                |-------|--------|
                |`In`   |Vector4h|
                |`Index`|Int32   |

|Output|Type|
                |------|----|
                |`Out` |Half|

## Parameter descriptions

- `In`: The input from which to extract a value.
- `Index`: The index of the input from which to extract a value. Default value is `0`.

## Discussion

The Extract node takes its `In` input and always outputs a singular `Float`. The value of the node’s output is the value of number in the `Index` position of `In`.
For example, if `In` is equal to a `Vector3` of (10,15,20) and `Index` is `1`, the output is `15`.

---

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)