threejs-grass
    Preparing search index...

    Interface GrassSettings

    Every setting of a Grass field. All are optional on input; see GrassInput.

    interface GrassSettings {
        baseColor: string;
        bladeHeight: number;
        bladeWidth: number;
        buildBudget: number;
        castShadow: boolean;
        clumping: number;
        clumpSize: number;
        colorVariation: number;
        curvature: number;
        debugLods: boolean;
        density: number;
        grassMap: GrassMap | null;
        heightVariation: number;
        interactionStrength: number;
        interactors: Interactor[];
        lods: GrassLOD[];
        maxDistance: number;
        maxSlope: number;
        patchiness: number;
        preset:
            | "kentuckyBluegrass"
            | "perennialRyegrass"
            | "tallFescue"
            | "bermudaGrass"
            | "zoysiaGrass"
            | "stAugustineGrass"
            | "buffaloGrass"
            | "fineFescue"
            | "toonMeadow"
            | "goldenSavanna"
            | "autumnHaze"
            | "frostbite";
        receiveShadow: boolean;
        shadowDistance: number;
        stiffness: number;
        sun: DirectionalLight
        | null;
        tileSize: number;
        tipColor: string;
        translucency: number;
        type: "blades" | "billboards";
        widthVariation: number;
        wind: WindOptions;
    }

    Hierarchy (View Summary)

    Index
    baseColor: string

    Blade colour at the root (any CSS colour).

    bladeHeight: number

    Blade height in metres. Any height works (lawns ~0.1, meadows ~0.5, tall grass 1–3).

    bladeWidth: number

    Blade width at the base in metres.

    buildBudget: number

    Milliseconds per frame spent (re)building tiles, nearest first. Spreads work to avoid frame spikes.

    castShadow: boolean

    Whether grass within shadowDistance casts shadows (needs a shadow-casting light).

    clumping: number

    0..1 how strongly blades gather into tufts that splay outwards.

    clumpSize: number

    Tuft diameter in metres.

    colorVariation: number

    0..1 per-blade brightness variation.

    curvature: number

    0..1 natural droop of blades when there is no wind.

    debugLods: boolean

    Tints grass by LOD (red, yellow, green, blue) to help tune lods.

    density: number

    Blades per square metre at full density (LOD 0).

    grassMap: GrassMap | null

    Coverage/height control texture; see GrassMap. null = grass everywhere.

    heightVariation: number

    0..1 random height spread per blade.

    interactionStrength: number

    Global multiplier on how strongly interactors bend grass.

    interactors: Interactor[]

    Up to 16 objects that push grass aside.

    lods: GrassLOD[]

    Exactly four levels of detail, ordered near → far.

    maxDistance: number

    Radius (metres) around the camera that has grass. Blades fade out over the last 15%.

    maxSlope: number

    Steepest terrain gradient (rise / run) that still grows grass. Infinity disables the check.

    patchiness: number

    0..1 field-scale light/dark and dry patches.

    preset:
        | "kentuckyBluegrass"
        | "perennialRyegrass"
        | "tallFescue"
        | "bermudaGrass"
        | "zoysiaGrass"
        | "stAugustineGrass"
        | "buffaloGrass"
        | "fineFescue"
        | "toonMeadow"
        | "goldenSavanna"
        | "autumnHaze"
        | "frostbite"

    Starting look; any GrassStyle field you pass overrides the preset's value.

    receiveShadow: boolean

    Whether grass receives shadows.

    shadowDistance: number

    Radius (metres) around the camera in which grass casts shadows. Shadows are costly: keep it small.

    stiffness: number

    Higher = less wind/interaction bending.

    sun: DirectionalLight | null

    Light used for back-lit translucency. null = first DirectionalLight found in the scene.

    tileSize: number

    Edge length of a streaming tile in metres. Tiles are re-centred around the camera.

    tipColor: string

    Blade colour at the tip (any CSS colour).

    translucency: number

    0..1 how much sunlight shines through blades when back-lit.

    type: "blades" | "billboards"

    Detailed geometric blades, or lightweight view-facing billboard tufts.

    widthVariation: number

    0..1 random width spread per blade.

    Procedural wind; see WindOptions.