# GetVertexAttribute(int)

> Returns information about a vertex attribute based on its index.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine](/engine/6000.7/script-reference/unityengine.md)
* **Assembly:** UnityEngine.CoreModule

```csharp
public VertexAttributeDescriptor GetVertexAttribute(int index)
```

### Parameters

**** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)): The vertex attribute index (0 to [Mesh.vertexAttributeCount](/engine/6000.7/script-reference/unityengine/mesh/vertexattributecount.md)-1).

### Returns

| Type                                                                                                            | Description                             |
| --------------------------------------------------------------------------------------------------------------- | --------------------------------------- |
| [VertexAttributeDescriptor](/engine/6000.7/script-reference/unityengine/rendering/vertexattributedescriptor.md) | Information about the vertex attribute. |

### Remarks

This function can be used together with [Mesh.vertexAttributeCount](/engine/6000.7/script-reference/unityengine/mesh/vertexattributecount.md) to query information about vertex attributes that are present in the mesh, without needing any managed allocations.

Additional Resources: [Mesh.vertexAttributeCount](/engine/6000.7/script-reference/unityengine/mesh/vertexattributecount.md), [Mesh.GetVertexAttributes](/engine/6000.7/script-reference/unityengine/mesh/getvertexattributes.md), [VertexAttributeDescriptor](/engine/6000.7/script-reference/unityengine/rendering/vertexattributedescriptor.md).
