Projection Map Shadows
This tutorial will give you a step by step method for creating realistic, fast rendering shadows with RPC objects in 3d studio.
Step 1. Create a simple scene in 3d studio consisting of a ground plane, a single RPC tree (or person), a Target Spot Light to act as the shadow casting light source and a camera for viewing.
Step 2. The next step is to turn off all objects in your scene except for the RPC(s) that will be casting a shadow. Next, change one of your viewports to be a view from your shadow-casting light source. I've named my shadow-casting light "My Sun" so that it is easy to find in the viewing list. You get this menu by right-clicking on the name displayed in the top left corner of each viewport. Your view in this viewport will now be from the shadow-casting light.
Step 3. We now need to adjust the settings for our light to create a proper shadow. I used a Target Spot Light with a Luminance value of 255 and a Multiplier of 1.5. To set the luminance value to 255 click on the color and change all color settings (R,G,B) to 255. You are by no means limited to these settings with your own lights. In this example I have set the "Overshoot" option "On" thus having light affect the entire scene. Again, this is not mandatory.
We now adjust the Falloff of the shadow-casting lightsource so that the RPC objects that I wish to cast a shadow can be seen fully in the view from that lightsource.
Step 4. The next step is to render an image of the RPC(s) as viewed from the shadow casting lightsource. I rendered a 640x480 image of the "Perspective" viewport as shown below.
Step 5. Now save this image as a 32 bit Targa file (tga) and include the option to split the alpha of the image out seperately. I chose to name my file "MasterShadow.tga". Choosing the "Alpha Split" option will automatically create a second tga file named "A_MasterShadow.tga". This is the file we are interested in using in this exercise.
Step 6. Next, launch the Material Editor and create a new Standard Material to be used to load the shadow image. Choose to load a Bitmap into the Diffuse Channel of this new material and browse for your newly created image rendered from the shadow-casting lightsource. The alpha split that I saved was called "A_MasterShadow.tga". I'll load this image into the Diffuse Channel of my new Material.
Step 7. Now that the bitmap has been loaded into the Diffuse Channel we need to Invert the image to black-on-white from white-on-black. You will find a checkbox for Inverting the image in the Output rollout menu at the bottom of that textures properties box.
Step 8. The next step is to load our newly created matte material as a Projector Map in our shadow-casting lightsource. To do this, choose your lightsource (My Sun) and proceed to the Modify panel for that light. Scrolling down the options for your lightsource you will see "Projector Map". Check the "Map" option and then click on the "None" button which will launch the Material/Map Browser window. Choose the option to browse from the "Material Editor" where you should see a listing of the images currently loaded in your Material Editor including our TreeShadow (I named my material "TreeShadow" in the material editor to make it easy to find) image that was loaded into the diffuse channel. You will be prompted to choose between a "Copy" or an "Instance" of the image. Choose "Instance" so that you can control the shadow effects from the Material Editor.
Step 9. Now that you have the alpha mask loaded as your shadow-casting lights Projector Map you can turn your ground plane (or other objects) back on in your scene and render a view from your camera. Voila! Great looking shadows without long rendering times!
Step 10. You can control the intensity of the shadows by adjusting the "Output Amount" value for your shadow map in the Material Editor. Choosing a value lower than "1" will cause the shadow(s) to become less intense. Choosing a value greater than "1" will cause the shadow(s) to become darker.
Tips: This method of generating shadows is very effective because you can generate a single alpha mask for your entire scene to load into your shadow-casting lightsource. Turn on all of the RPCs in your scene, adjust the shadow-casting light to make sure they are all in view and render a new alpha mask. The resolution that you choose to render your alpha mask will determine the crispness of your resultant shadows. If you want crisper shadows simply render out a higher-resolution image from your shadow-casting lightsource. A lower resolution image will result in a more diffuse look. This can be a great way to generate shadows for other objects beside RPCs! Go ahead, you'll be creating great shadows in minutes.
For some real fun try animating your shadow-casting light over time. All you will need to do to get great shadows moving across your image is render out a series of images from your shadow-casting lightsource and choose the "sequence" option when loading the alpha masks into the material editor.
Need help? Visit support.archvision.com