<!--
{
  "availability" : [
    "iOS: 8.0.0 - 26.0.0",
    "iPadOS: 8.0.0 - 26.0.0",
    "macCatalyst: 13.1.0 - 26.0.0",
    "macOS: 10.8.0 - 26.0.0",
    "tvOS: 9.0.0 - 26.0.0",
    "visionOS: 1.0.0 - 26.0.0",
    "watchOS: 3.0.0 - 26.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "SceneKit",
  "identifier" : "/documentation/SceneKit/SCNGeometry/sources(for:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "SceneKit"
    ],
    "preciseIdentifier" : "c:objc(cs)SCNGeometry(im)geometrySourcesForSemantic:"
  },
  "title" : "sources(for:)"
}
-->

# sources(for:)

Returns the geometry sources for a specified semantic.

```
func sources(for semantic: SCNGeometrySource.Semantic) -> [SCNGeometrySource]
```

## Parameters

`semantic`

A constant identifying a semantic for which to return geometry sources. See Geometry Semantic Identifiers for possible values.

## Return Value

An array of [`SCNGeometrySource`](/documentation/SceneKit/SCNGeometrySource) objects, or `nil` if the geometry has no source for the specified semantic.

## Discussion

Each [`SCNGeometrySource`](/documentation/SceneKit/SCNGeometrySource) object describes an attribute of all vertices in the geometry (such as vertex position, surface normal vector, color, or texture mapping coordinates) identified by the source’s [`semantic`](/documentation/SceneKit/SCNGeometrySource/semantic-swift.property) property. A geometry always has at least one source, for the [`vertex`](/documentation/SceneKit/SCNGeometrySource/Semantic-swift.struct/vertex) semantic, typically has additional sources for use in lighting and shading, and may have other sources for skeletal animation or surface subdivision information.

The vertex, normal, and color semantics each refer to at most one source. A geometry may have multiple sources for the [`texcoord`](/documentation/SceneKit/SCNGeometrySource/Semantic-swift.struct/texcoord) semantic—in this case, indices in the returned array correspond to values for the [`mappingChannel`](/documentation/SceneKit/SCNMaterialProperty/mappingChannel) property used when attaching textures to materials.

## See Also

[`+  geometryWithSources:elements:`](/documentation/SceneKit/SCNGeometry/init(sources:elements:))

Creates a new geometry built from the specified geometry sources and elements.



---

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)