L-System: Sympodial tree - Reboot

3dxml at the bottom.

 

Few years ago, I made some study on L-system sympodial tree 

https://r1132100503382-eu1-3dswym.3dexperience.3ds.com/community/swym:prd:R1132100503382:community:23?content=swym:prd:R1132100503382:communitypost:resgm8zVSJyaoE2Kj2hDbw

 

 

but I was missing the leaves. I thought it cool, worth sharing, however still no leave when we need shade. I kept that in mind until DS RD released "visual instance". 

https://r1132100503382-eu1-3dswym.3dexperience.3ds.com/community/swym:prd:R1132100503382:community:SNKdMgXCR8SJqa8lpbe7IQ?content=swym:prd:R1132100503382:communitypost:TU2ctnljQXe1bWEjDQAdQQ

 

 

I was sure they shared my feeling: no leaf, no live... so I decided to make a new study with leaves this time. new study, because with better understanding on how loop works, I am much closer to L-System original logic and I could almost divide by 2 the number of features needed to model the tree... so I think that it is more readable than before.

Here is the logic, the logic is still to drive a axis system which represents "the turtle" of the model

 

Initiate the model with the main trunk

Then set the growth ratio for the branch lengths. I start with 1000mm and then depending on which branch, the length is different. this breaks the symmetry of the tree

then I create the trunk. the important task is to set the initial radius for the trunk, it will be used for the branches in the loop

The loop has 3 inputs: the turtles / the branch lengths / the branch base radius

in the loop, let me focus on the Turtle input treatment. I follow L -system sympodial tree (B condition). as the A condition is done 1 time and corresponds to the initial trunk only! A condition is 1 time and never again.

turtle is moved forward, then split into 2 and pichted opposite direction of 35 deg. you could also break the symmetry, there with 50deg/-10deg for example. then there is tricky part to align the turtle to the horizontal. I used cross product with vertical direction and made it a "user feature". group the split turtles and set them as new inputs.

about the 2 other inputs: length and radius. it is not complex. so I skip the explanation.

I set 2 accumulators: one for the branch lattice, to be used for the leaves and 1 accumulator for the trunk surface, which I wanted to use lattice for smooth surface but could not make it work yet.

Then I copy pasted an old script of flower that could be used as leave. it gives a nice level of complexity to the model.

retrieving the extremities of the last generation of branches, I instanciated the flower to them.

finished.

 

here are some rendering trials (Real Time, not global illumination or ray tracing) -> 12 generations of branches.

also, it takes 10 to 15s !!!! while 2 years ago, I recall minutes of calculation with no leaves. DSRD rocks.

 

My favourite