Home Products Download Order Contacts


Subject: texture mapping distortion

I have the following code to texture map a triangle face. I know its a known
problem that distortion occurs when the number of triangles is low, however
Im not clear on how to modify the existing code in order to correct it.
Also, is it more of a performance hit to correct it, as opposed to just
increasing the number of triangles? Do I need to modify the actual vertices
of the triangle, or just the uv coordinates?

The code is actionscript, hopefully it will be clear. basically the
beginBitmapFill method takes an array of bitmap data and a matrix object for
transformation. It then fills the shape defined by the moveTo, lineTo
coordinates. Please let me know if I need to provide other code, such as the
transformation of vertices to screen coords, or anything else.


var w = myBitmapData.width;
var h = myBitmapData.height;


View All Messages in comp.graphics.algorithms



Copyright 2006 WatermarkFactory.com. All Rights Reserved.