3d max

Inverted occlusion in 3D Max by Xuan Prada

People asked me for a step by step installation and usage of Binary Alchemy Color Ray Length shader in 3D Max.
Here we go.

Installation

  • Download BA Shaders for 3D Max.
  • Copy .dll files here -> “3ds Max 2010\mentalray\shaders_3rdparty\shaders”
  • Copy .mi files here -> “3ds Max 2010\mentalray\shaders_3rdparty\include”
  • Edit “3rdparty.mi” located here -> 3ds Max 2010\mentalray\shaders_3rdparty
  • Your “3rdparty.mi” must be something like this.

Usage

  • Create a matte/shadow shader and uncheck “receive shadows” and “use ambient occlusion”.
  • In the “camera mapped background” input, connect a “BA_color_raylength” shader.
  • Play with the “spread” to control the behaviour of the occlusion.
  • Once rendered you’ll have something similar to this.
  • Mix the “BA_color_raylength” with procedural maps or bitmaps to improve the result.

Edit: The most important parameters to play with are “spread” and “far output”.

Inverse dirt maps by Xuan Prada

Sometimes is very useful to generate inverse occlusion bakes to reach an interesting starting point to paint our dirt maps.
Vray dirt material is perfect for this goal, but if you don’t work with Vray, is very easy to do the same with Mental Ray and Binary Alchemy Shaders.

  • You need to install the Binary Alchemy Shaders. Some packages are free and you will have to pay for another ones.
  • Apply a “surface shader” to the object and connect a “BA_color_raylenght” to it.
  • Put this shader in “Inverted Normal” mode and play with his parameters.
  • We get an inverted “ambient occlusion”.
  • Use a “blend colors” , “layered shader” o similar to combine this inverted occlusion with a nice bitmap.

Worn edges by Xuan Prada

This technique is based on “worn edges techniques” by Neil Blevins.

Requirements

  • 3D Max Scanline Render
  • SoulBourn Scripts
  • Warp Texture Script
  • All the objects must have a correct UV mapping

Procedure

  • We must complete perfectly the UV mapping of the objects, without overlappings and similar common issues.
  • To reach better results, we need more geometry information, especially in the corners.
  • For that purpose, duplicate the objects, rename them and apply them some bevels in the corners and one or two turbosmooths if necessary. (but try first only adding bevels).
  • Note: All the object mesh must be “Editable Poly”.
  • Select the object and execute “Corner edge to vertex map” script.
  • We will have to play with the low and high angle parameters, especially decreasing the intensity of the low angle when more complex geometry has the object.
  • The next step is to distort this mask created by vertex color, to give it more caotic shape and indeed, more real aspect.
  • We need to download the “warp texture” plugin.
  • In a standard material connect the warpt texture to diffuse channel.
  • In the target input connect a vertex color. 3D Max put by default the vertex information which we have generated previously with the corner edge to vertex script.
  • In the warp input connect a procedural noise, whose parameters will vary depending of scene scale and object size.
  • If we hit a render we reach a pretty decent results, but we need to define better our mask.
  • If we put an output in the vertex color channel, we can play with the curve for empathize the results.
  • In the noise we can also play with his output.
  • To finish, we can bake this mask to paint it in a more appropriate software.

Dust shader by Xuan Prada

This shader is completely procedural, easy to setup and quick to render. It's so basic but it gives you the sense of real dust, adding to your props some realistic properties and richness.

It might be useful for environments like basements, storage rooms, etc.
I'll be proposing two different ways to create this shader.

The first version is probably better, in a way that looks more realistic, but render times are also higher.
The second one is more simple, less real but it renders way faster.
It is always a good idea to know how to setup both version, depending on your production needs so here we go.

Dust_material_vray_v001

This material has been created using a blend node that mixes two different shaders using a mask. You can use a procedural or bitmap masks.

The first shader in the mix is the one designed to create the surface properties of your asset. In this case is called "teapot". Very simple shader with some reflection properties.

The second shader in the mix is the one designed to be dust. It's a simple shader without any kind if reflection, just matte properties.

You can also add some procedural noise as bump map, to simulate dusty areas and make some differences against the teapot material.

As mask I'm using a towards/away falloff in z direction. Playing with the mix-curve you can control the behaviour of the mix.

In the white colour of the mask we can add some procedural noise to create variation.

The best way to adjust all the shader parameters is testing them one by one in different renders.

Teapot shader.

Dust shader.

Dust mask.

Final render.

Improved dirt maps by Xuan Prada

When we start the task of texturing props, environments or characters, one of the first steps we accomplish after completing the UV Mapping, is baking different texture maps or procedural maps (or any other type) to a later use them as a base point to paint our textures.
Probably the most baked map is the ambient occlusion, to reach a base of dirt in logic areas which we will modify in Photohop, BodyPaint or Mudbox.

In my own experience I think that occlusion bakes are incredibly useful but a little bit boring.
Find below a simple method to create a more funny and live ambient occlusion bakes.

  • Using a costant shader or any other which are not affected by lighting, we mix using mix2colors, blendColors or Mixer.
  • In the channel 1 of the mix we use a map. Can be procedural or bitmap. In this example I’m using a tiled bitmap.
  • In the channel 2 of the mix we use a white color.
  • In the mask of the mix we use an ambient occlusion.

With this method we achieve that the bitmaps or procedural maps get masked by the occlusion, creating dirt on the logical and less exposed areas, but with the variation given by the map.
The keys to reach good results are the configuration of the occlusion and the quality of the maps.

This is the scene that I'm using for this example.

Regular ambient occlusion render.

Ambient occlusion render mixed with bitmap textures.

Dirt shader in Softimage.

Dirt shader in Maya.

Dirt shader in Max part 1/2

Dirt shader in Max part 2/2