threejs-worldgen
    Preparing search index...

    Interface LeafImage

    RGBA8 pixels of a procedurally drawn leaf card; row 0 is the bottom (v = 0, where the card attaches).

    interface LeafImage {
        data: Uint8Array;
        size: number;
    }
    Index
    data: Uint8Array

    RGBA, 4 bytes per pixel. RGB is a grey detail value (multiplied by the leaf colour), A is coverage.

    size: number

    Width and height in pixels.