COMPUTER AIDED ARCHITECTURAL DESIGN
Workshop 12 Notes, Week of  November 10, 2014

LIGHTING AND MATERIALS

Part II and III of this workshop is developed after techniques described in Maya 8 for WIndows & Macintosh (Visual QuickStart Guide) by Morgan Robinson, and Nathaniel Stein, Peachpit Press, 2007 ± § - see on-line version of this textbook. it contains examples that are reinforced by background concepts in Chapters Chapter 14 + Chapter 15 (part), pages 349 402, which can be read online when on ground or connected through UVA Anywhere.

The Robinson text is an especially well written introductory text in comparison perhaps with some more recent tutorial books. For additional online resources for later releases of Maya, see the references at the end of the syllabus for Arch 5420: Digital Animation and Storytelling.

PART I: LIGHTING

  1.  SIMPLE THREE POINT LIGHTING

 

Lighting types commonly used are 1) Ambient, 2) Distant/Directional, 3) Point and 4) Spot Light which appear from left to right in the Rendering Shelf tab in Maya. Ambient light provides general background illumination. A Distant/Directional light provides parallel light rays from a specific angular orientation, and may be used to mimic such distant lights as sunlight or moonlight. A point light is an omni-directional light that sends light out in all directions from a single location. A directional light sends light in a specific direction at a specific angle from a source location to a target location. 

 

Key and Fill Lighting: A typical three point lighting setup has a Spot light (also known as a Key light) to the upper right of model at full intensity to provide high contrast shadows, a Point light (also known as a fill light) to the upper left of the model at lower intensity filling in middle gray values, and a back spot light (also known as a back key light) at lower intensity than the front spot light and that provides some three-dimensional depth to the rendering.   

Open Maya, go the Polygon shelf tool, and create a simple box, sphere and cone and place them on top of a polygon plane similar to what we've explored in Rhino previously.

Add spot light.

spot light

With the spotlight selected, to the top of the screen menu item "Modify/Transformation Tools/Show Manipulator Tool" to get control of both the source of the spotlight and the target. Move the source of the spot light above and to the right of the polygons, and move the target of the spot light to an area just below the sphere. With the spot light selected, open the attributes editor (third icon from upper right-hand corner of Maya window) and resize the light's "cone angle" until it encompasses all the polygons within the view. Within the attributes editor for the spot-light, turn on ray-trace shadows for the spot light.

spot light added

Go into lighting mode by hitting #7 key

lighting mode

 

2. Now add a point source light to the upper-left area and a spot light to the upper right area of the model space for fill (point light)) and back light (spot light). Optionally turn off the shadows for these two lights. The shadows for the earlier spot light is probably sufficient to lend clarity to the rendering. Use the show manipulator tool again to reposition the new lights (target and source).

light icons

add point and spot light to model

3. Next, return to the "Rendering" shelf tool, and open the render settings dialog box (highlighted in green below).

render settings dialog

Under the Maya Software tab, and in the quality tab, select the preset "Production Quality" and then go to the "Raytracing" tab and select to on the check-box.

render settings setup

4. Rendering the image produces the following kind of result with all lights casting shadows.

 

rendering

Rendering the image produces the following kind of result with only the first spot light (also sometimes called the key light), casting shadows.

rendering 2


 

PART II: MATERIALS

1. Shaders in Maya are based upon standard rendering algorithms and include the following types:  

These types of shaders are acessible through the hypershade dialog box or Window/Rendering Editors/Hypershade

 

2. Materials Some Definition of Textures and Methods

Materials reference attribute nodes that determine look of an object. This includes

Texture – an material  that is mapped to object
      Types:  procedural (based on an algorithm) and
                    image (based on a photograph).

Bump Map – image read for its gray scale value that makes a material have the appearance of a surface relief

3. Menu items in Hypershade window (Left to Right)

Toggle bar – hide or show Create bar leaving more or less work area
Show top and bottom tabs - shows materials/textures as well as work area.
Show bottom tab - shows work area
Show top tab - shows materials/textures
Show previous graph (in work area)
Show next graph (in work area)
Clear Graph bar – clears out any nodes in work area
Rearrange graph bar – cleans up work area
Graph materials on select objects – finds material assigned to object
Show input connections
Show input and output connections
Show output connections

4. Basic material properties:

Color – RGB or HSV selection model color
Transparency – degree to which material is transparent
Ambient Color – brightness or darkness of whole material
Incandescence – create appearance of giving light
Bump mapping – makes a surface appear bumpy

5. Example of use of simple material definition and assignment

Go to materials editor by invoking the menu sequence select Windows >Rendering Editors > Hypershade.

  1. Click Lambert (cosine shaded object)
  2. Double click the new material to invoke attribute editor 
  3. Select field next to color on right-hand side of screen.
  4. Choose color from rgb or hsv model/accept




  5. Select the surface and select the material with right mouse button, and then select “Assign Material to Selection”


6. Texture mapping nurbs surface

Prepare or obtain an image file of some material such as brick.jpg file. Make a lamber shader. In the color selection area on the right-hand side of  the the screen, select the checkered symbol and follow the dialog box to load the brick.jpg file.

Once the image map has been loaded into the definition of the material, it is included in the symbolic graph of the material (left-hand side of image below). Double-clicking on the Place2D texture tool in order to activate interactive placement options.


Adjust the 2d Texture Placement Attributes. Note:

  1. U is the horizontal & V is the vertical coordinate parameters of the surface from lower left corner to upper right
  2. It's possible to map TIF, JPG and IFF(Maya's proprietary format) texture mapes
  3. Initiate the process by creating a Lambert material
  4. In Hypershade panel double-click on the" Lambert" icon.
  5. In the attributes editor for the material, elect the checkered box adjacent to the color and add the brick texture file.
  6. Select an object in Maya, and right click on lambert material to assign it to the object
  7. Double click on pace2dTexture node:
    1. See red square on object: middle mouse button - drag center to move, drag corners to rotate.
    2. Repeat UV … to repeat pattern (do 4 in each of U and V)

7. Projection Map

  1. Create NURBS plane.
  2. Create a lambert material in Hypershade and apply to plane.
  3. Double-click on the lambert material in Hypershade
  4. In attribute editor, click on map next to color slider.
  5. Click on radio button to projector.
  6. Click the file button (select a file).
  7. Click file1 tab at top of attribute editor.
  8. Click on folder icon next to Image Name
  9. Open your own image.
  10. Goto perspective view and select key #6 to render.
  11. Select the place3d texture utility in the perspective view.
  12. Rotate plane -90 so that image projects onto NURBS plane.
  13. With the place 3d texture tool selected press ctrl/ctrl – a to open attribute editor.
  14. Click the “fit to box” button.
  15. Experiment with scale and move options.

[If surface appears to be moving through texture, then in Rendering mode, select the surface, and then from the Texturing menu select “Create Texture Reference Object”]

8. To Improve Quality of Rendering

  1. Select object.
  2. In hypershade panel, choose Graph Materials on Selected Objects Icon.
  3. Double-click on the material in Hypershade.
  4. In Attribute editor, under Hardware Texturing, click arrow to expand options.
  5. Change “Texture Quality” setting to High. {only do for temporary viewing, slows Maya down]

9. 3D Paint Tool

  1. Create Lambert material and assign it to a new NURBS sphere.
  2. Select the sphere.
  3. From Texturing Menu, select box next to 3D Paint Tool.
  4. Scroll down until you see File Textures.
  5. Click the Assign Textures button, determine resolution, and click Assign Textures {note project setup must include texture area
  6. In perspective view, hold “b” key and move mouse left & right to size brush.
  7. Click and drag on surface to paint.
  8. Select swatch next to floor color and choose yellow at top of Color Choose.
  9. Click “Flood Paint”
  10. Change paint color and paint smiley face on surface.
  11. Click on the change brush button, scroll down Visor and select hair folder.
  12. Choose hair type and paint on to sphere.
  13. Clear surface with flood button.
  14. Select brush adjacent to Artisan to return to normal brush.
  15. Decrease capacity of brush to see color beneath
  16. Can edit image in Photoshop directly from directory.
  17. [techniques can also be used for Attributes and Transparency, pull-down menu under file textures.

PART III: ADDITIONAL MATERIAL AND MAPPING TECHNIQUES

10. Bump Map

  1. Create NURBS plane.
  2. Hypershade create Lambert and assign to plane via MMB.
  3. Double-click on Lambert sphere.
  4. Click map button next to bump mapping and select bulge.
  5. From Create Menu/Select Lights/Directional light.
  6. Use Show Manipulator Tool to rotate light onto plane.
  7. Select render icon (upper right hand side of screen) to see bump map..
  8. To change bump depth/chose graph materials on selected objects icon in hypershade panel and select lambert object.
  9. Select bump2d node, increase bump depth , & render (render icon)

 

11. Ramp texture (eyeball)

  1. Create Phone E shader
  2. Double click on the icon (gets attributes window), and then click checkerboard icon on the color.
  3. Select ramp shader.
  4. Change top shader to black by lowering color solider to left.
  5. Move middle shader (default color is green) closer to top
  6. Click on ramp 1/5th way to bottom, place new position indicator just below 2nd one (above).
  7. Click and drag bottom indicator just below new one (3rd one).
  8. Click on color swatch for above indicator and select white.
  9. Change shader type to U Ramp and assign to sphere

12. Layered Shader

  1. Create two blinn shaders red and blue.
  2. In blue shade, double clock on icon, and then on transparency color select fractal.
  3. Create layered shader
  4. Double click on layered shader material.
  5. Drag blue and red materials from the Hypershade into the red square under Layered Shader Attributes. (note blue shader comes before red shader)
  6. Click X under original green shader to remove it.
  7. On blue blinn shader, use fractal to define transparency
  8. Apply shade a square
  9. In Render view, click on the Redo Previous Render Icon. Red can be seen through the blue due to fractal transparency.