Here’s another update on the ‘exhaust wall’ part of the ‘derezzing’ sequence. As I was getting the exhaust wall network up to a level I was satisfied with, I figured, why not make it a tool and apply it to the red bike easily. That seemed like a jolly good idea, so I quickly got to work.
First, however, let me show the results coming out of a test render of my new tool (8 times, slow motion). Note that this render focusses completely on the exhaust walls. The background is still a placeholder, so is the grid (too low res texture), and the red cycle animation definitely needs quite some animation love, especially when it hits the ground. It’s also the ‘raw’ render output, with only sRGB applied. But…. with all those disclaimers:
View in high resolution: ExhaustWallTestHDA_V01.
Luckily, Houdini is literally made for that kind of stuff so progress was fairly swift. I started by isolating all the ‘turbulence’ displacement logic (as I mentioned here), which by now included the horizontal displacement (now called ‘side turbulence’) as well as the vertical displacement (now called ‘edge turbulence’) as shown here. Anyway, the VEX code for the turbulence became a separate HDA. I did end up changing some of it for differences in how the logic that calculates the ‘up vector’ for the vertical displacement (which I’ve now dubbed: ‘Edge Turbulence’) behaved in displacement shader. This didn’t really translate nicely, so I added this to the wall geometry generation as a separate piece of logic that just adds the up vector as an attribute to the geometry. This attribute gets used in the turbulence displacement tool.
In the process, I added a new piece of logic that adds ‘stickyness’ of the wall to nearby ground surfaces. This takes care of gaps between the wall and the ground when the bike moves up and down a bit when rolling sideways in turns. In order to not make this effect to sudden, it has a parameter that specifies from what height the wall is allowed to let go of the ground surface and a second parameter that specifies the height from which the wall is fully detached. Between these two boundaries there is a nice smooth transition. The actual distance is calculated with a ‘ray’ sop. All this ended up as another element in the turbulence displacement tool.
Next thing was to make a tool out of the exhaust wall shader and to update it with reflections, refractions, the turbulence tool and the proper render passes. The refraction part of this shader is next to the turbulence part, the most interesting element in the shader. Again, based on what I think I see in Tron Legacy, and on what I think is cool, I decided to have some fun here. My thinking (and presumably the thinking at Digital Domain) is that the top and bottom of the exhaust walls have the higher energy (hence the brightest light), so it kind of feels right if you also get most optical distortion there. So, I ended up using another ‘ramp parameter’ to control the value of the Index of Refraction as it changes from top to bottom. The default setting in the shader has it very high at the top and bottom of the wall and much lower towards the center of the wall. This creates some really nice optical effects especially with highlights at the top of the wall. Lastly, I used the ‘time’ parameter to add high brightness to the leading edge of the wall as it comes out of the cycle, which then quickly drops off, again controlled by another ramp parameter. I actually did one more thing to further ‘toolify’ the shader. To make it easier to quickly setup another exhaust wall with only a different color I separated the brightness (ramp parameter) from the color of the wall. This means I could setup the red cycle’s wall shader by just changing the color and reuse all the other settings.
With these two components out of the way, it was time to make a tool out of the actual geometry generation. I split this up into a ‘base geometry’ tool that contains the particle network and the skinning as described here and a set of ‘preview’ nodes that adds the preview of the turbulence and color of the wall in the view port. I also added some caching logic that allows to quickly cache out the ‘base geometry’ to disc. This takes care of the particle generation stuff and allows for free timeline scrubbing though the animation. With a cached out ‘base geo’ the ‘preview’ logic makes it very interactive to setup the turbulence and color. Renders will only ever see the ‘base geo’ and apply the turbulence at render time at high res. As the turbulence is based of the same displacement tool you can be sure that the ‘preview’ in the view port is fairly accurate as long as you keep the resolution (a separate parameter) high enough for it.
The last thing left was to package this all up into an ‘object’ level tool, which combines all the elements and their user interfaces into a single logical unit. The end result of all this is a tool that makes it extremely simple to add exhaust walls like the ones you can see in the render above from any animation of any vehicle or otherwise. The workflow of this tool is as follows:
- animate something
- add a number of points that specify where the exhaust wall should come from
- add the ‘DEF_ExhaustWallObject’ to your project
- point the tool to the points (from step 2), the animated object (for velocity transfer of leading edge) and the ground it needs to stick to
- click on the cache button
- tweak color, brightness, turbulence, etc to taste (or use the defaults and just select a color)
- hit render
I tested this workflow on the red cycles wall and was pleased as punch that it actually was this simple :), I did notice from the render that the red wall isn’t yet properly sticking to the ground at the end of this render, so I probably have to tweak the ‘stickyness’ settings a bit.
One last thing I want to cram into this post is that I’ve been able to ‘enlist’ the help of my friend Linus Hofmann to do the final compositing on the animation sequence and add an arena to the environment as well. This should speed up this ‘little’ project quite a bit, so I can focus on the 3d fx part of it.
The render above is based on the first frames that finished rendering to get him started on combining my output into a final comp. I got a very quick first comp from him with which I’d like to conclude this post.