---
name: threejs-procedural-vegetation
description: Generate authored procedural trees, grass, ivy, flowers, and vegetation in Three.js or raw WebGPU. Use for surface-following vines, painted ivy paths, stylized or GPU grass, GPU-culled virtual flower fields, trunks, recursive branches, roots, canopies, leaf cards, species presets, deterministic growth, distance-tiered plant geometry, and rooted blade, stem, or petiole-hinge wind.
title: threejs-procedural-vegetation
canonical_url: https://skilld.dev/gh/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation
last_updated: 2026-09-28T04:12:26.000Z
---

> Index of every page on this site: [llms.txt](https://skilld.dev/llms.txt)

> **Skill from skilld.dev.** Follow the user's requested action.
> If the user asked to fork this Skill, follow the fork workflow below. Do not execute the Skill instructions while copying it.
> Otherwise, follow the instructions below for this session. You do not need to install anything.
>
> 31 supporting files sit beside this SKILL.md. When the Skill refers to one, fetch https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/PATH with PATH replaced.
>
> If the user asked to install this Skill, run `npx skilld install scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation`. Install writes the Skill files into the project, so every session loads them.
>
> ## Fork workflow
>
> A fork creates an editable local Skill with its original author and licence. The request authorizes copying and local installation.
> 1. Check `./skills/threejs-procedural-vegetation`, the project lockfile, and selected Agent targets together. If the local directory or installed Skill exists, stop. Never overwrite an existing directory or Agent target.
> 2. Read [source metadata](https://skilld.dev/api/v1/skills/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation) once. Use sourceUrl, sourceCommit, skillPath, sourceGone, and license. If the source is gone or its path is missing, stop. If license is null, read licence files at the source commit.
> 3. Fetch only the source commit into a temporary Git repository. Do not clone full history. Derive repository_url from sourceUrl, including repository renames. If sourceCommit is absent, resolve the sourceUrl ref once. Set source_commit to that actual commit. Run these commands in one shell call:
>
> ```sh
> git init --quiet "$temporary_dir"
> git -C "$temporary_dir" fetch --quiet --depth=1 "$repository_url" "$source_commit"
> git -C "$temporary_dir" checkout --quiet --detach FETCH_HEAD
> ```
>
> Read applicable licence declarations and notices at that commit. If copying is not permitted, report the restriction and stop.
> 4. Inspect source entries together, then copy the directory containing skillPath into `./skills/threejs-procedural-vegetation`. Use the user's path if selected. Keep the original SKILL.md, relative links, scripts, binary assets, and executable modes. Exclude .git metadata. Reject symlinks and paths outside the Skill directory. After checking entries, use cp -a where available. A regular source directory needs no custom copy script. Do not save this page wrapper as SKILL.md.
> Preserve author credit, notices, and applicable licence files from repository or parent directories. Add PROVENANCE.md with the Skill page, source URL, actual commit, original path, and licence. Retain any existing PROVENANCE.md and record new provenance separately. Batch source inspection, copying, and provenance work where practical.
> 5. In the project root, run `skilld install ./skills/threejs-procedural-vegetation --mode copy --plain`. If skilld is unavailable, use `npx skilld install ./skills/threejs-procedural-vegetation --mode copy --plain`. This known command needs no help lookup. Install does not support --json. Use detected Agent targets, or add --agent for the targets the user selected. Install the local path, never the upstream selector. If installation fails, preserve the local copy and report the exact failure.
> 6. Confirm the local lockfile source and installed Agent copies once. Report the local path, actual commit, and Agent targets. After edits, reinstall the same local path. Upstream updates must not replace it. Do not publish or push unless the user asks.

# Procedural Vegetation

Represent a plant as a growth hierarchy plus rendering adaptations. Do not model it as randomly scattered cylinders.

This skill contains exemplary examples and assets beyond descriptive guidance,
they're worth studying, referencing, or even copying. Use them sufficiently
when relevant and do NOT blindly skip them.

## Build sequence

1. Define a per-level species table: length, radius, taper, child count, emergence range, angle, twist, gnarliness, sections, radial segments.
2. Grow branches iteratively from a queue so recursion depth and budgets remain inspectable.
3. Emit each branch as oriented rings with an intentional UV seam.
4. Update section orientation from:
   - inherited direction;
   - stochastic curvature;
   - tropism or external force;
   - optional attraction constraints.
5. Spawn children with stratified longitudinal slots and independently permuted angular slots.
6. Generate leaves only after branch topology is stable.
7. Build foliage normals from both card orientation and local crown volume.
8. Choose wind scope explicitly. Leaf-root deformation, branch hierarchy deformation, and whole-tree sway are separate systems.

Read [references/structured-ash-growth-system.md](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/references/structured-ash-growth-system.md) and preserve its preset, continuation, child-placement, leaf, material, wind, and composition contracts before tuning.

Read the [Ash Growth System implementation](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/examples/structured-ash-growth/tree-system.js)
with its [authored preset](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/examples/structured-ash-growth/ash-preset.js) for a
contract-accurate implementation and its diagnostic attributes.

Read the
[stylized meadow grass implementation](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/examples/stylized-meadow-grass/grass-system.js)
for authored blade-cluster geometry with a procedural fallback, image-driven
path masking, per-instance origin/facing attributes, circular-arc rooted wind,
gust fronts, tip flutter, color clumps, macro variation, translucency, and rim
diagnostics.

Read the
[GPU-computed grass implementation](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/examples/gpu-computed-grass/gpu-grass-system.js)
for MRT blade-parameter generation, deterministic terrain-conforming placement,
Voronoi clumps, Bezier blade folding, wind-facing yaw, distance LOD/culling,
normal/color fading, translucency, and field diagnostics.

Read [references/gpu-culled-flower-field.md](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/references/gpu-culled-flower-field.md)
for the exact virtual-address, ecology, hierarchical-compaction, indirect-draw,
distance-tier, atlas, wind, contact, resource, and diagnostic contracts.

Read the
[GPU-culled flower-field entry](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/examples/gpu-culled-flower-field/gpu-culled-flower-field.js)
and its complete
[raw WebGPU implementation](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/examples/gpu-culled-flower-field/source/gpu-culled-flower-field.ts)
for zero-record integer candidate reconstruction, 32 by 32 tile culling,
three visible-ID streams, indirect near/middle/far draws, curved textured
petals, identity-preserving horizon heads, and rooted moving-contact response.

Read the
[procedural surface ivy entry](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/examples/procedural-surface-ivy/ivy-effect.js)
and its complete
[TypeScript implementation](https://skilld.dev/api/skills-raw/scottstts/threejs-awesome-graphics-agent-skills/threejs-procedural-vegetation/examples/procedural-surface-ivy/source/ivy.ts)
for seeded spline-following stems, repeated mesh reprojection, tangent-plane
creep and droop, parallel-transport tube rings, growth reveal, instanced leaves
and umbels, and rigid petiole-hinge wind. Treat the TypeScript modules as the
only implementation; the entry file only re-exports them.

## Visual failure conditions

- branches form visible helices;
- dense grass ignores terrain height or clump-level variation;
- every child emerges at the same relative height;
- bark texture scale changes with branch radius;
- leaves reveal flat card normals under rotation;
- leaf wind moves card roots instead of remaining anchored;
- branch wind is claimed to match a reference whose branches are static;
- different seeds change species identity rather than controlled variation;
- geometry cost grows without a per-level budget;
- surface-following stems are offset from the host or flip normals across seams;
- ivy branches ignore the tangent plane while attached;
- leaf wind rotates around the card center instead of the petiole.
- a million-flower field allocates CPU transforms or per-candidate records;
- distant flower LOD replaces species identity with one generic sprite;
- compaction and direct rendering reconstruct different roots or acceptance;
- flower heads stay world-up after their stems bend.

## Routing boundary

Use `$threejs-procedural-geometry` for generic branch-ring emission without a
growth model. This skill owns species tables, vine and branch topology,
surface-following growth, foliage, grass fields, roots, and rooted wind.
