---
title: "dotScreenMask"
description: "The dot coverage of one halftone screen: 1 inside a dot, 0 between, with the dot size set by an ink amount."
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#L835"
---

# dotScreenMask

The dot coverage of one halftone screen: 1 inside a dot, 0 between, with the dot size set by an ink amount.

```ts
dotScreenMask(
  uv: Expr,
  aspect: Expr,
  angle: Expr,
  intensity: Expr,
  frequency: Expr,
): Expr
```

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

A raw building block for a custom press inside a gather `build`. `uv` is the pixel's uv and `aspect` the canvas aspect (`ctx.uv`, `ctx.aspect`). `angle` is the screen angle in degrees. `intensity` 0–1 is the ink amount at this pixel; 0 leaves no dot. `frequency` is the number of dots down the canvas height.

## Parameters

| Name | Type | Notes |
|---|---|---|
| `uv` | `Expr` |  |
| `aspect` | `Expr` |  |
| `angle` | `Expr` |  |
| `intensity` | `Expr` |  |
| `frequency` | `Expr` |  |

## Example

```ts
const dots = dotScreenMask(ctx.uv, ctx.aspect, uniforms.angle, intensity, uniforms.frequency)
```

## See also

- [`inkTransmission`](/docs/primitives/patterns/inktransmission) — How much light passes one ink plate: white where the dot mask is 0, the ink color where it is 1.
- [`cmykPress`](/docs/primitives/patterns/cmykpress) — A four-color print filter: the layer inside it separated into ink plates, each screened into dots at its own angle and laid down on paper in order.
- [`dotScreen`](/docs/primitives/patterns/dotscreen) — A classic halftone filter: the layer inside it redrawn as a grid of dots that grow where it is bright.