Archive for April, 2009
In this tutorial I will show you 2 ways of making a frosted glass material in 3d max. The first part of the tutorial is focused on obtaining this type of material directly from the render. Although this part is especially written for 3ds max and vray, the same workflow can be applied to any other rendering software.
First method
1) The basic material settings.
Every time I have a glass material in a scene, I start with the following parameters:
a) diffuse color – pure black
b) reflection – a falloff map from black to white, set to FRESNEL
c) refraction – pure white
d) Index of refraction (“IOR”) 1.4
e) Refraction “max depth” 7

If you hit a render at this stage you will have a clear glass material, like the one in the following rendering:

2) Controlling the sharpness of the refraction and reflection
As you can see both reflections and refractions are clear. You can now start by blurring the refractions. You control the sharpness by adjusting the glossiness parameter under “Refract”. A value of “1” for the glossiness produces crystal sharp refractions; by decreasing this value the refractions will become more and more blurry.
For this example, I think that a value of “0.95” is enough.

The refractions are now ok, but the reflections are still sharp.
You can adjust this in the same manner as you did for the refractions, by decreasing the glossiness parameter under “Reflect”.
The beauty of using this method is that you can control the reflection glossiness and the refraction glossiness separately; some types of frosted glass materials, although they have very blurry refractions, the reflections are quite sharp.
Here is a test I did with blurry reflections.

3) Controlling the color
If the frosted glass material that you need to obtain has a color tint, you can assign it by changing the “fog color” from white to whatever color you need.
Note: This has quite a high impact, so you need to use very bright and desaturated hues.
Bellow you will see 2 tests I did, with different values for the fog color:


4) Bump mapping
If the material you want to achieve has some bump pattern applied, just apply the desired bump map in the “bump” channel, and you’re done
Second Method
In the second part of the tutorial, we will go through a more versatile method of obtaining a frosted glass material that allows you to quickly change how the material looks, without having to render again.
Stay tuned!
For some time I’ve been experiencing a lot of problems with 3ds max design 2009; 8 out of 10 times when I was panning or zooming, max was crashing and I was losing more time waiting for it to restart than I was spending on the actual work.
The first thing that crossed my mind was that it might have been a hardware problem; either the ram memory or the video card. However, it couldn’t have been a hardware malfunction since I had the same problem with all the 5 workstations (identical configurations) in our office. I have updated the drivers with the latest versions, but nothing seemed to solve the problem.
Today when I was talking to a friend of mine this subject came up and he told me that he had been having the same problem, but unlike me he managed to solve it. Apparently it all had to do with the “view cube” and after disabling it, max doesn’t crash every 15 seconds.
I checked this out first thing when I got back to the office, and to my surprise, it did the trick.
Therefore if you are using 3ds max 2009 and the software crashes when zooming or panning in the viewports, than the solution to your problem is to disable the viewcube.
You can do this by renaming the file called “AutoCamMax.gup” located in “program files, autodesk, 3ds max 2009, stdplugs”. (You can delete it as well, but just in case for some reason you decide you want this back, renaming it is the way to go).
Brief introduction
Depth of field can prove to be a very effective way to add a “special” touch to an architectural rendering, or simply to focus the composition on a specific element.
Technically speaking, there are several possibilities to add dof to an image.
One way to do this is to add it from the vray camera rollout (if you are using vray), but keep in mind that the rendering times can go through the roof, so unless you have a render farm you may not want to consider this option.
Another way to achieve this type of effect is by adding it from the “effects” tab in 3d max. Even if this is way faster (being just a post-processing effect) I always feel the need to have more control over it regardless of the camera position or direction.
Rendering a separate zdepth pass
So here’s the way I do it.
Under “Render Elements” click “add” and choose “vrayZdepth” (if you not with vray you can chose Zdepth instead of vray z depth, or the equivalent of your rendering software).

After hitting “render” you will notice that you end up with 2 rendered images, the main image and another one in gray scale. If you look closer at the gray scale rendering you realize that objects that are close to the camera are light gray, and they get darker as the distance between them and the camera increases.

Post processing the zdepth pass
Open both renderings in photoshop.
Select the main rendering and duplicate the “background” layer. With the newly created layer active, click on “layer” drop down menu (at the top, between “select” and “image”), click “layer mask” and select “reveal all”.

Select the grayscale rendering and invert it (image>adjustments>invert). Now using the “rectangular marquee tool” drag a selection over the entire image than press “ctrl+c” in order to copy it to the clipboard.
Select the first image again and click the “channels” tab. Activate the previously created mask (under RGB, red, green and blue channels) and press “ctrl+v” in order to copy the zdepth mask.
Click the “layers” tab and select “background copy” layer to make sure you have the layer itself activated (and not the mask).
Go to “filters” and apply a lens blur filter.
As you will notice, thanks to the zdepth mask, the lens blur is affecting more the objects that are further away, and has less effect to the ones closer to the camera.
The big advantage of using this method is that you can control the depth of field anyway you want, simply by editing (painting) the zdepth rendered pass.
Here are 2 examples that show the flexibility of this method.
Click the renderings to view higher res ones:

