VegPalms.module
This package holds more than this page lists. See all of its files in its world.
README.md
VegPalms
Deterministic generators for the tropicalProps palms: palmCoconutStraight, palmCoconutLeaning, palmWindBent, palmFan, palmYoung, palmCluster and pandanus. VegPalms.generate(kind, variant, form) returns { lods = { [0] = parts, [1] = parts, [2] = parts } } of VegGeo geometries named trunk, fronds, dry, nuts, grass. VegBake calls it; nothing loads it at runtime.
A palm is a trunk path (lean and curve per kind, all leaning toward +Z), a tapering tube with leaf-scar rings, a flared, lobed root ball and a fibrous crown boot, and a crown of fronds in a 137.5-degree spiral: young fronds stand up, old ones arch out and hang. Coconut fronds are a rachis tube with two rows of separate drooping leaflets (a V keel), longest 40 % of the way out; fan palms carry pleated, split-tipped fans on long petioles; the pandanus has stilt roots, forking arms and spiral tufts of keeled strap leaves.
Forms: real (shared by the real, painted and pixel looks), toon (fewer, broader lobed blades, stacked-segment trunk) and low (faceted). LOD1 keeps every third leaflet at 2.4x width; LOD2 is a trunk of 5 sides and one keeled ribbon per frond whose UVs repeat a leaflet along it. Leaflet UVs: u across (midrib 0.5), v 0 base -> 1 tip; bark: u wraps the trunk twice, v = metres.