Polytron32 Manual - written by Steve Klinger

The Polytron32 Tools

 

Texture Mapping

Texture mapping is the process of aligning textures in a fashion that leaves the textures aligned from polygon to polygon. The texture mapping types currently supported are Planar, Spherical and Cylindrical mapping.

Planar Mapping is a type of mapping process that sets the textures basic alignment oriented by a chosen viewpoint. For example, we can set the texture to appear as normal when the mapped object is viewed from the front (XY Plane). We can think of this as if we were to drop a texture covered blanket on the model from one of the three directions.

Spherical Mapping will map textures in sphere-like fashion. I'm not currently adept at this map type and you should be aware that the results can be less than perfect. Heiko and I decided that we would include this functionality because it seemed stable and the results, although imperfect, could be tweaked where necessary using the texture alignment functions.

Cylindrical Mapping can be thought of as similar to wrapping a piece of wall paper around a tube. The orientation of this wrap is based on one of the three axis'. Like the Spherical Map type, this can produce less than perfect results. You may find it useful though. Fixing these two map types is currently being addressed.

 

The Texture Mapping Interface

Tmt.gif (4142 bytes)The three left-most icons serve two purposes. They are used to select the type of map desired and they also reset the values to defaults.

Planar - Exposes the Planar frame with default settings. (Seen at right).

Cylindrical - Exposes the Cylindrical frame with default settings.

Spherical - Exposes the Spherical frame with default settings.

The Overall Section - Sets some parameters that affect all settings.

Center - Clicking this icon will determine the center settings of all marked points and place the result in the X,Y and Z boxes in the Mapping frames. Note that the image shows a disabled icon. This is because there are no marked points. You should remember to mark the points of the polygons you wish to map to use this icon.

OK - Applies the texture map to the marked polygons and exits the Texture Mapping dialog.

Cancel - If you change your mind or find that you forgot to mark your polygons and points you can escape the mapping dialog with no changes.

 

The Overall Section

TM1_0.gif (3865 bytes)TM2_0.gif (4269 bytes)The image to the left shows the results of a Scaling setting of 1.00 with both U and V scaling set at 1.0. The cube is sized at 1.

The image to the right shows the results of a Scaling setting of 2.0.

The 2.0 setting has the effect of shrinking the texture by one half in the U and V dimensions, thus we have the equivalent of 4 textures in the space of one.

 

 

TM0_5.gif (2780 bytes)rot45.gif (5060 bytes)The image to the left demonstrates a setting 0.5. This results in a texture of 1/4 the size of normal.

To the right, a setting of 45 in Rotation setting shows what this parameter does.

 

 

 

 

Planar Mapping

Vscaldbl.gif (4837 bytes)Uscaldbl.gif (4657 bytes)V Scaling - This parameter sets the height of the texture. Increasing this setting will compress the texture from up to down allowing more texture to show. The pic to the left shows a U scaling of 1.0 and a V scaling of 2.0.

U Scaling - This sets the texture scaling width. A higher setting has the effect of squeezing the texture from side to side allowing more texture to show. The pic to the right shows the results of a U scaling of 2.0 with a V scaling of 1.0.

These two parameters should be left as is unless a texture needs to be stretched in one dimension only. Use the Scaling parameter in the Overall section for most texture sizing requirements. Later we will show a valuable use for the U and V scaling settings.

X Y and Z center - Sets the center point of the mapping. These should be set to the center of the object being texture mapped. Settings that differ from the center of the object being mapped can be used to produce different effects. When mapping objects that need an edge of the texture lined up with the edge of a polygon, often one setting will be set to match the coordinate of that polygons edge, with the other settings set to the center of the object.

ZYplane.gif (5085 bytes)XZplane.gif (5013 bytes)ZY Plane - The texture will be oriented based on the ZY Plane. If the robot is viewed from the side, as in the ZY view, you will see the texture pattern lined up straight on from this view. The example to the left shows the texture mapped with the ZY Plane checked. The texture pattern appears correct on the side of the cube but the top and front have a different effect called stretching.

XZ Plane - The texture will be oriented on the XZ Plane. If the robot is viewed from the top, as seen in the XZ view, you will see the texture pattern lined up straight on from this vantage point. In the example above and right, the texture was mapped with the XZ Plane checked. Notice that the front and sides are stretched but the top is correctly oriented.

TM1_0.gif (3865 bytes)wrap.gif (5179 bytes)XY Plane - The texture will be oriented based of the XY Plane. If the robot is viewed from the front, you will see the texture pattern lined up correctly. At left, the top and sides are stretched from front to back.

Stretching is the continuation of the texture at a 90 degree angle from the plane the map is based on. On large polygons, this effect tends to look somewhat undesirable. On small polygons this effect can be acceptable.

If the polygons are at an angle that differs from 90 degrees, the effect is more of a wrapping effect. The lower the angle difference, the more the wrapping effect. In the example at right, the XZ Plane button was checked, so the texture pattern lies on top of the polymodel. The angled surfaces show the wrapping effect while the sides that lie at a 90 degree angle from the top show the stretched effect. In this case, the stretching works well with the wrapped effect.

With a little understanding of the texture mapping controls, we can achieve the results we are after. With the number of controls we have at our disposal, these examples only demonstrate a small fraction of the possibilities. Experimentation combined with different textures can result in a large variety of looks.

 

Spherical Texture Mapping

This type of mapping tries to align all the textures from all angles, unlike the planar map which maps from the chosen plane only. The stretched effect seen in planar mapping is non existent in this type of map.spheri.gif (4990 bytes)

The Spherical Texture Mapping dialog contain a few bugs. What really happens is that the mapping process is alright except for a few polygons. These errant polygons can be aligned via the UV Vectors mode of the Object Browser and Alignment Display and in this way, this dialog can still save time from having to do all the texture alignment for each individual polygon one at a time. A fix is of course on the list for a future release.

I haven't worked with it enough to explain in a satisfactory fashion how to use this dialog for best results. But many of the parameters are the same as those used in the Planar Mapping dialog. Experiment with these settings to get a feel for it.

 

Cylindrical Texture Mapping

Cylindrical Texture Mapping can be thought of something like wrapping a a piece of paper around a tube. The paper represents the texture and the tube represents the marked polygons to be wrapped around. Most of the parameters are the same as Planar and Spherical Mapping except that an axis is used to determine the direction of the wrap. The X Axis would lay the "tube" oriented with the open ends each facing the left and right as seen in the XY view. The Y Axis would have the open ends of the tube facing up and down.cylindric.gif (4967 bytes)

As with Spherical Texture Mapping, the Cylindrical dialog is not yet reliable enough to produce a proper map over all polygons. There will be a polygon that needs aligning. This will be addressed in a future revision of Polytron.

Again, play with these settings to see what you can do with them.

 

 

nav_prev.gif (599 bytes)
Back
nav_stop.gif (644 bytes)
Contents
nav_next.gif (616 bytes)
Next

 

 

WebHits counts accesses on this page since 02/08/97. View detailed statistics!