Wednesday, 18 December 2013

Daylight Scene in 3D max

This tutorial shows you the basics of how to set up daylight lighting in V-Ray using VRaySun and a 3ds Max daylight system for precise control of time of day and location.

In this tutorial we will start by lighting our scene with a VRaySun inside a 3ds Max daylight system in order to have accurate time and location control.

1 . Switch to top view and go to the create menu > systems > daylight system. Now click and drag a daylight in the center of your scene.
2 . Now we need to change the settings of the Max daylight system so that it uses a VRaySun to light our scene. Select the daylight system and in the modify panel select VRaySun from the Sunlight dropdown menu. Accept the request to automatically add a VRaySky environment map. We will be using the automatically created VRaySky environment map to light the scene, so we also need to disable the Skylight. Select from the Skylight dropdown menu.
3 . We can now use the daylight system to accurately position our VRaySun and we do so by clicking on the setup button in the modify panel and then adjust our time and location to our needs. In this example I have set it to 15:45 and this gives me a low angel for the sun, thus creating a nice afternoon mood. TIP: Having the sun at close to a 90 degree angle will resemble 12:00 mid-day resulting in a brighter scene.

Before we go to rendering we need to adjust our VRaySun and create a VRayPhysicalCamera in order to have physically correct exposure.

4 .  Go to the VRaySun rollout of the daylight system in the modify panel, and select CIE Clear from the sky model dropdown menu. This setting gives you a few presets of physically correct sky models that will contribute to the overall lighting of our scene.
5 . Now in the top viewport create a VRayPhysicalCamera and point it at the object.
6 . Select the VRayPhysicalCamera and go to the modify panel and adjust the distortion to 0.25. This will curve the camera lens slightly just like the lens in real world cameras.
Then set the vignetting to 1.3 which will mimic an effect produced by the lens that darkens the corners of your image. This will help draw the eye to the center of the image. White balance is important because it will affect the overall color tone of the image, a light blue will balance the image and a dark blue will give us a more yellowish tone whereas a light orange will give us a cold blue tone. Feel free to play with this, and at the end of this tutorial there are a few images showing the effect of color balance. The last thing to set in the VRayPhysicalCamera is the film speed. The higher the value the brighter the image just like in real world films. This value represents the films sensitivity to light, and in this case we set it to 120
7 . If you render your scene at this point it will look like the image below.
8 . Lets quickly set the 3ds Max gamma setting to a Linear Workflow (If you haven't already) so we can get the correct colors. Go to the customize menu > preferences, and then select the Gamma and LUT tab. Check enable Gamma/LUT correction, and adjust your gamma value to 2.2 and set input gamma to 2.2 and output gamma to 1.0 .
9 . Now let's jump to the render settings. Press F10 to open the render dialog box, go to the VRay tab and enable built-in frame buffer. This will allow us to further control our exposure and colors after the rendering is done and will be a huge time saver. To ensure image sampling happens at the correct gamma level for our render we need to adjust the gamma to 2.2 and enable Don't affect colors(adaptation only). Unless we do this the image sampler will be using gamma 1.0 to determine if sampes are within acceptable noise thresholds, and we end up with a more noisy image when viewed at gamma 2.2
10 . Move to the Indirect Illumination tab and enable GI. For primary bounces we will use Irradiance map, and for secondary bounces we will use Light cache. This combination gives us a fast plus clean render. well… fast-ish .
11 . Now that we have chosen our GI method combination we need to adjust them, so go to the Irradiance map section and choose medium. Or if your computer is slow you can set it to low or very low and do a bit of compromising. Enable show calc phase, this will let you see the irradiance map while it's being calculated .
12 . In the Light cache section set the subdivs to 1500 and (or if your computer is slow set it to around 800, but not lower if you need a good quality image). Also enable show calc phase to see the light cache while it's being calculated
13 . We are done now, and you can render the scene. In the VRay Frame Buffer you have to click on the sRGB button to see the final result of our gamma correction. Also and notice that you can enable the curve editor by clicking its icon at the bottom of the VRay Frame Buffer window and then adjust the color to your liking. Remember to save your images in a linear format, like Open EXR, as this will ensure that the image displays correctly further down your pipeline (see image below). If you want to save to a format line PNG, TIFF or JPG you should change the output gamma in the save dialog to 2.2 to burn in the gamma.

And here is the final image:


I hope that you have enjoyed this tutorial and happy rendering .

No comments:

Post a Comment