Using VEX Shaders in Houdini - Creating an Underwater Scene

Page 8

 

 

 

 

Add an up light to simulate highlights on the water

1. Return to the object level and add a light object and call it water_spot.

2. Under the Transform tab set the following:

tx=0
ty=-3
tz=-12
rx=90
ry=0
rz=0



3. Select the Light tab in the parameters window and set:

Dimmer = 2
Click the Cone Light check box on.
Cone Angle = 160
Cone Delta = 30
Cone Rolloff = 1
Attenuation = 4

4. Render a test image.

*This light also illuminates the ground plane from underneath, giving it a glow since a default added light does not generate shadows. If a light generates shadows, then light stops at surfaces it hits, otherwise light will illuminate all surfaces in it's view.

The scene is almost complete. You have installed and applied three new shaders, a surface shader (VEX JW Gloop Color), a displacement shader (VEX JW Gloop), and a light shader (VEX JW Caustic Light). You have also applied one of the Houdini default VEX shaders (VEX Choppy Water).

Adding the fog

So far you have created all the elements in the scene and applied shaders to the ground_plane, water_surface, and light_caustic.

One last element and shader will be added to tie things together. This is the atmosphere or fog that will simulate actual water between the ground_plane and water_surface.

For the fog you will again use a Houdini default VEX shader.



1. Open underwater.hip and go to the SHOPs network editor.

2. Add a "VEX Uniform Fog" SHOP. (one of Houdini's default SHOPs)

3. Set the following:

Fog Color r=0 b=0.17 g=0.33
Fog Density = 0.16

4. Change the Network editor from SHOPS to Objects.

5. Add a fog object.

6. Select the Shading tab.

7. Click the SHOP Shader flyout arrow and select v_uniform1.

8. Render a test image.

PAGE 8

Go to Page 1 2 3 4 5 6 7 9


Post a message in the Digital Post Production World Wide User Group!