top of page

Diffusion Limited Aggregation

Aim

The aim of the project is to create fractal like growth inside 3D geometry using the principle of Diffusion Limited Aggregation. The implementation has been done in two parts: Text and 3D Geometry and Intersection. The first part involves working with a single geometry, filling the geometry using growth effect. The second part, however deals with how the growth will perform when two or more objects are in contact or are penetrating into each other.

Concept

The process of Diffusion Limited Aggregation consists of the following main parts:
• The initial seed(s) called the “aggregate” which will start the growth process
• A particle called “walker” at a location inside the geometry which will undergo random walk to reach the aggregate
• Collision happens between the walker and aggregate following which the walker stops and becomes part of the aggregate
• Generating new walker which will go through the same process as the previous one
• Repeating the process until the aggregate has grown to the desired size

Implementation

Defining Initial Aggregate 

The user is given the flexibility to choose his/ her own initial seed region. Through the Paint option in Houdini, the user can paint over any region of the geometry and the points scattered over that region will act as the initial aggregate. The Paint SOP provides a very visual way with a better control to choose the growth region.

For intersection, the user is given the choice to use his/her own intersecting geometries in addition to the main geometry. Unlike the 3D Geometry and Text, the initial aggregate for intersection is defined by the area of intersection of two or more geometries.

Scattering Internal Particles

The user is given the flexibility to choose his/ her own initial seed region. Through the Paint option in Houdini, the user can paint over any region of the geometry and the points scattered over that region will act as the initial aggregate. The Paint SOP provides a very visual way with a better control to choose the growth region.After initial aggregate area is defined on the main geometry, the procedure for growth has to be set up. This is done by scattering the particles within the geometry since the growth will take place inside. For this purpose, the geometry is converted into a volume using IsoOffset with the Uniform Sampling Divs set to 100. The points are then scattered inside the fog volume using Scatter node. Once the points are scatted, they need to know the color information from the surface which is accomplished using Attribute Transfer.

For intersection, the user is given the choice to use his/her own intersecting geometries in addition to the main geometry. Unlike the 3D Geometry and Text, the initial aggregate for intersection is defined by the area of intersection of two or more geometries.

Generating Random Walkers

Random walkers are particles which will via random movement collide with the aggregate points for the process of growth to begin. The generation of random walkers is done inside the pop network which handles particle simulation. The POP network uses the particles scattered inside the volume as emitters for the random walkers.

Collision and Growing Aggregate

Now that random walkers are generated, it is to be checked if during their random movement they collided with the initial aggregate or not. If the collision happens, the new aggregate is defined including the point which collided else random walk continues.

Algorithm: Walker collision with growing aggregate

1. select search distance
2. find two neighbor points within search distance
3. loop through neighbor points
4.    fetch point number of neighbor points
5.    if neighbor point belongs to aggregate group
6.         stop current point
7.         regroup from walker to aggregate group

8.         change color
9.    endif

10. end loop

Algorithm: Stopping emission based on new aggregate

1. select search distance
2. find the nearest aggregate point
3. calculate nearest point position
4. calculate distance between emitter and respective nearest point
5.    if distance < search distance
6.         remove from emitter group
7.    endif

8. end

Joining Aggregate Points

inside the POP network the “nearpt” of each walker is found and if that point is part of the aggregate or stopped group the walker is stopped. At the time when the walker is stopped, a connection is established between the walker and its “nearpt”. As the point number of both the points is known at this instance, they can be joined using a polyline by adding vertex to both using addvertex() function and setting connection using addprim(). In this manner, as each walker is stopped it connects to the point which stopped it using a polyline giving a propagation like growth effect.

SimpleDots.png
Simple_wire.png

Adding Geometry

Now that we have both points and lines, these can be used for carrying geometry which could then be used for the application of different shaders or textures or simply colors to add aesthetic appeal.

1. Wire Fill

vary_with_dist.png

Wire Fill: Uniform width

Wire Fill: Varying width with distance from boundary

Wire Fill: Geometry added on seed points

2. Object Fill

Uniform.png

Object Fill: Uniform scale

Vary_dist.png

Object Fill: Scale varying with distance

nonoverlap.png

Object Fill: Check overlap

Object Fill: Complete Fill

3. Intersection

Wire Fill: Varying width with distance from the intersection points

injection_demo_start.png

Object Fill: Area of interaction as the starting point

Wire fill on intersection with geometry on seeds

intersection_demo_fill.png

Object Fill: Complete fill

colored_points.png
painted_teapot.png
injection_visualization_points.png
Screenshot from 2017-08-07 17-23-01.png
Screenshot from 2017-08-07 17-22-15.png
Uniform.png
add_geo_3d_geo.png
Full_fill.png
intersection_vary.png
intersection_add_geo.png

Application

The section deals with three of the many possible ways the tool could be used for. Two different 3D models: teapot and rubbertoy and a 3D text has been used to show the adaptive ability of the tool.

Vines

The connecting lines when applied with polywire could be used for vine like growth effect. Polywire with the option of decreasing width with distance enabled has been used. This would, as stated before have finer branches near the boundary of the geometry and thicker ones towards the center. Default flowers are copied onto the seeds of growth, again with a variation effect with respect to distance to have a better visual appeal. Instead of simply copying, the growth of the flower can also be animated by scaling them with time but that aspect has not been considered here. Apart from just the addition of the flowers (or any user preferred geometry), the user is given the control to remove flowers from any location of the geometry. This is accomplished using Paint tool. The removal area is painted upon and the seeds of growth which inherit the painted color using attribute transfer will no longer act as seeds of growth and any geometry placed on these points will be removed. The purpose of the removal option is to give user further control over where to add the
additional geometry.

Uncanny Growth

The propagation effect of DLA can be used to show spreading of disease, virus or any such uncanny growth effect. The application shows the growth of an organic like matter which spreads inside the geometry and subsequently engulfs it. For this effect, metaball with the copy to points option was chosen. The reason of choosing metaball is because it provides a simple method for creating organic looking surface. The effect has the feel of a blobby substance covering the geometry. It was tested with both uniform color and color variation with distance, each giving interesting results in its own stand.

uncanny_growth.png

Injection

The injection effect is similar to the uncanny growth effect with the spread of blobby substance in the geometry. It is called the injection effect because it appears as if the two rods are injecting or releasing the blobby material into the geometry. The result is similar to the spreading effect shown in the wolverine adamantium scene, X-Men Origins Wolverine.

Screenshot from 2017-08-01 18-24-19.png
Screenshot from 2017-08-01 18-19-46.png
Screenshot from 2017-08-01 18-24-32.png
uncanny_growth_uniform.png
injection_start_1.png
injection_fill.png
injection_empty.png
JR

Final Report

A report with detailed discussion about process of development and the problems encountered.

bottom of page