<!--
{
  "availability" : [
    "iOS: 18.0.0 -",
    "iPadOS: 18.0.0 -",
    "macCatalyst: 18.0.0 -",
    "macOS: 15.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "RealityKit",
  "identifier" : "/documentation/RealityKit/LowLevelMesh/Descriptor-swift.struct/init(vertexCapacity:vertexAttributes:vertexLayouts:indexCapacity:indexType:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "RealityKit"
    ],
    "preciseIdentifier" : "s:17RealityFoundation12LowLevelMeshC10DescriptorV14vertexCapacity0G10Attributes0G7Layouts05indexH00K4TypeAESi_SayAC9AttributeVGSayAC6LayoutVGSiSo08MTLIndexL0Vtcfc"
  },
  "title" : "init(vertexCapacity:vertexAttributes:vertexLayouts:indexCapacity:indexType:)"
}
-->

# init(vertexCapacity:vertexAttributes:vertexLayouts:indexCapacity:indexType:)

Creates a descriptor for a low-level mesh.

```
init(vertexCapacity: Int = 0, vertexAttributes: [LowLevelMesh.Attribute] = [Attribute](), vertexLayouts: [LowLevelMesh.Layout] = [Layout](), indexCapacity: Int = 0, indexType: MTLIndexType = MTLIndexType.uint32)
```

## Parameters

`vertexCapacity`

The maximum number of vertices the system can store in the mesh.

`vertexAttributes`

The attributes of the vertices.

`vertexLayouts`

The layouts for the vertex buffers.

`indexCapacity`

The maximum number of vertices the system can store in a single buffer.

`indexType`

The index type to use for the mesh.

## Discussion

To create a new [`LowLevelMesh`](/documentation/RealityKit/LowLevelMesh), first create a `Descriptor`
object and set its property values,
then use that `Descriptor` with [`init(descriptor:)`](/documentation/RealityKit/LowLevelMesh/init(descriptor:)).

---

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)