# Tree

by NightElfik

Short link: http://malsys.cz/g/JFI1IzqW

### Comments

comments powered by Disqus### Source code

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | lsystem Tree extends Branches { let d1 = 94.74; // divergence angle 1 let d2 = 132.63; // divergence angle 2 let angle = 18.95; // branching angle let l = 1.109; // length increase rate let w = 1.732; // width increase rate set symbols axiom = /(45) F(100, 1) A; set iterations = 6; set initialAngle = 90; set tropismVector = {0, -1, 0}; set tropismCoefficient = 0.15; set scale = 0.7; interpret F as DrawForward; interpret f as MoveForward; interpret & as Pitch(-angle); interpret / as Roll; rewrite A to F(50, w) [ C & F(50, 1) A ] /(d1) [ C & F(50, 1) A ] /(d2) [ C & F(50, 1) A ]; rewrite F(length, width) to F(length * l, width * w); rewrite f(length) to F(length * w); rewrite C to f(-1) &(-90) f(1) &(90); // correction } process all with SvgRenderer; |