A Basic Vray HDR Tutorial:
*Please note: this article below may be outdated. Most of these techniques are still probably applicable. I will look into updating this as time permits.
I am going to outline a few easy steps for using High Dynamic Range Images with Vray 1.5 SP3 and 3D Studio Max. This should apply to any HDRs you may have in your texture and lighting libraries. Most of you are probably already aware of these basic steps but for those that are not, I will try to walk you from the beginning without going into too much detail and theory.
Linear Workflow Setup:
1) First, you will want to use Linear Workflow for more accurate color reproduction. Technically, you do not have to use LWF but you’ll find yourself manually adjusting your images in post-production in order to achieve better realism. This is true for almost all scenes when using Vray.
Open up Max and browse to the top menu bar: /Customize/Preferences/Gamma and LUT/ and make sure the following parameters are set:
3D Studio Max Units Setup:
2) It’s generally a good practice to set your scene dimensions to real world units. Again, this is not necessary but it is very helpful for reproducing more accurate lighting conditions. It’s especially important when working with both architectural and product modeling.
I almost always try to at least approximate the dimensions of my 3D models even if the measurements aren’t completely accurate.
Browse to /Customize/Units Setup/ and set your parameters to your local system of measurement:
Scene and Model Setup:
3) Insert your model into the scene or create a new item such as a teapot in the top viewport. I’ll set the teapot radius to 1′ as an example.
4) Right click your model, select move from the context menu, and zero out the coordinates in the XYZ boxes at the bottom of your screen so your model is centered.
5) Create a plane in the top viewport near the center of the scene. Usually, I start to drag out the object as I’m holding the control button down – this way the plane is created from the center instead of an edge. I usually “zero out” all of my models.
Your scene should look similar to this:
6) VRay works best if you use Vray materials instead of standard ones. On large scenes, sticking with VRay Materials can shave off several minutes of rendering time.
Create a plain white Vray Material and apply it to the plane:
Please note that with LWF, pure white colors (255, 255, 255) can lead to excessive render times. I usually reduce my white values by several points out of habit. In this case I set my values to 254.
7) Create another Vray material of your choice. For this example, I’m using a basic chrome material as it demonstrate good reflections. Apply the material to your model:
8) Create a VrayPhysicalCam in your scene:
9) Press ‘c’ on your keyboard after laying out your camera in order to view the scene as the camera sees it. You may want to adjust the position of your camera with the rotation controls in the lower right-hand side of your screen. My Physical Camera settings for HDR images usually render nicely at F1.2. Sometimes, I will also set the White Balance settings to neutral.
10) Now we will set up the HDR lighting. There’s several ways to insert a HDR into a scene, but Vray provides a very efficient light called a domelight. This light can be inserted anywhere in your scene as position does not matter.
Occasionally, inserting a domelight into a scene may cause the colors in the viewport to shift. Simply press ctrl+l several times in a viewport to change the default lighting setup until you find a lighting mode that works or resets it.
Below is my HDR lighting setup:
Please note that there is a resolution number which defaults to 512 under the Texture section of your light. This number can be changed (I used 1024 here) depending on the quality desired. This also increases rendering time especially on very complicated scenes.
You can also choose Spherical (full dome) under your light’s Dome light options (not shown) if you want the light to completely encompass the scene from an angle below the horizon. In most cases this will never be seen and will only add the lighting calculations.
11) Drag the VrayLight VrayHDRI Material over to an empty slot on your Material Editor and select instance on the pop-up window.
In the Material Editor, browse to the HDR/EXR of your choice:
I selected a HDR from one of my HDRSource libraries. HDRSource HDR images fit the Spherical Mapping type. You can usually tell which mapping type you have by looking at the material preview window. If the Material Editor Preview image looks distorted, try selecting other types of mapping.
12) Now we are ready to run a test rendering. Open up your rendering setup window from the top menu bar: /Rendering/Render Setup (shortcut =F10.) I’ve provided a very efficient test rendering setup below:
Rendering the Results:
13) Select your Camera in the viewport or press the ‘c’ key after selecting your viewport. This should switch you to your camera view. Now you are ready to make your first rendering test. Select render.
Below is my final result:
Additional Tips and Information:
1) Scenes may look perfect, too dark, or too bright depending on the HDR used. There are several different options you have at this point. You can change the camera angle, change the camera F-Stop, or adjust the brightness/contrast in post with a program like Photoshop. You may also have vignetting turned on which will darken image corners. Last but not least, your camera White Balance can introduce an unwanted tint. I usually turn my white balances to neutral but sometimes daylight settings (the default) works well.
2) Sometimes I’ll add a Vraylight set to sphere, No Decay checked, and a slightly tinted yellow in direct position of the sun. This can add a more defined shadow as well as a little bit of warmth to your scenes. You may need to adjust your light multiplier. This is really dependent on the HDR being used and also the look you are going trying to achieve. In the image above, my teapot is in the shade (just like the HDR which was shot) and I’m fine with the lighting. I could dial down the F-Stop of the camera .5-1.0 to make it a little bit brighter.
3) You can try out as many HDRs as you like by simply loading them in the Material editor.
4) You can change the camera angle manually, or turn the actual HDR by entering in new ‘Horiz. rotation’ values in the Material slot.
5) When you are ready to render the final image, adjust the “Width” and “Output” size under the “Common” render tab. The “antialiasing filter” found under the Vray render tab will produce sharper edges. Under the “Indirect Illumination” tab, you can change your “Primary Bounces” to “Brute Force” (default settings) or “Irradiance Map” (change to medium or high settings.) Set your “Light Cache” to ~1500 subdivs. Finally, you can raise the “Global Subdivs Multiplier” under the “Settings Tab” to 2 or 3 (even higher) if you’d like to increase the overall rendering quality.