---
title: "stripeBands"
description: "A mask of straight parallel stripes that scroll with the layer's clock."
group: "paint"
groupTitle: "Painting"
categoryId: "patterns"
categorySlug: "patterns"
categoryTitle: "Patterns & tiling"
kind: "function"
sourceUrl: "https://github.com/shader-effects-inc/shaders/blob/main/packages/core/src/std/paint/patterns.ts#L390"
---

# stripeBands

A mask of straight parallel stripes that scroll with the layer's clock.

```ts
stripeBands(slots: {
    angle: PropRef
    density: PropRef
    balance: PropRef
    softness: PropRef
    offset: PropRef
}): PatternPaint
```

Import `patterns` from `shaders/std` and use `patterns.stripeBands`.

`angle` is in degrees. `density` is the number of stripe pairs across the canvas height. `balance` 0–1 is how much of each pair is the 0 side (the fill in `strokeOver`). `softness` 0–1 blurs the edges. `offset` shifts the phase; 1 is one whole pair. Declare `animatedTime: {speed: 'speed'}` on the definition; speed 0 holds the stripes still.

## Parameters

| Name | Type | Notes |
|---|---|---|
| `slots` | `{
    angle: PropRef
    density: PropRef
    balance: PropRef
    softness: PropRef
    offset: PropRef
}` |  |

## Example

```ts
paint: strokeOver({fill: p('colorA'), stroke: p('colorB'), mask: stripeBands({angle: p('angle'), density: p('density'), balance: p('balance'), softness: p('softness'), offset: p('offset')}), space: p('colorSpace')})
```

## See also

- [`zigzagBands`](/docs/primitives/patterns/zigzagbands) — A mask of chevron (zigzag) stripes that scroll with the layer's clock.
- [`checkerCells`](/docs/primitives/patterns/checkercells) — A checkerboard mask: 1 on one set of squares, 0 on the other, with clean edges at any size.
- [`ringWaves`](/docs/primitives/patterns/ringwaves) — A mask of concentric rings spreading out from a point, animated by the layer's clock.

## Used by

[Stripes](/docs/components/stripes)