Pages

Sunday 28 June 2015

Diffusion Limited Aggregation over 3D Surfaces


Here is a preview of the results from a DLA system created primarily with the Solver SOP.

What you can see is every tenth frame of the systems growth, what you don't see is the systems simulation frames. I created a method to only save .pc files as the current point became part of the growth system, omitting the points during their random walk towards the growth system.
Also it's not immediately obvious but the point in the growth system are actually moving over the convex surface.

There are a bunch of useful point and detail attributes created for the system, eg. creation frame, life etc.



Also here is a clip showing the simulation process, to get a nice formation it can take a long time. I do envisage that once some efficiencies are made and the system is turned into an asset, it could be tweaked to run faster. Although I guess, that's also the nature of sims.



If you'd like to find out more about the math and logic involved, my system is loosely based on the of Robert Walker.

Monday 15 June 2015

DOP Multiple Cloth Objects using Copy SOP

Multiple Cloth Objects can be created using the Cloth Object DOP, where the Initial Geometry contains multiple pieces of geometry, e.g.. Grids. (In many cases this geometry would be created by way of the Copy SOP). Actually to be more specific the key is Primitive Groups not so much pieces of Geometry, although those usually coincide.

Before continuing, I have to mention that although this process technically does as it says. The aim was to constrain each Cloth Object individually and dynamically(number of Cloth Objects). I have found it didn't give me the outcome I was looking for, ie. Constraints only work on a single Cloth Object, however I do think the may be a way, possibly using Copy Data DOP.

On the Creation tab of the Cloth Object DOP changing the following parameters:-

  • Number of Objects : This would contain an expression that equates to the number of copies required, this will depend on your particular setup. 
    • Pointing to the Number of Copies parameter of the Copy SOP using ch("your_copy_sop_location/ncy") would be one way.
    • Using the npoints("your_copy_sop_location") expression could also be used when there are Copy SOP Template Points being used
  • Object Name : "name_prefix" $OBJID   note : Quotes aren't required for the name_prefix 


Now this setup so far will create x number Cloth Objects with exactly same Geometry! So the trick is to isolate the Geometry for each Cloth Object based on the Primitive Groups created in the SOP context, in this case by way of the Copy SOP. As you'll notice there isn't any Group or Primitive Group parameters on the Cloth Object. You can however add the appropriate parameter, by editing the parameter interface of the Cloth Object DOP you can add a parameter - Primitive Group. It can be found via the Create Parameters - From Nodes tab, expand +Cloth Object + clothconfigureobject1 + sopgeo_initialgeometry1(Geometry) + Primitive Group (primgroup). move the parameter to the Cloth Object Creation tab. Finally in the Primitive Group parameter place an appropriate group name followed by the object id variable : "your_primitive_group_name"`$OBJID`   note : $OBJID could be affected by other simulation objects




The following screenshots show the Cloth Object and Geometry Data before and after the changes. Notice the standard setup Cloth Object contains all the copied geometry points, apposed to the altered setup, has multiple objects which only contain a subset of geometry based on the primitive group/s.