Chapter 1. Overview of Materials in Cycles

In this chapter, we will cover:

  • Material nodes in Cycles
  • Procedural textures in Cycles
  • How to set the World material
  • Creating a mesh-light material
  • Using displacement (aka bump)

Introduction

Cycles materials work in a totally different way than in Blender Internal.

In Blender Internal, you can build a material by choosing a diffuse and a specular shader from the Material window, by setting several surface options, and then by assigning textures (both procedurals or image maps as well) in the provided slots—all these steps make one complete material. After this, it's possible to combine two or more of these materials by a network of nodes, thereby obtaining a lot more flexibility in a shader's creation. But, the materials themselves are just the same you used to set through the Material window, that is, shaders made for a scan-line rendering engine as Blender Internal is, and their result is actually just an approximation of a simulated light absorption-reflection surface behavior.

In Cycles the approach is quite different: all the names of the closures describing surface properties have a Bidirectional Scattering Distribution Function (BSDF), which is a general mathematical function that describes the way in which the light is scattered by a surface in the real world. It's also the formula that a path tracer such as Cycles uses to calculate the rendering of an object in a virtual environment. Basically, light rays are shot from the camera, they bounce on the objects in the scene and keep on bouncing until they reach a light source or an "empty" background. For this reason, a pure path tracer such as Cycles can render in reasonable times an object set in an open environment, while instead the rendering times increase a lot for closed spaces. For example, furniture set inside a room, and this is just because the light rays can bounce on the floor, the ceiling, and the walls a good many times before reaching one or more light sources.

In short, the main difference between the two rendering engines is due to the fact that, while in Blender Internal the materials use all the traditional shader tricks of a scan-line rendering engine such as, for example, the simulated specular component, the Cycles rendering engine is a path tracer trying to mimic the real behavior of a surface as closely as possible as in real life. This is the reason why in Cycles we don't have, for example, the arbitrary Spec factor simulating the reflection point of the light on the surface, but a glossy shader actually mirroring the light source and the surrounding, to be mixed to the other components in different ratios and so behaving, in this respect, in a more correct way.

In any case, just for explanatory purposes, in this book I will still refer to the more or less blurred point of light created by the reflection of the light source on a mirroring glossy surface as Specularity.

Be aware that the rendering speed in Cycles depends on the device—CPU or GPU—you use to render your scenes. That is, basically you can decide to use the power of the CPU (default option) or the power of the graphic card processor, the GPU.

To set this:

  1. Call the User Preferences panel (Crtl + Alt +U) and go to the System tab, the last one to the right of the panel.
  2. Under the Compute Device tab to the bottom-left of the panel, select the one to be used for the computation; to make this permanent, click on the Save User Settings button or press Crtl + U. Now close the User Preferences panel.
  3. In the Properties panel to the right of the interface, go to the Render window and, under the Render tab, it's now possible to configure the GPU of the graphic card instead of the default CPU (the option is present only if your graphic card supports CUDA, that is, for NVIDIA graphic cards; OpenCL, which is intended to support rendering on AMD/ATI graphics cards, is still in a very incomplete and experimental stage and therefore not of much use yet).

A GPU-based rendering has the advantage of literally increasing the Cycles' rendering speed several times, albeit with the disadvantage of a small memory limit, so that it's not always possible to render big complex scenes made by a lot of geometry; in such cases, it's better to use the CPU instead.

There are other ways to reduce the rendering times and also to reduce or avoid the noise and the fireflies (white dots) produced in several cases by the glossy, transparent, and light-emitting materials. All of this doesn't strictly belong to shaders or materials, by the way, you can find more information related to these topics at the following addresses:

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset