---
title: "solarize"
description: "Invert only the bright parts of the child, the darkroom solarization look."
group: "effects"
groupTitle: "Filters & effects"
categoryId: "effects.color"
categorySlug: "effects-color"
categoryTitle: "Color effects"
kind: "function"
sourceUrl: "https://github.com/shader-effects-inc/shaders/blob/main/packages/core/src/std/effects/color.ts#L155"
---

# solarize

Invert only the bright parts of the child, the darkroom solarization look.

```ts
solarize(slots: {threshold: ArgSpec; strength: ArgSpec}): PointwiseEffect
```

Import `effects` from `shaders/std` and use `effects.color.solarize`.

`threshold` (0–1) is the brightness above which a pixel flips. `strength` (0–1) fades the flipped result over the original: 0 is untouched, 1 is fully solarized.

## Parameters

| Name | Type | Notes |
|---|---|---|
| `slots` | `{threshold: ArgSpec; strength: ArgSpec}` |  |

## Example

```ts
effect: solarize({threshold: p('threshold'), strength: p('strength')})
```

> **Tip.** Declare `identityWhen: isZero('strength')`.

## See also

- [`invert`](/docs/primitives/effects-color/invert) — Flip every color of the child to its negative.
- [`posterize`](/docs/primitives/effects-color/posterize) — Reduce the child to a few flat color levels, like a screen-printed poster.

## Used by

[Solarize](/docs/components/solarize)