| www.blender.nl this document is online at http://www.blender.nl/showitem.php?id=177 |

Game Textures |  |  | 2001 05 16
| Yamasaki Satoshi | id177

Introduction
gameBlender has many effects for the realtime rendering engine. We can make cool visuals to use them more effectively. In this tutorial we will use them to make a nice looking clown.

Begining
First you need to download the file below (clownsmp.zip). "clownsmp.zip" includes "clownsmp.blend" and "texture" directory (you must unzip "clownsmp.zip". Now load "clownsmp.blend". The left window is the 3d window in wire-mode (). The right window is the Image window for displaying textures.
Download: | clownsmp.zip

I put three lamps in this sample. Select a lamp and press key. You can see the layers in which the lamp is present. You have to put lamps in same layer as the object that you want to light. You can select multiple layers for a lamp (click the layer buttons while holding )

Now select the head. If you make objects in gameBlender, the direction of the object is important. Press the Axis button in EditButtons and look at the 3D window (it should look like the screenshot when you have the button pressed). The front is indicated by the Y-axis of the object. It is used for "Track to", UV-coordinates, etc...

Selecting Faces
Enter the Face Select Mode ( key) and change the ButtonsWindow to "Paint Buttons" (click icon). If not all of the faces are selected, Select All with .

Press key with the mouse in the 3D Window to open the Specials Menu. Now we can apply a command to many faces at a time. Select the first Light. This command allows faces to receive realtime lighting from the lamps we set up (Note: when you select the second Light the switch is set to off). You can see that the object is drawn in shaded mode. Also look at the Buttons Window and make sure the "Light" button is pushed.

UV-Mapping(1):UV-Calculation
Now it's getting about time to attach some textures to the faces. To do this we need to set the view to rear view first. Click icon in the 3D Window Header while holding the key. Press the key to bring up the "UV Calculation Menu" in the 3D Window.

Select Cylinder. Blender will show the UV Mapping in the Image Window. This UV-map is too small, so we'll have to resize it: Click the "Clip Image Icon" (marked with red in this figure). Select all the vertices with and Size them in the Image window so they fit the area you want. If you want to paint a texture image, make a screenshot of the ImageWindow ( with the mouse over the ImageWindow). You can use this screenshot as a template for the texture.

UV maps can be pretty complex. You can paint textures more easily if you only select the faces that will need a certain texture before making a screenshot. |

UV-Mapping(2): Attaching a Texture
We'll use the sample file "facemap.jpg" from the zipfile you downloaded earlier in this tutorial. Press "Load" button in the Image Window, and select "facemap.jpg" from the texture directory.

Change to "Potato-mode" () in the 3D Window. You'll see the texture has been applied to the object. When you're done press to exit Face Select Mode.

Halo effect
The "Halo" effect makes each face turn to the camera. It is often used for flares, lightning, and in this case something like a ball. Let's make the clown's nose and the balls on his collar and hat. Change to top view (), and add a Plane Mesh ( >> MESH >> Plane) somewhere. Make sure the Double sided button is not checked, and Draw Normals is checked in the EditButtons .

Next, Change Front view(), and Rotate () all vertices to 90 degrees (hold ). Note: Halos will only show faces that face the positive X-Axis.

Change to side view (), go out of Edit mode() and enter Face Select Mode (). Load "nose.tga" in the ImageWindow. This file is formatted as "RGBA Targa", which means we can use the alpha channel for transparency.

Change the ButtonsWindow to the PaintButtons and press Halo, Alpha, Light and Twoside button. Look in the 3d Window (change to "potate-mode" if necessary). Finally change the Button Window to Material Buttons() to attach the material "clown".

Make the woolen balls in the same way and parent () them to the "Neck" object.

Vertex Paint
Vertex Paint is easy way to make materials for low polygon models. It is also used to economize on the texture memory and to make static shadows. And you can use it with a texture. Now, we use Vertex Paint to paint the cap of our clown. Select the head object and enter Face Select mode.

Select target faces |
We can select faces in the Face Select Mode with , but we can only select faces that are facing the camera. A nice trick is to select faces in EditMode. Press the key. In EditMode you can see the selected faces (you may have to press 'Draw Faces' in the lower right of the EditButtons . Now select the vertices like in this figure. Press key to escape EditMode and open the Specials menu (). Select the Clr Tex command to remove the texture from these faces. Change the ButtonsWindow to the Paint buttons.

Painting |
Press key to enter Vertex Paint Mode. Set the RGB slide to blue (0.0, 0.0, 1.0) and click to paint faces. When you're finished painting, enter the EditMode again and select the other side of the cap. Now set the RGB slide to Yellow(1.0, 1.0, 0.0) and paint once more.

Now paint the other parts in the same way!

Final words....
You can download the final result below. Of course this is just a sample. You can try to make a clown any way you like now! Yamyam
Download: | clowngoal.zip