---
title: "wardAlphas"
description: "Turns roughness and anisotropy sliders (0–1 each) into the two lobe widths `anisoSpecular` takes."
group: "light"
groupTitle: "Noise, light & materials"
categoryId: "materials"
categorySlug: "materials"
categoryTitle: "Materials & surfaces"
kind: "function"
sourceUrl: "https://github.com/shader-effects-inc/shaders/blob/main/packages/core/src/std/paint/materials.ts#L604"
---

# wardAlphas

Turns roughness and anisotropy sliders (0–1 each) into the two lobe widths `anisoSpecular` takes.

```ts
wardAlphas(
  roughness: Expr | number,
  anisotropy: Expr | number,
): {along: Expr; across: Expr}
```

Import `materials` from `shaders/std` and use `materials.wardAlphas`.

Higher roughness widens the highlight. Higher anisotropy stretches it along the grain and squeezes it across.

## Parameters

| Name | Type | Notes |
|---|---|---|
| `roughness` | `Expr \| number` |  |
| `anisotropy` | `Expr \| number` |  |

## Example

```ts
alphas: wardAlphas(u.roughness, u.anisotropy)
```

## See also

- [`anisoSpecular`](/docs/primitives/materials/anisospecular) — A highlight stretched along a grain, as on brushed metal or carbon fibre.

## Used by

[BrushedMetal](/docs/components/brushedmetal), [Satin](/docs/components/satin)