Building an avatar in Blender from scratch. Step 8: UVmapping Deka

September 20, 2010 by griff   Comments (0)

So we have Deka created but we need to create a UVMap so that we can texture on the clothes etc. Normally in the past I would have used UVMapper, but for this I continued on in Blender using another Jonathon Williamson tutorial which you can find here .

There are a number of things that I can say up front about the tutorial:

1. His final result is two textures - the head and the whole body. For VRML we want a single texture - so ignore the two textures build it all on one texture.

2. The final result from the tutorial has the body as one single piece to texture - but that, as the tutorial says, wastes pixel space. So that whole section I ignored.

3. The tutorial use a mirror while mapping - which saves time but does not give you the real picture of the UVMap until you apply the mirror. I did it without using the mirror which means extra work - but to be honest not that much - basically duplicating the seams for the right/left arms and the right/left legs. (You can select edges for seams by going into the Edge selection mode and Right Click then Shift Right Click on edges you wish to select.)

4. The tutorial uses Blender 2.5 but I did it in 2.49 - there are major differences but most of them apply to item 2 above. The seams created in the initial part of the tutorial are all you need.

The final map I ended up with is not the same as the usual uvmap of Avatar Studio or even Second Life - they are planar maps (front and back) - and the sides are stretched and distorted. 

The initial map was created at 2048x2048 - so that I could work with it in Photoshop or Gimp to create textures. Then, when I was happy, I reduced it to 1024x1024.  


image

The above image shows the basic Blender setup that I used. The screen is split into two sections - a windiw showing the 3d model in the Edit mode (left A) and a window showing the UVEditor.

 

I added an image to Deka by selecting all the vertices in the Edit Window and then loading an 2048x2048 pixel basic skin image in the UVEditor window (Image -->Open). The UV map to be created is restricted to this image by UVs-->Layout Clipped To Image Size. (Menus under the UVEditor window) 

The mapping in Blender is done by creating seams then unwrapping about those seams. The figure below shows how I subdivided Deka (head, torso, legs/feet and arms/hands) and and the seams I created (orange lines) - basically a slightly simpler version of those in the video tutorial. Wherever possible the seams are in areas that are seldom viewed (inside of legs underneath of the arms etc)

 

image

 

The image below gives a brief step by step method of unfolding the head.

1. Select all vertices for the head (A key).

2. Then in the Edit Window Mesh --> UVunwrap -->Unwrap - the Result is A in image below.

3. In the UVEditor Window, the flattened vertices of the map are dragged to the centre of the image (G key)then scaled (S key) to fill the texture - the Result is B below.

4. Still in the UVEditor window, the map is scaled to 50% of full size (S key 0.5)and dragged to the top left corner - Result C below.

5. And finally so that the UV map is a few pixels away from the image edge, it is scaled to 95% - S key 0.95



image


This procedure was repeated for the torso, legs and arms and then the hands and feet were fitted into the open spaces.

 

The final UVmap looks like the left side of the image below. The right side is a quick preliminary texture using a fancy lace texture for the top and a jean texture with vertical thread discolouration for the pants. The insets are enlargements if the front (A), the back (B) and the side (C). The model is VRML exported from Blender and viewed in Instant Reality which Russ Kinter is using for his Deep Matrix chat system.


image


Note there is little or no stretching of the fancy lace pattern at the sides, no obvious seam where the seams were created on the model and no smearing of the jean threads as you go around the model and the threads remain essentially vertical (allows adding side seams to military pants/unforms, jeans, stockings etc)

I hope to post some more textured examples at a later date.

 

griff :)