threejs-worldgen
    Preparing search index...

    Function growSkeleton

    • Grows a tree skeleton by space colonisation (Runions, Lane & Prusinkiewicz 2007): attraction points fill the crown, each pulls the nearest branch node within influenceDistance, nodes grow one segmentLength step towards the average pull (plus tropism and jitter), and points within killDistance of a branch are removed. Radii then follow the pipe model with radiusExponent.

      Each point remembers its nearest node; since nodes never move, only nodes added in the last step need checking, which keeps a few thousand nodes well under a few milliseconds.

      Parameters

      Returns TreeSkeleton