Part 1: Creating Shaders
 
 
 

In this section, you will use Hardware Shade to render a scene, and create shaders for the caps, bottles and labels.

Watch Part 1 of the tutorial.

Opening the tutorial file

  1. Choose File > Open to open the File Browser.
  2. In the File Browser, locate the CourseWare directory and set it as the Current Project.
  3. Open the file called Render_Basics.wire, located in the wire directory in the CourseWare project.

For information on how to open a file, see Opening the tutorial file.

A dialog box appears, asking if you want to delete all objects, shaders, views, and actions. Click Yes.

If your values for construction tolerances differ from those in the Render_Basics.wire file, you are presented with a dialog:

Click Accept New Settings to use the construction tolerances in Render_Basics.wire.

The file is opened. The scene has two shower gel bottles in different positions, one with the cap open, and one with it closed.

Viewing a Shaded Scene

When setting up a model to be rendered, it is useful to work interactively with a rendered view. For this exercise, you will use Hardware Shade to work directly on a shaded scene.

  1. Maximize the Perspective view.

  2. Choose WindowDisplay > Hardware Shade to open the Hardware Shade Options.

  3. Choose All Geometry from the option window and click Shade on at the bottom of the option window.

    The bottles are now visualized using the Hardware Shading.

Choosing a Shading Model

The bottles are using the Default shader, which has the Blinn shading model. There are four types of shading model in Alias:

As you gain more experience with shaders, you will understand which Shading Models will produce the results you want.

Next, you will create three new shaders one for the bottle, cap, and label. After that, you will choose the right shading model for each one.

Using the Visualize Control Panel

For this part of the tutorial, you will use the Visualize Control Panel to create and modify shaders.

TipIf the Control Panel is not currently shown, choose Windows > Control Panel to turn it on.
  1. At the top of the Control Panel, choose the Visualize option.

    The Default Shader is shown in the Resident Shaders section.

    If the name of the Default Shader is not shown underneath the grey shader ball, you can turn on the icon labels in the General Preferences.

  2. Choose Preferences > General Preferences to open the preferences window.

  3. The Interface section is opened. Check the Icon labels box to turn on the icon text.

    The Resident Shaders section in the Visualize Panel now shows the name of the Default shader underneath the shader ball icon.

    It is good practice to not use or modify the default shader, as you will copy it to create new shaders.

    So first, you will create a shader for the bottle.

Creating a Bottle Shader

  1. Click the Default shader to select it.

    Below the resident Shaders section, there are four icons. Click the Copy Current Shader icon to create a shader.

  2. Double-click the new shader icon to open the shader editor.

    The default settings are shown.

  3. Change the Shader Name to Bottle, and leave the Shading Model set to BLINN. This will give a soft highlight for the bottle plastic.

    Now, you will choose a color for the bottle.

  4. In the shader editor, open the Common Shader Parameters section.

    Click the grey color chip to open the Color Editor.

  5. In the Color Editor, choose a color for the bottle.

    The color chip updates, and the Bottle shader shows the new color.

    Now, you will Assign the new shader to the bottle surfaces.

  6. Select the bottle surfaces by using the Pick Objects option on the Bottles layer sub-menu.

    All the bottle surfaces are selected.

  7. Click the Assign icon on the Visualize Panel to assign the new shader to the bottle surfaces.

    The bottle surfaces are now shown in the new shader color.

    Now, you will repeat this process for the cap shader.

  8. Click the default shader to select it. Then, choose the Copy Current Shader tool to create a second new shader.

  9. Double-click the icon of the second new shader to open the shader editor.

    Change the Shader Name to Cap and the Shading Model to PHONG.

    In the Common Shader Parameters section, choose a color for the cap.

    Now, you will assign the shader to the cap surfaces.

  10. Pick the cap surfaces using the Cap layer sub-menu.
  11. Assign the Cap shader to the cap surfaces using the Assign icon in the Visualize Panel.

    A small bright highlight appears on the caps illustrating a glossy plastic material.

  12. Close the shader editor window.
  13. Choose Pick > Nothing to de-select the label surfaces.

Modifying Shaders in the Visualize Panel

The most common parameters for a shader can be accessed in the Visualize Panel.

Now, you will give the cap a more shiny appearance, and the bottle a softer finish.

  1. Click the Cap shader to select it and open the Shader Parameters section of the Visualize Panel.

  2. Modify the Shinyness value to make the highlight on the cap smaller.

    The cap material should look more shiny.

    TipYou can use Render > Direct Render to see the changes more accurately.
  3. Click the Bottle shader to select it.
  4. In the Shader parameters section, modify the Eccentricity and Spec. Rolloff values to make the bottle plastic look less shiny, with a softer surface finish.

    The two images below show the changes you will see in the materials.

    TipOnly the most commonly used parameters are shown in the Visualize Panel. To access all the parameters for each shader, either double-click the shader ball icon, or use Render > Multi-lister> Shaders.

Saving your work

Now, you will save the scene as a new file.

  1. Choose File > Save As to open the File Browser.
  2. Save your work in the wire directory of the Lessons project.
  3. Name your file myRender_Basics1.wire.