# VertexAttribute

Artifact: [androidx.xr.scenecore:scenecore](https://developer.android.com/jetpack/androidx/releases/xr-scenecore) [View Source](https://cs.android.com/search?q=file:androidx/xr/scenecore/VertexLayout.kt+class:androidx.xr.scenecore.VertexAttribute) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/xr-scenecore#1.0.0)

*** ** * ** ***


```
public final class VertexAttribute
```

<br />

*** ** * ** ***

Defines the attribute of a vertex.

This class is used to define the semantic meaning of a vertex attribute in a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeDescriptor`. See `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType` for the supported data types.

## Summary

| ### Public fields |
|---|---|
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#BONE_INDICES()` The indices of the bones that affect this vertex. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#BONE_WEIGHTS()` The weights of the bones that affect this vertex. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#COLOR()` The color of the vertex. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#NORMAL()` The normal of the vertex. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#POSITION()` The position of the vertex. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#UV0()` The first set of texture coordinates. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#UV1()` The second set of texture coordinates. |

| ### Public methods |
|---|---|
| `boolean` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#equals(kotlin.Any)(https://developer.android.com/reference/java/lang/Object.html other)` |
| `int` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#hashCode()()` |
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#toString()()` |

## Public fields

### BONE_INDICES

```
public static final @NonNull VertexAttribute BONE_INDICES
```

The indices of the bones that affect this vertex. Must be a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType#UBYTE4()`. If this attribute is present in a `https://developer.android.com/reference/androidx/xr/scenecore/VertexLayout`, `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#BONE_WEIGHTS()` must also be present.

### BONE_WEIGHTS

```
public static final @NonNull VertexAttribute BONE_WEIGHTS
```

The weights of the bones that affect this vertex. Must be a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType#UBYTE4_NORM()`. If this attribute is present in a `https://developer.android.com/reference/androidx/xr/scenecore/VertexLayout`, `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttribute#BONE_INDICES()` must also be present.

### COLOR

```
public static final @NonNull VertexAttribute COLOR
```

The color of the vertex. Must be a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType#UBYTE4_NORM()`.

### NORMAL

```
public static final @NonNull VertexAttribute NORMAL
```

The normal of the vertex. Must be a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType#FLOAT3()` normal, or a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType#FLOAT4()` quaternion representing the entire tangent frame (normal, tangent, and bitangent vectors).

### POSITION

```
public static final @NonNull VertexAttribute POSITION
```

The position of the vertex. Must be a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType#FLOAT3()`.

### UV0

```
public static final @NonNull VertexAttribute UV0
```

The first set of texture coordinates. Must be a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType#FLOAT2()`.

### UV1

```
public static final @NonNull VertexAttribute UV1
```

The second set of texture coordinates. Must be a `https://developer.android.com/reference/androidx/xr/scenecore/VertexAttributeType#FLOAT2()`.

## Public methods

### equals

```
public boolean equals(Object other)
```

### hashCode

```
public int hashCode()
```

### toString

```
public @NonNull String toString()
```