Cutter Setup
RenderMan Shader Writing


main index



Introduction

Editing rib and rsl files with Cutter offers many advantages compared to using a general purpose text editor. Cutter applies syntax coloration to both types of scripts. Rendering a rib file and compiling a shading language document is conveniently accomplished using the keyboard shortcuts Alt + e, Control + e or Apple + e. If the URL to Pixar's documentation has been set in preferences then Command + double clicking on a keyword in a rib or rsl file will trigger Cutter to display the relevant Pixar documentation.

For use with RenderMan for Maya Cutter can:
- automatically write a slim appearance file for each shader it compiles,
- convert shading language source code into a Pixar Slim node,
- convert an RSL function to a HyperShade node.


It is assumed the reader has installed Pixar's RenderManProServer and has followed the "Cutter setup" and "RenderManProServer setup" instructions. By default, Cutter writes a slim file for each shader it compiles. As shown below (emit slim doc) auto-generation of slim files can be turned off. Slim files are only relevent if you intend to use your shaders with Pixar's RenderMan for Maya.



Figure 1


If your shaders will be used with Side Effects Houdini, "Output to Houdini OTL" should be activated and a path should be set to a shared OTL file.
    Edit->Show Preferences->Rman->User->Output to Houdini OTL
If the path is left empty Cutter will create a OTL file for each shader it compiles. Initially, Cutter will indicate the file does not exist ie.



Figure 2
Activating OTL output.


Ignore the warning. The path will change from red to black once the OTL is created.


Cutter's Shader Development Work Flow

The process of developing and testing a shader consists of repeatedly cycling through the following five steps.

1

Open a copy of a "constant_test" shader ie.
    Rman Tool->Docs->Traditional Shaders->Surface - Constant

2

Save the file as "contant_test.sl" in your "shader_src" directory

3

Compile the shader - keyboard shortcut Alt+e, Control+e or Apple+e.

Cutter will ensure the compiler will save the shader to the users "shaders" directory.

4

Open a rib file to test the shader ie.
    Rman Tools->Docs->Beauty Pass->Reyes Classic Shading
Cutter will generated a rib file that references the compiled shader and its default parameter values.

5

Save the rib file and render it - keyboard shortcut Alt+e, Control+e or Apple+e.


Cutter's Keyframing Facility

It is often very useful to animate the parameters of a shader in order to see how surface opacity, color and displacements interact. Importing a shader into Maya or Houdini is a time consuming process although, of course, such applications enable an artist to fully assess a shader. Cutter offers a simple keyframing facility that enables animations to be directly and quickly created. For information about this topic refer to the tutorial "Cutter: Key Framing".


Cutter's Open Shader Source Facility



Figure 3


If the ALT or CONTROL key is pressed when a shader is chosen (figure 3), Cutter will find the corresponding .sl file and display a copy of it's code - figure 4.



Figure 4


Cutter's Open Doc Facility

To open Pixar's documentation CONTROL + double click on the name of a datatype or RSL function. On MacOSX the keyboard shortcut is APPLE + double click. The Rman Tool provides quick links to selected RenderMan topics - figure 5.



Figure 5


The Help menu also provides a quick link to Pixar's documentation.



Figure 6



© 2002- Malcolm Kesson. All rights reserved.