This shows you the differences between two versions of the page.
collections [2018/10/18 10:14] |
collections [2021/04/27 09:19] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== Collections ====== | ||
+ | |||
+ | Collections allow tree geometry to be collected in a mesh asset while the model is being computed. This gathered geometry can then be used by generators and forces just as any other mesh asset would be. | ||
+ | |||
+ | ===== Creating a Collection ===== | ||
+ | |||
+ | {{ : | ||
+ | Collections are created via the Mesh Asset bar. Use the " | ||
+ | |||
+ | ====Collection Properties (Mesh Asset bar)==== | ||
+ | |||
+ | The two properties in this group allow you to control how the collection is created. | ||
+ | |||
+ | ====" | ||
+ | |||
+ | Use this tool under the menu item " | ||
+ | |||
+ | |||
+ | ===== Contributing to Collections ===== | ||
+ | {{ : | ||
+ | To make a generator contribute to a collection, look for the Collections group with the " | ||
+ | |||
+ | > **Note**: Order matters. Generators that contribute to collections should precede generators that use them during tree model computation. | ||
+ | |||
+ | Mesh forces can also contribute their geometry to collections. | ||
+ | |||
+ | > | ||
+ | |||
+ | |||
+ | ===== Examples ===== | ||
+ | |||
+ | ==== Example 1: Ivy growing on a zone ==== | ||
+ | |||
+ | {{ : | ||
+ | A good example where collections are useful is growing ivy off of the roots and trunk of a tree (see image to the right). The brute force way to do this is to use two nearly identical leaf generators, one linked to the roots generator and another to the trunk generator. The problem with this approach is that it is hard to get an even distribution or to use masks to uniformly control the areas where the ivy can grow. A better approach is to create a collection that captures the root and trunk geometry as it computes and then use that collection in conjunction with a zone generator to grow the ivy leaves. This approach provides the best way to get even, controllable growth off of the trunk and roots, even when the trunk and roots change shape. | ||
+ | |||
+ | ==== Example 2: Self-colliding branches ==== | ||
+ | |||
+ | Collections can be used to prevent branches from colliding with each other as they grow. For example, collect the roots of a tree into a collection and create a Mesh force that uses that collection. | ||
+ | |||
+ | ==== Example 3: Vines growing over a trunk ==== | ||
+ | |||
+ | Another good use of collections is when vines are growing over trunk geometry. In order to be able to change things about the trunk after the vines have been added, a collection of the trunk must be created first. Then, the vines can collide with a Mesh force that has been assigned the collection, which is self-updating. | ||
+ | |||