---
title: "shadowOffset"
description: "The coordinate a shadow reads the child's silhouette from: `distance` away in the compass direction `angle`."
group: "effects"
groupTitle: "Filters & effects"
categoryId: "effects.blurs"
categorySlug: "effects-blurs"
categoryTitle: "Blurs, glows & screens"
kind: "function"
sourceUrl: "https://github.com/shader-effects-inc/shaders/blob/main/packages/core/src/std/effects/blurs.ts#L1125"
---

# shadowOffset

The coordinate a shadow reads the child's silhouette from: `distance` away in the compass direction `angle`.

```ts
shadowOffset(opts: {angle: ArgSpec; distance: ArgSpec}): (params: RttFilterParams) => Expr
```

Import `effects` from `shaders/std` and use `effects.blurs.shadowOffset`.

`angle` is in degrees, 0 up, 90 right, 180 down. `distance` (0–1) is a fraction of the canvas height and covers the same number of pixels in either axis. Pass the result as the `at` of `silhouetteCoverage`.

## Parameters

| Name | Type | Notes |
|---|---|---|
| `opts` | `{angle: ArgSpec; distance: ArgSpec}` |  |

## Example

```ts
silhouetteCoverage({at: shadowOffset({angle: p('angle'), distance: p('distance')}), blur: p('blur')})
```

## See also

- [`silhouetteCoverage`](/docs/primitives/effects-blurs/silhouettecoverage) — A soft copy of the child's alpha silhouette: a number per pixel from 0 to 1.
- [`shadowComposite`](/docs/primitives/effects-blurs/shadowcomposite) — A tinted shadow behind the child.

## Used by

[DropShadow](/docs/components/dropshadow)