miércoles, 12 de junio de 2013

Hi everybody. Sometimes, when you are creating a complex scene, you need a method to get a simple render of your objects, without taking account into materials, lights, backgrounds or environments. This is known as a clay render (see the image below). In some render engines you have an option to do this. But in Cycles you don't have it.

The color should be RGB (0.8, 0.8, 0.8) or similar, and the roughness is 1.0. This use the Oren-Nayard algorithm for the diffuse shader. The Lambertian algorithm produces brighter colors and darker shadows, and it is used with roughness equal to 0.0.

If you want to assign one material to all the objects in your scene, you can create it for one object, select this, then press A (select all objects, but the first is the active object), and go to menu Object >> Make Links >> Materials.

You don't need to set lamps, meshlights or check Ambient Occlusion in your World settings. If you prefer another background color just change the blue color in that Background node. The white background node has a color value of RGB (1.0,1.0,1.0).

As you can see the background of the scene is a plane with a texture image. I will set my rainbow just before the background. (note about the background: As I want the render to be realistic, I have flipped the background image file. This is because of the rainbow must be in the opposite side of the sun. See the thread above for further details about a realistic rainbow by @CarlG)

This are the steps to create my rainbow mesh:

1. Set the cursor on the background plain (press Shift + S >> Cursor to Selected)

7. Grab your rainbow mesh just a bit in front of the background, along the Y axis.

8. Locate it in a realistic position, on the opposite side of the sun and in an angle around 42 degrees.

9. Add a Subsurf modifier to smooth the shape

Now it's time to setup your rainbow material. As I need to set my texture along the mesh, I will use UV unwraping. In particular I have unwraping my rainbow mesh with Follow Active Quads >> Even option. Previously you must select all your vertexes.

This is the node setup I have used:

And this the texture options. Pay attention to the texture mapping (go to Properties >> Texture Button >> Mapping ):

The rainbow is finished. If you render the scene you will get the following:

EDIT: I have modified the scene changing the position of the sun, to get a more realistic render (the sun must be in the opposite place to the rainbow).