Leaf texture hack for Arbaro trees

Started by bigben, August 26, 2007, 09:21:21 PM

Previous topic - Next topic

bigben

The default Arbaro leaf shape is "disc", which is a rough leaf-shaped polygon. This works well from a distance but starts to look a little fake when you get closer.  Rather than change the leaf to a square and then use an alpha-masked leaf texture I thought I'd try a hack by cropping a rectangular image out of the centre of a leaf texture.

[attachimg=#1]

This is then simply mapped to the leaf shader of the object.

It's not perfect, but it does provide for a more realistic leaf at closer range. Here's a preview of the leaf texture. The render's almost completed.

old_blaggard

http://www.terragen.org - A great Terragen resource with models, contests, galleries, and forums.

bigben

#2
Here's the final full res render. It looks like I had a wee problem exporting from Arbaro with a loss of leaves on the lower branches (although it's only a 25Mb model, which is a lot smaller than the willow)... and the trunk could be made a bit smoother.  Will have to check the settings in Arbaro

It's not perfect, but the extra shading also seems to distract the eye from the low edge count on the leaf shape... now for stage 2... making it sway in the breeze.

old_blaggard

This is very convincing!  It looks like Arbaro can be used to give some pretty interesting results.  Thanks for the details and inspiration.
http://www.terragen.org - A great Terragen resource with models, contests, galleries, and forums.

bigben

Don't forget you can always change the leaves to squares (rectangles), shorten the stem length to 0 and borrow some "traditional" leaf texture images from other models. 

The animation step is where Arbaro can have a big use for TG2. By producing a series of XML files of the same model with varying curvatures for some of the branch settings, you can generate a series of models for an animation with moving branches.... Rather than create multiple models, I just create one, set it up in TG2 and then render the animation via commandline, inserting a command for Arbaro to generate a new OBJ model (overwriting the same file each time) prior to rendering the frame in TG.  This saves a lot of disk space (100 x 3.5kb xml files vs 100 x 20-80Mb OBJ files) and there's aboslutely nothing else needed in the TGD.

I was going to stick the tree in a field of barley but the render time is long enough as it is. I might adjust the camera angle to look up at the tree with some barley in the foreground. Getting the horizon out of the shot should also save some render time (the last few rows of pixels along the flat horizon took a substantial amount of time to render). It'll probably be next week by the time it's finished.

old_blaggard

Again, thanks for the tips, especially about the animation idea.  Animation is one of my favorite things in TG, and being able to animate the vegetation would be fantastic.
http://www.terragen.org - A great Terragen resource with models, contests, galleries, and forums.

moodflow

Very nice work BigBen!

I was pretty much giving up on Arbaro, but this could bring back some use of it.
http://www.moodflow.com
mood-inspiring images and music