A user on si-community asked how to “move” the deformation in the earlier whirlpool example. Doing so involves a couple of matrix transformations – you basically force the points of the geometry to the global origin where you perform your deformation and them move them back to the local space they were in.
It’s a simple operation that I haven’t really figured out how to illustrate in a simple and intuitive manner yet… about the best I could do was to revise the scene so people can compare a “before” and “after”. The first scene is a working scene, it’s where I was assembling the basic deformation, it’s all relative to the global origin. This new scene then goes through the steps of making the deformation “production ready.” I clean things up, make the deformation operate in the object’s space, and package it all up as compounds.
Here are the compounds and the revised scene (2013): example_whirlpoolDeformer2
There are a billion discussions of the Fibonacci sequence, phi, the golden section etc. So I’m going to let you browse the wonderful web and largely find out about it for yourself (try here), with only this brief summary…
The Fibonacci sequence is a series of numbers such that the last two numbers of the sequence added together result in the next: 0,1,1,2,3,5,8,13… ie: Fn = Fn-1 + Fn-2.
If you take the ratio between any two consecutive numbers in the fibonacci sequence, they increasingly converge towards a single value, 1.61538 (memorize it!) which is called the “Golden Number” or Phi: Φ
This ratio is found throughout nature, as well as classical art, mathematics etc. It crops up in an amazing number of places. A logarithmic spiral in which points of the spiral are Φ units apart after a quarter turn is called a “golden spiral”, for instance, and can be found in seashells, seed pods, flowers, pinecones and as I said before, lots and lots of websites. If you’ve had a certain amount of coffee, this video might be illuminating:
Other artists using ICE have put out tutorials and compounds relating to these spirals, browse around (hint I’m one of them.)
Recently as I fiddled around I came across an interesting point about these kinds of distributions that caught my attention: they are a very efficient way to pack particles evenly on a surface. This is an important point to an effects artist, because not only is a large part of this job mimicking nature, but distributing points efficiently on surfaces lets us maximize the number of non-overlapping particles we emit.
So, I built some compounds, first to calculate phi (or simply return it as a stored constant, depending on the accuracy needed.) Another to convert phi into angles in degrees and radians (the “golden angle”), and finally I took these and made an emitter. Hooray, it indeed did allow me to emit a sphere of particles packed efficiently, and even better since I didn’t have to use a “generate sample set” it allows millions of particles to be emitted much faster than simply emitting particles from spherical geometry, and without any resolution-dependance on the LOD of a polygonal sphere. And this “phi” distribution has a nice, natural look.
Here are the compounds, enjoy: ICE_phiDistribution
Here’s a quick example of a number of handy tricks in ICE.
A compound I shared earlier on the softimage mailing list is used to create a grid of particles on a camera plane at a definable resolution, as if each particle was a pixel. The basic camera attributes like FOV etc are respected. This bit uses a little simple trig to identify the corners of the camera frustum at any distance from the camera, which can be incredibly useful. I’ll try to make some time to go over this in a future post.
A simple raycast is then used to project particles onto geometry and to color those particles based on the depth of the projection.
A lot can be done with the (super) simple techniques in this scene, trust me. Perhaps the simplest and yet most useful is to cull particles outside the camera frustum prior to writing a cache – if you are dealing with a shot that has a locked down camera this can be used to reduce cache data by massive amounts. If you are dealing with a stereo production and have access to depth maps, you can use that information to cull particles which are “behind” footage elements, or even have particles react to the “surface” of footage elements. Very cool! Knowing where a particle or object is in camera “screen-space” is easy and has a lot of use, too.
File: Softimage 2013, ~2.5MB example_cameraDataInICE
On a gig with the very cool people at Psyop, one of my all time favorite studios. So no posts for a bit. Stand by for more useful stuff in a few weeks. – AM
The simulation is “meh”, but it was a test. This scene wasn’t originally about particle clumping, either: that was just put in as a way for me to play with the idea but not really my original focus. I was using it as a testbed for a homebrew collision/bounce node, which functions, but in the end that part wasn’t anything particularly special or even sophisticated. The clumping part is more interesting in the long run.
Someone recently asked about clumping particles online, and I recalled that I had this scene on hand. So here it is, as built by yours truly while never intending it to be anything other than personal experimentation… with some comments put in after the fact.
The file (softimage2013 ~8mb): example_createParticleClusters
A discussion about Mudbox and Zbrush-style shading arose on the Softimage mailing list. Their signature look comes from “MatCap” shaders (originally known as lit-spheres.) It’s a popular way to achieve a custom lighting solution from a texture, in realtime, which is particularly useful when modeling – you can get a nice clay or sculpy “look” to geometry in realtime. It’s also useful for creating nonphotorealistic (NPR) looks in realtime, toon shading etc.
As mentioned in an earlier post, the grey-ball shader in mental ray can render litsphere textures, and a user suggested that in the high quality viewport you can get the desired result by plugging the metaSL node “Map_ball” into the environment channel. The problem with this is the result (on my machine, at least) appears in world space. A proper litsphere should be in view space.
But it called my attention to something important – almost all of the metaSL nodes used in Mental Mill are now accessible in the render tree and can be used similarly – meaning for most intents and purposes all softimage users now have Mental Mill. Which is awesome.
But we still needed a solution for matcap functionality in the high quality viewport. So I bit the bullet and wrote a metaSL shader which seems to do the trick. It can be used for both realtime performance in the high quality viewport as well as full renders in mental ray (and any other platform supporting metaSL.)
Update: Daniel Brassard kindly fixed some bugs, the new version is now available below. Thanks Daniel!
Here’s the shader (MetaSL ~2kb): litsphere_v1_1
More examples of the shader:
I finally got around to enabling metrics on this site, and have a first month of data. ~2500 visits, wow. I’m glad people are visiting and finding the site useful. Visitors to the site hail from all over the world, with only about 50% from the States. The second most common nation of origin is Japan. 訪問をありがとうございました!
The closest visitors to my home in Orlando (yes, I spend a lot of time flying to LA and NYC lol) hail from Davenport, FL, with 88 visits this month. Thats a lot for such a small town, is there a school or studio there?
Thanks for dropping in, all of you.
This scene shows how ICE can be used to display custom information about aspects of a scene. In this case, the cone of a spotlight is displayed, with an option to display a projection of the spotlight on the surface of geometry. A second example shows how the same setup can be used for a near and far attenuation display.
One great thing about ICE is how easy it is to re-use and re-task your “code.” In this example, it is simple to save the null containing the ICE operator as a model. Any time you need this display, import the model and give it your spotlight’s name, and you’re done. Or better, write a script which does this for you so all you have to do is pick the light. – AM
Here’s the file (softimage 2013, 276kb): ICEspotlightDisplay
Petr Zloty sent me a useful tip… when you place the ICE operator on an empty pointcloud rather than a null, the results display properly in any viewport. This is an important realization which is really good to know. In fact, the problem with ICE display attributes on nulls only appearing with wireframes is an annoyance which I’ve bumped against more than once. Thanks Petr!
Rob Chapman posted a cool whirlpool deformer to the “Resource Dump” on SI-Community here. Since I had been doing a lot with logarithmic spirals recently I decided to make one from scratch and compare the two. Here’s the result.
Instead of using Rob’s wave deformer, since it’s fun to share it out there’s a “ridged turbulence” compound in there. Here’s what it looks like when used as a deformer:
And here’s the file (softimage 2013 ~160kb): alt_whirlpool
The most common email I get from people who have visited this blog is inquiries about the dark color of the background in the screenshots. No it’s not a custom UI, I just have a custom menu with a bunch of stuff including two ridiculously simple scripts… one which cycles the background color in all viewports and one which sets them to this dark grey.
I chose this color for a couple of reasons.
- With a darker color, particles are much more visible, meaning I can display them as single pixels.
- The color is dark but just light enough to easily see black wireframes.
- Have you ever opened Softimage in a dark room full of people using Maya and Nuke? It’s like switching on a searchlight. The light grey color scheme of the Softimage UI is waaaay to bright.
These two little scripts go a long way towards my personal enjoyment of the software. I won’t bother to display them in the post (wordpress kills the formatting), but here’s a file for each…
Since we’re on the topic… Softimage needs a new UI. It’s elegant and functional in many ways, but dated. The light grey is glaring, the huge arrow button looks absurd to new artists, (they’re right) and I have a strong suspicion that it’s a major factor which keeps new artists from Softimage. Just my $0.02.