threejs-worldgen
    Preparing search index...

    Function generateRock

    • Generates a rock: an icosphere displaced by fBm (lumps) and Worley noise (facets and cracks), squashed, stretched and cut flat underneath, with vertex colours for weathering and moss on top. Deterministic in params and seed. The base sits at y = 0. Attributes: position, normal, uv (spherical), color.

      Parameters

      Returns BufferGeometry