---
name: procedural-textures
description: "Create deterministic, reusable surface textures with documented scale and color spaces. Use for textures, текстуры, bump, CanvasTexture."
---

# Процедурные текстуры

Create deterministic, reusable surface textures with documented scale and color spaces.

## Implementation decisions

1. Use deterministic generators for repeatable assets and expose resolution as an export choice.
2. Color textures use sRGB; normal, roughness and bump scalar data use a linear/no-color space.
3. Set repeat wrapping and test seams; do not call random noise a scanned PBR material.
4. Distinguish a single procedural modulation map from a calibrated multi-map PBR set. Keep texture scale tied to object dimensions.

## Working source

Read [lib/objects.ts](../webcraft-shared/source/lib/objects.ts) when implementing this capability. The example belongs to the WEBCRAFT React/Three.js playground except the Python commerce starter, which runs without third-party dependencies. Use [shared catalog](../webcraft-shared/source/lib/catalog.ts) only to resolve related examples. Adapt the source to the target framework and preserve existing project conventions.

The original workshop uses Three.js 0.180 and procedural builders. The external asset viewer separately loads licensed glTF, scanned PBR maps and HDRIs. Preserve the provenance of each corpus. See [objects.ts](../webcraft-shared/source/lib/objects.ts) for material and geometry ownership and [scene.tsx](../webcraft-shared/source/components/scene.tsx) for renderer lifecycle.

## Verify observable behavior

- PNG export matches the selected texture.
- Repeat boundaries are checked at high contrast.
- Map and bump textures are disposed on replacement.

## Scope

Use only the parts relevant to the requested task. This skill does not grant permission to publish, spend money, change account access or expose secrets. The original brief and environment rules remain authoritative.

Live example: https://webcraft-skill-library.undrgrnd.chatgpt.site/demos/3d

Version 2.0.0 · Original WEBCRAFT content · MIT
