Vex and VOPs – A Twist Deformer (Part 2)

So twisting some points around the origin was easy, but not useful as a generalized tool since you really need to place the twist anywhere it’s needed in world space.

The trick to this is to create and store a transformation matrix based on the origin of your control object, then move your deforming geometry to the origin via the inverse of that matrix. Then, after performing the deformation, apply the stored transformation matrix to move your deformed geometry back to where it was in world space.

Getting the vex wrangle right took me a fair amount of teeth pulling because I’m so new, and frankly it feels like it could be reduced to something a lot simpler. Email me if you see a better or cleaner way! Here’s what I ended up with:

// Create vectors to fill matrix using the second node input's transform
vector translate = set(`chs(opinputpath(".", 1)+"/tx")`,`chs(opinputpath(".", 1)+"/ty")`,`chs(opinputpath(".", 1)+"/tz")`);
vector rotate = set(`chs(opinputpath(".", 1)+"/rx")`,`chs(opinputpath(".", 1)+"/ry")`,`chs(opinputpath(".", 1)+"/rz")`);
vector scale = {1,1,1}; // I'm not worrying about scale...

// Build the transform matrix of the control object
matrix xform = invert(maketransform(0, 0, translate, rotate, scale));

// Apply the matrix to the current points to move them to the origin centered on control object
@P *= xform;

// Store the matrix to return to original location after deformation
4@xform_matrix = xform;

Yeah so there you go, that takes up a pointwrangle before the deform VOP and then a little wrangle after it returns the points to world space:

@P *= invert(4@xform_matrix);

Here’s a houdini take on that original twist scene using this setup:




Vex and VOPs – A Twist Deformer

Now let’s do something a bit more demanding. We will replicate the twist deformer I made in ICE in VOPs, and then use some vex wrangles to allow a control object to place the twist deformation anywhere on the object in world space. Here’s the actual twist deform VOP, with a little extra to make the twist into a whirlpool funnel shape:

Pretty straightforward, the VOP takes a radius of points around the origin and pull them down in Y as well as rotates them around the origin, with a falloff based on distance and ramps to allow for user control.

Nodes Aplenty, and Mantra too

Making a hexagonal sphere is easy enough, just hit a polygonal sphere with a divide SOP and viola. Hit that with a wireframe SOP and an attribute wrangle to ramp the color and alpha and, well, it’s just a hexagonal sphere. But it’s a good chance to hop into Mantra and fiddle with settings. Oh, this DoF rendering is nice. Thumbs up for Mantra I know that everyone has their favorite flavor of the month renderer but I have to say Mantra strikes me as a real workhorse. I like it.

Yep, it’s a hexagonal sphere. Tadah. Let’s hit that with the connect points SOP/wrangle asset I made for the spirals…

Well that’s pretty much what you’d expect. I love how effective the few assets I’ve made are. Now an asset itself, expect to see this hexagonal sphere again, I’m enamored with it.

Hello, Houdini.

Ok, so Houdini. Like most people I found the initial experience daunting. Cinema 4d is like a warm blanket, Houdini is completely the opposite having a lot of cryptic nodes to learn, many of which have evolved far beyond what they were first intended to do. Being a proceduralist that part of Houdini was amazing to first explore, but there’s a lot of ground to cover and caveats everywhere that can only be worked through by getting hands-on with every inch of this software.

Wheee! This is both fun and completely daunting.

But ok, I’m getting comfortable. VOPs was a no brainer for an ICE guy so I started there and that quickly turned me on to VEX and lovely attribute wrangles. First up, let’s make some lines, and then make some spirals. W00T.

Yep, phyllotaxis and phi resurface. Same concepts, new toolset. For a while I’ll be covering similar ground to prior posts as I rebuild much of my ICE production toolset as Houdini Assets. Now I have a set of .hip assets to create different kinds of spirals, connect lines to points and the like. Stuff in everyone’s toolbox I would think… should I share simple stuff like that here? I’ll probably make a wrangle cheatsheet for little stuff like this and share that.

See you, Softimage…

Well, they did it. Autodesk killed Softimage, despite it’s huge potential and growing audience using ICE. Sadly Fabric Engine has disappeared as well. My response? Return to my roots for a while and make fine art glass. A complete change from CGI but a lot of fun! But don’t worry, there will be more CG discussion coming up as I dive into Houdini and explore!



Example: LK Fabric early test scene

Since LK Fabric is out I dug up one of the early test scenes we used on Nike “Evolution” at Royale in which we developed some of the techniques we used to get various looks. This setup is very basic but covers some of the key tricks for getting a natural result and was used as a starting point for a number of shots.


I have replaced the original many-versions-old compounds with ones from Leonard’s public release, and have also left in a few “helper” compounds I built which weren’t part of his official release. I then removed everything superfulous to the basic effect and commented the resulting ICE tree throughout. Any typos or misspellings are entirely my fault. :D




The actual setup is very simple.

This scene demonstrates:

  • A basic setup of a single evolving swatch of fabric, with the most basic pattern and the modifiers we used most often.
  • Using the “slide profile over U/V” compound and other techniques to shape the leading edge of fabric growth.
  • Using the “offset” core parameter to make the leading strands animate and form a shape for the thread tips.
  • Using a second ICE “post” effect to add per-strand variance and “frizz” effects.




The early tests like this were pretty chaotic, we knew the system did a good job of creating a “perfect” weave so we were pushing in the other direction and adding ways to create chaos and randomness.

Ironically despite the first briefs being focused on “organic” and “evolving” concepts the client spent much of the latter half of the job dialing in a more out-of-box mechanical look… that’s the way it goes sometimes. But this means there is a lot of capability which hasn’t been seen yet. I’d love to see some people use some of the per-strand and per-thread modifiers, and the capability to create patterns beyond the basic “canvas,” to create a more organic, aggressive look.



Here’s the file (Softimage 2013 scene file, ~0.6mb): LKFabric_AMexample1

Example: A Reticulate Noise Function

Here’s a scene file and a couple of compounds which compute a simple noise function and then create a reticulated “push” from it. It’s meant to demonstrate how a simple spatial noise can be layered on itself to create a fractal, visually pleasing result, as well as give a little insight into how functions like perlin, worley, turbulence etc can be similarly layered to create a huge variety of natural looking patterns.


Scene file and compounds (softimage 2013): example_ICE_reticulation

LK Fabric released

LK Fabric has been released!

Congrats to Leonard Kotch who put his heart and soul into this and who put up with my endless demands for the system during the production.

Pretty much everything you see in the Nike commercials below was built with this system, with Leonard doing daily updates as we worked. We barely touched some of the possibilities of this system, I hope people will try it out because it is cable of some truly spectacular effects. Kudos to Royale for being so cool and sharing it out like this!