---
title: "cellLaneUVFor"
description: "Where one shard's value sits in a one-row data texture."
group: "effects"
groupTitle: "Filters & effects"
categoryId: "effects.fracture"
categorySlug: "effects-fracture"
categoryTitle: "Fracture"
kind: "function"
sourceUrl: "https://github.com/shader-effects-inc/shaders/blob/main/packages/core/src/std/effects/fracture.ts#L103"
---

# cellLaneUVFor

Where one shard's value sits in a one-row data texture.

```ts
cellLaneUVFor(laneWidth: number): TgpuFn<(idx: F32, field: F32) => Vec2f>
```

Import `effects` from `shaders/std` and use `effects.fracture.cellLaneUVFor`.

Lay the texture out as four values per shard, so `laneWidth` is the shard count times four. The returned GPU function takes a shard index and a value index (0 to 3) and gives the uv to sample with `'nearestClamp'`. Built once per width.

## Parameters

| Name | Type | Notes |
|---|---|---|
| `laneWidth` | `number` |  |

## Example

```ts
const cellLaneUV = cellLaneUVFor(16 * 4)
const dataAt = (idx: Expr, field: number) => dataKit.sample(call(cellLaneUV, 'cellLaneUV', [idx, floatE(field)]), 'nearestClamp').member('r')
```

## See also

- [`voronoiRegionField`](/docs/primitives/effects-fracture/voronoiregionfield) — Splits the canvas into shards around random sites and records, per pixel, its shard and the next-nearest one.
- [`crackGeom`](/docs/primitives/effects-fracture/crackgeom) — How much crack there is at a pixel, and which way the shard under it has moved.

## Used by

[Shatter](/docs/components/shatter)