# BrushPaint.StampingTexture.Builder

Artifact: [androidx.ink:ink-brush](https://developer.android.com/jetpack/androidx/releases/ink) [View Source](https://cs.android.com/search?q=file:androidx/ink/brush/BrushPaint.kt+class:androidx.ink.brush.BrushPaint.StampingTexture.Builder) Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

*** ** * ** ***

Common/AllAndroid/JVMNative/C/iOS
- Cmn

  ```
  class BrushPaint.StampingTexture.Builder
  ```

*** ** * ** ***

Builder for `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture`.

For Java developers, use `StampingTexture.Builder` to construct a `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture` with default values, overriding only as needed. For example: `StampingTexture layer = StampingTexture.builder().setClientTextureId(id).build();`

## Summary

| ### Public functions |
|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture` | `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder#build()()` Constructs a `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.TextureLayer` from this `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder` | `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder#setAnimationColumns(kotlin.Int)(animationColumns: @https://developer.android.com/reference/kotlin/androidx/annotation/IntRange(from = 1, to = 4096) https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the number of animation columns in this texture layer. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder` | `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder#setAnimationDurationMillis(kotlin.Long)( animationDurationMillis: @https://developer.android.com/reference/kotlin/androidx/annotation/IntRange(from = 0, to = 16777216) https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html )` Sets the duration of the animation for this texture layer. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder` | `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder#setAnimationFrames(kotlin.Int)(animationFrames: @https://developer.android.com/reference/kotlin/androidx/annotation/IntRange(from = 1, to = 16777216) https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the number of animation frames in this texture layer. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder` | `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder#setAnimationRepeatMode(androidx.ink.brush.BrushPaint.AnimationRepeatMode)( animationRepeatMode: https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.AnimationRepeatMode )` Sets what should happen when this texture layer's animation repeats. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder` | `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder#setAnimationRows(kotlin.Int)(animationRows: @https://developer.android.com/reference/kotlin/androidx/annotation/IntRange(from = 1, to = 4096) https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Sets the number of animation rows in this texture layer. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder` | `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder#setBlendMode(androidx.ink.brush.BrushPaint.TextureLayer.BlendMode)(blendMode: https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.TextureLayer.BlendMode)` Sets the blend mode used for blending this and all previous texture layers with the next one. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder` | `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder#setClientTextureId(kotlin.String)(clientTextureId: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)` Sets the client texture ID for this texture layer. | Cmn |

## Public functions

### build

Cmn Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

```
fun build(): BrushPaint.StampingTexture
```

Constructs a `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.TextureLayer` from this `https://developer.android.com/reference/kotlin/androidx/ink/brush/BrushPaint.StampingTexture.Builder`.

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-illegal-state-exception/index.html` | if `clientTextureId`, `sizeX`, and/or `sizeY` were never set |

### setAnimationColumns

Cmn Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

```
fun setAnimationColumns(animationColumns: @IntRange(from = 1, to = 4096) Int): BrushPaint.StampingTexture.Builder
```

Sets the number of animation columns in this texture layer.

### setAnimationDurationMillis

Cmn Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

```
fun setAnimationDurationMillis(
    animationDurationMillis: @IntRange(from = 0, to = 16777216) Long
): BrushPaint.StampingTexture.Builder
```

Sets the duration of the animation for this texture layer.

### setAnimationFrames

Cmn Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

```
fun setAnimationFrames(animationFrames: @IntRange(from = 1, to = 16777216) Int): BrushPaint.StampingTexture.Builder
```

Sets the number of animation frames in this texture layer.

### setAnimationRepeatMode

Cmn Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

```
fun setAnimationRepeatMode(
    animationRepeatMode: BrushPaint.AnimationRepeatMode
): BrushPaint.StampingTexture.Builder
```

Sets what should happen when this texture layer's animation repeats.

### setAnimationRows

Cmn Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

```
fun setAnimationRows(animationRows: @IntRange(from = 1, to = 4096) Int): BrushPaint.StampingTexture.Builder
```

Sets the number of animation rows in this texture layer.

### setBlendMode

Cmn Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

```
fun setBlendMode(blendMode: BrushPaint.TextureLayer.BlendMode): BrushPaint.StampingTexture.Builder
```

Sets the blend mode used for blending this and all previous texture layers with the next one.

### setClientTextureId

Cmn Added in [1.1.0-alpha11](https://developer.android.com/jetpack/androidx/releases/ink#1.1.0-alpha11)

```
fun setClientTextureId(clientTextureId: String): BrushPaint.StampingTexture.Builder
```

Sets the client texture ID for this texture layer.