Icecubes In A Glass
Download the files first
Set up a scene with a table and a wall beyond it. Use ordinary boxes for the table and wall.
Create a subdued checker material and apply it to the wall.
Create a wood material and apply it to the table. To make the tabletop a flat mirror, select the table and go to the Modify panel. Click More on the Modify panel and choose Material. Make sure Material ID is 1. Click Mesh Select. Select the top face of the table, the face where the glass will sit. Make sure the selected face is red. Apply the Material modifier, and change Material ID to 2. This assigns material ID #2 to the tabletop only.
On the Maps rollout for the wood material, click on the button labeled None across from Reflection. Choose Flat Mirror from the list that appears. When the Flat Mirror Parameters rollout appears, check the box next to Apply to Faces with ID, and change its value to 2.
Click Go to Parent . Change the Amount across from Reflection to 30.
The tabletop will now subtly reflect anything on top of it.
Next, you'll make the glass object itself. Draw a line for the profile of the glass, similar to the line shown below. Make the bottom part of the line sit on the table. Note that at the upper tip of the line, the line curves around to form a nearly closed circle.
With the line selected, go to the Modify panel. Click Lathe. Under the Align section, click Min to align the center of the lathe with the left side of the shape. Set Segments to 32.
Check the Weld Core checkbox. Checking Weld Core gets rid of the pinched star that sometimes appears at the center of a lathed object.
If the lathed object looks odd, as if it may be inside out, try checking the Flip Normals checkbox to see if that makes the object look better.
This lathed object will become a drinking glass. A shiny, transparent material will be put on it later.
Next you'll set up the camera and lights. Place a Target camera in the Top viewport, starting at the bottom center of the viewport and going to the center of the glass. In the Left viewport, move the camera upward until it looks down on the glass at approximately a 20-degree angle.
Place a target spot in the Top viewport, starting at the lower right corner and going to the center of the glass. In the Left viewport, move the light up until it shines down on the glass at approximately a 45-degree angle. The light and camera positions in the Top and Left viewports should be similar to those shown below.
Create an omni light at the lower left corner of the Top viewport. Move the light upward in the Left viewport until it is nearly level with the spotlight. Change the V value to 110.
For the target spot, set the following parameters:
Cast Shadows: On
On the Shadow Parameters rollout, open the pulldown list and choose Ray traced Shadows.
For shadows from transparent objects, the raytrace method works better than the shadow map method (the default method). The raytrace method makes transparent shadows for transparent objects, while the shadow-map method makes solid shadows no matter how transparent the object is.
Activate the Perspective view, then press c to change it to the camera view. If necesary, use the Dolly Camera and Truck Camera tools (like the Zoom and Pan tools) to move the camera into position, then render the camera view. Check that the shadow and reflection are appearing on the table. If not, look back through the previous steps and correct the scene.
Next you'll make the material for the glass. This material is the most important part of this tutorial. It is made up of shininess, transparency, and both a Reflection and Refraction map. A variation of the glass material will be used on the ice cubes.
Make a material with the following attributes:
RGB: 135, 135, 135 (medium gray)
Specular Level: 80
Assign the material to the glass. Render the camera view. The glass is transparent and shiny, but the material still has a long way to go.
To make the bitmap to be used as a Reflection map, open a paint program such as Photoshop. Create a new picture with the dimensions 400x400 and a black background. With a white brush, draw thick, smeared vertical lines. Draw a few white blobs as well. Your drawing should look something like the following picture.
Save the drawing as a JPG file in the \3DSMAX4\MAPS directory with the name GLASSREF.JPG.
Return to the Material Editor. Expand the Maps rollout. Across from Reflection, click on the box labeled None and pick Bitmap from the list that appears. Pick GLASSREF.JPG from the list that appears.
Click Go to Parent to return to the parent level of the material. Next to Reflection, change Amount to 50.
Render the glass. It looks better, but it's not refracting light, which prevents the glass from looking like glass and makes it look like plastic.
On the Maps rollout, click on the box labeled None across from Refraction. Choose Raytrace from the list. Click Go to Parent and change the Amount next to Refraction to 50.
By using the Raytrace map type for refractions, the refractions in the glass will be raytraced, which is one way to get somewhat accurate refraction in MAX.
Expand the Extended Parameters rollout. Change Index of Refraction to 1.1. This IOR (Index of Refraction) will lend a slight refraction to the glass.
Render the camera view. The glass is looking pretty good, but could stand a few finishing touches.
On the Maps rollout, click on None across from Opacity. Choose Falloff as the map type. Render the camera view.
This map type will cause faces facing the camera to render as more transparent than those facing perpendicular to the camera. In this case, the center of the glass will appear more transparent than the outer edge. The effect is subtle, but does make the glass look a little better.
Across from Diffuse, click on the box labeled None and pick Noise from the list that appears. When the rollout with the Noise parameters appears, change Size to 0.5. Click Go to Parent. Next to Diffuse, change Amount to 50.
This change will make very slight spots and irregularities on the glass, making it more realistic.
Render the camera view. The opacity on the glass has changed, and it also has subtle specks on it from the noisy Diffuse map.
Now for the ice cubes. Make a small ChamferBox with the same Length, Width and Height, and with 5 segments along each dimension. Give the ChamferBox 2 Fillet Segments. Make two copies of the box.
Apply a Noise modifier to each box, giving each slightly different parameters. You should have three bumpy cubes when finished.
Create a copy of the glass material in the Material Editor. Give the new material another name so it won't overwrite the glass material when applied to the scene.
On the new material, add a Noise map for the Bump map. Set the parameters so lots of small bumps appear on the sample sphere. Apply the material to the ice cubes.
Put the ice cubes in the glass and render the camera view.
There are a number of ways to make different kinds of glass and ice effects. Experiment with this tutorial to familiarize yourself with refraction and how it works.
Important note: The author is not a natural English speaker and there is a high chance of mistakes in every way. Corrections and comments are welcome.