Thanks for this useful script!
Sapling: A Tree Generator Add-On for Blender (OSX Fix 10 Aug 2011)
Atom, bat3a, I completely agree with your observation of the motion of the leaves. Unfortunately, motion of the individual leaves was not addressed in the paper I used as the basis for this script. Currently the only option I can think of to rectify this is to add a bone for each leaf. I am hesitant to do this because the armature creation is the slowest part of the script and the bone count would increase significantly. Any ideas on other methods I could use would be great.
Thanks for finding this PKHG, this was due to a change I made to the method of finding the direction of branches. I’ve fixed this and uploaded the revised script.
For the leaves, you could use softbody or cloth. Did a little test on a branch, setting the base vert on a few leaves as a pinning group which I’ve attached. Possibly using three verts as the pin may be better, plus the zillions of properties from the softbody sim. The red leaves have been pinned…
Oops file too big for here @2meg
Very cool leaves from kaicent, hopefully we can collaborate for some nice integration! Cheers
thanks for the comments guys.
The leaves are made by using hair particles i have different systems set up allready. i will post a blend.file soon (Still want to do some cleanup and a paper on how to use is properly)
for the moment the best way to apply it to the sapling curve is to convert the curves to a mesh and add vertex groups on the twigs (select the base than invert selection and add to new vertex group) after this i can add my hair (leaf) particlesystem. i could even make it dyamic and wave in the wind.
i think a lot about the integration and i think the only way to do it is to convert the branches to a mesh with the armature applied to it. like some button at the end wich will say convert tree.
It would be nice to automate the vertexgrouping as well so only the twigs will have a vertex group called density so i can set it in the particle emitter
Hi kaicent, I have an idea on how to retain the original curves and still be able to use particles. I’ll try and put something together over the next few days and post it here.
Added this quick little hack to add a pin to the base of all the leaves. Then used softbody for the leaves object with stiffness pretty high 0.9 and damping around 0.2 and am getting reasonable results, especially after putting a wind field in the scene. Would also be pretty simple to add some sort of weighting pattern to your six vertex leafs to make the stems appear stiffer.
Looking forward to seeing kaicent’s hair leaves.
replace leafMesh.validate() at around line 720 in utils.py with this
#### Quick hack to add PINS for softbody leaves i = 0 pinGroup = leafObj.vertex_groups.new("PIN") #pin =  verts = leafMesh.vertices #print("adding pinning") while i < len(verts): pinGroup.add([verts[i].index],1.00,'ADD') # could add stiffness thru stem here #pinGroup.add([verts[i+3].index],0.5,'ADD') i += 6 #pinGroup.add(pin,1.0,'ADD') leafMesh.validate()
and you have a vertex group “PIN” to use as the goal in the softbody sim.
thanks for taking the time i am very interested in how you will do it!
let them grow!
tell me what you think
That looks awesome Kaicent.
Here’s a quick preview of using particle leaves while retaining the original curves and using image mapped planes for the leaf ‘particles’.
A full res version can be found here. I know that leaf at the bottom of the tree shouldn’t be there, but I forgot about it when I rendered :spin:. Hopefully I’ll be able to iron out a few of the particle leaf issues and post a new version of the script soon with particle leaves included. I haven’t decided yet if I’ll ditch the mesh leaves all together, I might just leave them in there as an option for the user.
PS The leaf texture is from CG textures
thanks for the greatr updates
I think mesh leaves can be useful still.
i cant wait for it. you dont have to ditch the mesh leaves the option is enough for me and the peaople who want to use the library. but you could take the mesh and add it as a particlesystem wich would give you more control about the behaivior of the leaves. If you put the option in it i could extend the library regulary and you dont have to integrate it.
thinking about a new website to collect free premapped leaves as blendfiles. Highres for rendering and lowres for games.
also i am trying to figure out how the ivygenerator works this would also be great to have in blender
it is by the university of konstanz so i will ask for some papers.
Also i found this site with a video showing how they do it.
papers and application available soon!!
WHY DIDNT I FIND THIS A MONTH AGO? thanks very much!
we already have permissions & have started porting the ivygen to Blender.
you can see the progress here: https://svn.blender.org/svnroot/bf-extensions/branches/ivygen/
if you like, as the dev who started this is dormant, you could build upon his work.
Also I’ll get together my leaf files for you & upoload them soon.
great job so far!
It would be awesome if you could join here: http://projects.blender.org/projects/bf-extensions/
This script is very awesome & It would be a great addition to Blender’s addon tools.
Have you seen this page? http://lsystem.liquidweb.co.nz/Home/tabid/117/Default.aspx
You could also drop in irc freenode #blenderpython if you have any questions.
With plenty of help from Meta, there are now wiki and tracker pages. See the first post for links. Nothing much in the wiki yet, but I’ll get to work on it.
Congrats Truman! Well done.
I tryed ivytest.py removed a number of things not possible in 2.57 and got (see picture)
thanks for the information and thanks for the leaf files.
open source rocks!