Page 1 of 1

decimating the leaves on a tree/clipping maps

Unread postPosted: Tue Jun 30, 2020 4:51 am
by witheredhack
Hi, I have some tree models which have a few too many leaves. The leaves are a simple plane to which the image maps are applied to as a UV with an alpha/clipping mask.

I'd like to reduce the amount of leaves on the tree by about 25%.
I had a few ideas but was not sure how to get them to work.

1) some kind of switch/instance colour setup (where one of the colours has an alpha of 0) piped into the opacity input of the material?
2) run the leaf material through a shading layer and associate the material with a clipping mask, and have that clipping mask somehow randominsed so on 1 of 4 instances it returns an alpha of 0
3) use the existing leaf geo to drive a scatterrer and tweak as required.

Any thoughts or other ideas?

thanks

Re: decimating the leaves on a tree/clipping maps

Unread postPosted: Tue Jun 30, 2020 9:40 am
by dboude
Hi,

Number 2 is the way to go. Opacity is heavier to evaluate than clipped geometries. But how did you export your trees ?

Cheers

Re: decimating the leaves on a tree/clipping maps

Unread postPosted: Sat Jul 04, 2020 10:26 am
by witheredhack
Hi Demain,

I have a couple different models, one (obj) where the trunk, branches and leaves are all one mesh, but have different materials assigned to them. So I was using a shading layer based on materials to assign.
The other is an alembic, with leaves on one, and branches the other. Again a shading layer but identifying the geo name.

Can you give me an example of what the randomnised clipping mask solution might look like?

Thanks heaps,

Re: decimating the leaves on a tree/clipping maps

Unread postPosted: Mon Jul 06, 2020 8:20 am
by dboude
Hi,

With such geometries, it's not possible. You have to somehow export a property that has a different value (between 0 and 1 for example ) on each leaf. Then you would be able to clip leaves based on this property.

Another way will be like you describe on 3). Export Trunk + branches, and a primitive instead of each leave. Use this geo as support for a scatterer (with a point cloud set to primitive center). With this setup, you will use an instance color to clip or not the scattered leaf.

Cheers

Re: decimating the leaves on a tree/clipping maps

Unread postPosted: Mon Jul 06, 2020 11:09 am
by witheredhack
Ok, thanks Demian