COMPUTER AIDED ARCHITECTURAL DESIGN
Workshop 6 Notes, Week of  Sepember 28,  2015 (Preview week of September 21)

INTRODUCTION TO LIGHTING AND RENDERING

These notes will introduce basic lighting and  rendering through Rhino Render and continue on to more advanced options using the Rhino plugin for V-Ray. Additional notes are provided on the plug-in for Maxwell for comparative purposes only. They are for optional reading only and the techniques are not required for the class.

PART 1. LIGHTING

1. Create a Rhino Model with a ground plane surface and three solids as follows:

simple solids

2. Open the lighting icon from upper right-hand side of screen.

3. Place a spot light in the model from the front view, entering the target and radius first, and then the light location second.

place spot light part 1

 

4. Select the light and turn the control points to on.

5. From the top view, move the lighting source position to the +x, -y position relative to the ground plane.

adjust light source position

5. Activate the perspective window, select the rendering icon, and render the view.

one light rendering

6. Following a similar procedure, create a back spot light pointing towards the center of the model and create a rendering.

two lights rendering

7. Select the properties icon for the back light and reduce the shadow intensity to 0 and light intensity to 50.

8. To change the background of the rendering, go the the File/Properties menu, select Rhino Render, select Background "Solid Color" and select the color swatch and change it to black. Also, note in the last rendering that there are stair step like lines on geometry running diagonally across screen (they are jagged), such as on the cone and the box. To compensate for this problem, which is called "aliasing", change "Antialiasing" to High(10x) in the same dialog window:

change background color

Render the perspective window again and note that the second light is no longer casting a shadow and also that now that there is a black background.

key and back lighting

9. Add a point light to the upper left hand corner of the model. Here it is only necessary to position the light source. That is, the point light is an omnidirectional light and doesn't have a target or cone profile. Begin in the front view and continue to place the light in the top view similar to setting the light source locaation for the spot lights.

place point light

10. Using the properties icon, adjust the shadow intensity of the point light to 0 and change the light intensity to 50 (i.e., 50%).

change light intensity

11. Render the perspective again for a rough simulation of three point lighting.

redner 3 pt light

 

PART 2. RENDERING

 

1. You can continue to adjust the antialiasing level by rendering the same model within a more advanced rendeing tool as we will see in a later workshop tutorial.

2. Using the same properties icon as before, set the material colors of the box, cylinder and cone to red, blue and green, and also make the cone transparent. Note that the "Material" pull-down tab is active, that the "basic" assign by method is selected, and that for the cone, the transparency value is set to 0.75. Do not select the "Transparency Check Box" which refers to a separate material property.

set cone to color green

5. Rendering the view to 640 by 480 pixel resolution results in the following jpg file.

6. Download the image of penguins below by right clicking on it and saving it to your local working folder.

 

7. Now select the ground rectangle, open up the properties dialog, select the "material" (tube) icon, select the check-box for "Bump" and also "empty - click to assin" link highlighted in blue in the image below. Load the file above through the map file interface.

 

penguin bump map loading

Render the result.

render bump map for penguin

 

 

8. Within the same dialog box, go to the texture mapping, which looks like a half roled sheet of paper, and select the planar texture mapping icon.

plannar mapping icon

Trace the surface in the ground by a rectangle from the lower-left-hand corner to the upper-right-hand corner.

trace planar projection

Now, continuing in the texture mapping dialog box, adust the "UVW repeat" parameters to 2.0, 2.0, and 1.0.

planar map parameters

Re-render the image and note that the bump map is repeated twice along each axis.

bump map doubled

PART 3: LIGHTING AND RENDERING WITH V-Ray

Part 3 is an introduction to rendering techniques with V Ray. We will introduce basic rendering methods through V Ray for this first tutorial and then return with more advanced treatments of materials and lighting in the workshops to follow. 

For a complete  documentation of the V-Ray plugin to Rhino see the V-Ray For Rhino Plugin Manual

1.  To change rendering engines from Rhino Render, go to Menu item  Render> Current Render>V-Ray For Rhino

2. Using the same techniques as described above, create a file with a ground plane with  three objects, a box, a sphere, and a cone. 

3 objects for v-ray

3.  Create a key light, back light and fill light without determining intensities and other properties.

three lights for v-ray

4.  Select the spot light in the front right-hand area of the 3D model, and in the properties dialog box, select the "spotlight" icon. Use the default settings, and note specifically that the color is white,   intensity is set to 30.0 scalar units (a relative measurement of intensity rather than specific energy units), and that the shadows check-box is on. 

key light properties

3. Select the spot light in the rear back right-hand side (i.e., the back light). Set the intensity to "15" and uncheck the shadows checkbox.

back light

4. Now select the point light, and also set the intensity to "15" and the shadows to off.

point light settings

5. Open the menu  item "V-Ray/Options" and select the "Camera" tab, switch on "Physical camera", and set the F-number (F-stop number) to 3. The F-number is a number determined by the aperature opening of the simulated camera. A lower number corresponds to a wider aperature opening that increases the exposure to light.  A high F-number corresponds to a smaller aperature opening  and the lowers the exposure to light.  (Note that the actual calculation of the F-number is based upon a the ratio of the focal length to the diameter. That is, F-number = focal_length/diameter. Thus,  the greater the diameter of the opening the lower the F- number. )

V Ray Camera Initiation

6. Select the "Perspective" window, choose a desirable view orientation,  and then select the Render Icon (the blue sphere) and render the perspective view.

render icon and perspective view

If the rendering is too dark, return to the camera editor, and try lowering the shutter speed or f-stop number. Note that a slower shutter speed means that the shutter remains open and thus admits more light. Conversely, increasing the shutter speed will decrease the amount of light entering the camera.

Alternatively, as described previously, lowering the F-number value of the camera means that the camera aperature is larger and that the camera will admit more light. Conversely, a higher F-number correspondends with a smaller aperature and will decrease the amount of light entering the camera. However, lowering the F-number may be used to increase the depth of field, a measure of how much within the view lies in focus. This is a technique that will be discussed in a later workshop.

7. For another approach, within the V-Ray Buffer Window, turn on the icons in the lower left-hand corner for "show color corrections control",  "color corrections level", and  "use exposure correction" (see icons highlighted by arrows in lower left hand corner of image below).

V-Ray Buffer Window

8. The "show color corrections" icon will open the "Color corrections" window. Within the window adjust the left and right "gradiant" slider (the values at the ends of the green arrow of -0.59 and 7.4 in the image below) to produce a desired contrast and brightness level.

color corrections window

9. Within Rhino, select in turn each of the lights in the 3D model, and turn off the "enabled" check-box in order to turn off the light.

10. Go to Render Tab, and toggle the standard Rhino  "sun" symbol to turn on the Sun control panel.

sun toggle

Within the Sun control panel, set the Sun to "On", and determine the time and day of the year, as well as set the location either by picking a city (e.g., Richmond, VA) or entering the exact latitude and  longitude.

sun control panel

Render to see the impact of the direct sunlight. If necessary, adjust either camera settings and/or the color control curves to arrive at a good light level and contrast. Note that the standard Rhino Sun is tinted to reflect the color temperature of natural daylight.

sun render

6. Go back to the V-Ray Option editor and open the "Output" tab.

Turn on the check-box for  "Override viewport", change the resolution to 1280 x 960 and test render.  

Render again, and within the V-Ray frame buffer, select the floppy-disk "Save image" icon highlighted below, and save the image to the jpg format.

save image sequence

7. To create materials, go to the menu V-Ray/Material Editor

mat editor

Within the Material Editor Dialog Box, right mouse-button click on "Scene Materials" and select "Create Material > Standard"

Next, right mouse-button click the text "DefaultMaterial", and rename the material to "glass1"

rename material

Right mouse-button click on "glass1" and create three layers, one each for "Reflection, Diffuse and Refraction"

Select the "Glass" material and select the "Preview" button to see it. Next, go to the "Diffuse" layer tab, and change the "Transparency" color to Gray.

change diffuse color

Test the change to the transparency color by again selecting the "Preview" button.

preview transparent glass

Next, go to the "Refraction" layer tab, change the IOR (Index of Refraction to 2.00), and then once again select the preview Button to see the resulting greater level of refraction.

change IORf

Select the sphere, right mouse-button click on the "glass1" material, and choose the option to "Apply Material to Selection".

apply glass to sphere

Return to the "Output" tab of the V-Ray option editor, lower the resolution to 640 x 480, and do a test rendering:

sunlight model with glass added

Return to the V-Ray material editor, create a material "myCone" with a Diffuse layer only,  select the Diffuse layer tab, and change the "Color" to cyan, and assign the color to the cone.

schange color to cyan

Similarly, create a material "myBox", select the Diffuse layer tab,  change the "Color" to Brown, assign the color to the box and render the result.

render with colors added to box and cone

8.  Using the V Ray Sun

In this step, we wwitch from the Rhino Sun to a V Ray Sun. First, select the sun icon in the Rhino "Render Tools'' and using the pop-up dialog box change the check-box to turn it off.


Now, go the VRay sunlight palette. If the VRay sunlight palette doesn't already appear on the screen, Go to the File/Properties dialog box, and  select "Toolbars".  Within the resulting dialog box, look at the list of "Files" in the upper right-hand area and select "VRayForRhinoV4_tb". Next, under Toolbars in the lower right-hand area, select the check-box to turn on both  "New V-Ray for Rhino" and "V-Ray Lights", and then select the "Ok" button.

set toolbars for V-Ray

The palette will float on the screen Windows.

 [Note:  If the V-Ray light palette isn't visible, then you may need to seek out extra help to turn it on. In this case, in order to see the toolbar,  you can right mouse-button
click in a gray-shaded area that is to the right of tabs located just below the command prompt text area. In the pop-up dialog box that appears select  "Show Toolbar" and then scroll down list of options to select "V-Ray Lights". Optionally, you may also wish to drag the lights palette and anchor it to one of the toolbar margins in the screen.]

vray sun symbol

Select the sun icon in the upper left-hand corner.  Next, similar to the basic Rhino Sun, use the Sun panel to setup the sun location.

vray sun panel


 Select the "OK" button at the bottom of the sun panel, and then enter the "return" key to automatically  position the sun near the origin (see sun arrow at lower left-hand corner of plan view below):

set sun at origin

Do a test render in VRay.

vray sun test render


Now, select the sun within the plan view. Go to the object properties tab and select the light symbol. This displays the properties of the sun. For example, the intensity value of 1.0 can be raised or lowered to effect the relative brightness of the sun.

vray sun properties

8. Controlling the Sky Color

Return to the V Ray Options Panel and open the  "Environment" tab.

options editor environment tab

Select the letter "m" adjacent to reflection, and within the V-Ray texture editor, change the texture to "TexSky",  and then select the OK button.  

 create texture sky

Render the perspective view and note the sky background.

blue sky in V-Ray

Return to the  V-Ray texture editor, and under the menu item for sun, pick the sun with the long hexidecimal name (numbers and characters). Lower the" turbidity" to value to 2.0 in order to make the sky less hazy, and select the "OK button..
 
lower turbidity to 2.-0 on simulated sky

Re-render the perspective view and note the moderately deeper blue color of the sky as compared with the earlier rendering.

render deeper blue sky

9. Working with a predefined materials library.

With the V-Ray material editor, right  mouse-button click on "Scene Materials" (shown below) and select the option to "Load Material Collection" and select the folder for the "Vismat Material Collection" downloaded from the classes server and examples folder. Or, the original source materials can also be obtained free from the V-Ray web site at http://www.vray.com/free_vray_tools/vismat_material_collection/index.shtml.

material editor pre-load vismat

After loading the material library, the V-Ray material editor appears as follows:

material editor post lib. collection added

Select any three materials, apply to the ground rectangle, box and cone in Rhino, and re-render. For example, the materials "Car_paint Burgundy",  "stainless-steel"  and "White Plastic" were applied to produce the following rendering:

vismat applied

In the next rendering, the ground plane and sphere have been scaled up, and the materials "Sea Water" and " Earth" have been added.  These materials use more advanced " mapping" techniques that will be covered in a future workshop.

sea scape rendering

PART 3: LIGHTING AND RENDERING WITH MAXWELL 

Part 3 includes a short description of rendering techniques via the Maxwell Plugin. This is an alternative option to V-Ray However, we will be exploring V Ray  in greater depth.  Here is a brief introduction of Maxwell for comparative techniques and values. This is purely optional reading.

For a complete treatment of Maxwell's plugin to Rhino see the Maxwell For Rhino Plugin Manual

1.  Go to Menu item  Render> Current Render>Maxwell For Rhino

2. Go to Menu item  Maxwell/Plugin Windows>Scene Manager

3.  Go to Folder Tab

Set  Name to testMaxwell.png

Set folder to local folder on "T" drive (or on your local "C" hard drive on a private computer)

Set time to "25" and SL to "15"

Set Light Multilight to "Intensity"("Color + Intensity" is no longer an option)

Set engine to "low priority"

Set render to "difffuse + reflections"

4. Go to Environment Tab

Set type to "Physical Sky"

Select on "Physical Sun"

5.  Go to Location and Time Tab

Set location to desired  place.

Set time to 11 a.m..

6. Go to camera tab.

Change output resolution to "manual"

Enter output width as 1920 (height will change proportionately). We will modify this later.

7. Create layers for ground, box, cylinder, sphere  and lights and copy objects to each one, changing layer color as desired.

8. Go to materials tab.

Note: the tab is (still) empty. No materials are yet defined for Maxwell.

9. Go to Menu item  "Maxwell>Plugin Manager>Database"

Drag desired materials from Database manager to Scene Manager

10.  In layer manager, go to default material column.

Go to the Material Editor and choose Assign by "plug-in ", and select a Maxwell material via the "browse" option. Note that the "projects" folder on the "classes" server (\\archstore01.arch.virginia.edu) also includes a number of downloaded or student created Maxwell materials.

Repeat step for all remaining objects except the cone. For the cone, go to the Materials tab and create a new material using a wizard for glass:

Right-click in the materials window to create a new material.

Double-click on the new material.

Name the material "myGlass" - Select the "Wizards" menu and choose "glass/ hight grade".

 

 

Adjust material properties

Note Nd =  index of refraction -  a measure of the speed of light in a material

            k  = extinction of the wave - absorbtion loss (optional) 

More detail on these properties:

http://support.nextlimit.com/display/maxwelldocs/Index+of+Refraction+-+ND+and+K

http://support.nextlimit.com/display/maxwelldocs/Surface+Properties

Apply glass material to sphere layer.

 

11. Select "render" and render scene in  maxWell

12.  Stop "render" change to"camera" tab.

Adjust "resolution"

Re-render and adjust Iso and "shutter-speed"

13.  Go to Multilight tab

Adjust lights as well as  sun, etc.. while rendering

14. Go to  Material Editor, and create emitter and call it "myEmitter1"



Select wattage and other properties.

15.  Go back to Rhino. Edit light properties. And assign emitter to key spot lght via layer option or directly.

16. Note IES (Illuminating Engineering Society) options.

Used in defined emitter in Rhino plugin for Maxwell.

Lighting Fixture Data and Examples

Additional notes



1. School of Architecture Maxwell wiki notes helpful to preparing this outline, written by Alex D'Aversa.

2. Rendering Farming Setup with Maxwell (IT staff notes).