|
|||||||||
Texture mapping complex objects using just planar mapping |
|||||||||
Skill level: Beginner/Intermediate Download the completed exercise & textures here Texblend.zip Preamble Lightwave has a superb rendering engine, backed up by a good range of texture types, but the most useful, & sometimes most frustrating, is the virtually unlimited number of texture layers that you can apply to an oject. Proper use of this facility can overcome the blindingly frustrating lack of UV Mapping, which is included in just about every 3d package known to man. Normally, the use of planar mapping, is all you need. However, texture striping will occur if the shape you want to map has any flat edges at its extremes. (Click on the image to see a larger version)This image is a render of the Triceratops model that can be found in the animals directory, with the skin surface being just one texture map along x. Autosize is used to position the texture map - which was draw over a screen grab of the side view (see section on texture creation). Things look pretty bad, even if you ignore my garish texture & lighting. Striping is evident along the forehead. If we change the map for one that is applied along y, things look even worse. Don't Panic I will now attempt to illustrate one way of overcoming this problem using multiple planar mapping along different axes, using texture falloff to blend the different texture maps. My example is using garish colours to show the operations being carried out, & doesn't really require the textures to be in any particular order. Normally the first texture in the list is the base layer & will have 100% opacity, the next layer should have less & so on. This example uses falloff to blend the textures where they meet, so you can leave all layers set to 100% opacity, although you might want to see what happens if you don't....
Now we do something that might seem a bit odd, but bear with it, all will become clear.
You should see something like this. This is probably just what you expected, after all, we are applying 2 textures over the same axis. How do we get around the problem? Simple. Move the texture coordinates so that the top & bottom textures actually sit just above & below the object respectively. In this case the skin surface height is from y=0 to y=3.3357 The 'Automatic Sizing' button initially puts each texture at the centre point of the surface, so we need to move it For the bottom texture, set the Texture Centre to y=0.
Just moving the centre of the texture has no obvious affect, so what gives? This is where the texture fallof comes in handy. In essence, we want the bottom texture to appear only on the bottom half, & the top texture to, well, appear on the top half. This is the bit where things can get a little bit tricky, so read carefully.
Why? because texture falloff in any given direction obeys these rules
If all axes are used, with equal settings, the fallof is a sphere of texture that is 1m in diameter. So, the reason we set the falloff to y=30 is because the surface is 3.3357m in y & we want it to fall off to 50% about half way up (the belly) and 100% at the top or bottom depending on the direction. 30 x 3.3357 is approx 100. If we left the textures centres in the middle of the surface, they would fall off equally above & below, creating a stripe of solid texture in the middle, fading off to 50% at the top & bottom I have changed the surface colour to pink so you can see the effect So, the top texture fades off to the bottom & the bottom texture
fades toward the top. Where they meet, in the middle, they are both at
50%. We can tweak the bottom texture slightly, to put it a bit nearer the belly, but will have to increase the falloff so it doesnt encroach on the top texture.
You will still see a fair amount of striping down the side of the creature. This is where some simple Texture Alpha Images (opacity maps) come in handy.
Things to do next:
If you want to create your own textures, I have grabbed a side & top image for you to paint over. All the files needed, including an object with the finished texture are in this zip file. Click to view the full size images. To use the object (tricerabox.lwo), first load in the original triceratops model from your disk, then load in the box. It's texture will replace the skin texture on the dinosaur model. I didn't include the actual model for copyright reasons. If you have any problems with this, please email me |
|||||||||
|