PDA

View Full Version : Don't UV coordinates have 'resolution' issues too?


googlo
10-20-2002, 04:56 AM
I've started to learn about UV coordinates for texturing and had some questions:

Are UV coordinates 1:1 with the vertices that make up the model or is that only true for vertex color channels?

Is each vertex an 'anchor' point where each UV coordinate is stored as well, and in between the coordinates along the surface of the model intermediate UV coordinates are interpolated between them (or is this only applicable to vertex color channels as well)?

For the area that is mapped is it always 'stretching' a normalized space of [0,0],[0,1],[1,1],[1,0] over the entire regions, regardlesss of the size? And if that is th case, wouldn't this mean that the larger the surface area you are mapping uv coordinates over, the more reduced the resolution of the uv space along the surface of the object is?

Texels kind of confuse me because they are related in description in manner to pixels.

Are texels basically like a unit of resolution on the surface of an object in which maps are mapped too? Like the higher the texels across the surface of an object, the better the resolution of the map on the surface of the object? so would a low resolution texel object in a scene display a blocky version of a texture mapped across it's surface even if the texture were high resolution? How can you control the density of texels on an object? With UV info? I thought UV info was fixed over a 0->1 information range, regardless of the size of the object the UV mapping is being applied to.

leigh
10-22-2002, 12:00 PM
Yes, yes, and yes :)
But I'm not entirely sure what you are wanting to find out?

Because of the way in which UVs are sampled, they are technically inferior to normal projections, for the reasons that you have mentioned.

But that is why it is important to edit your UVs, so that you eliminate stretching and distortion within the UV map itself.

Unfortunately I don't really know anything about texels, so I can't comment on those... Perhaps you should look on a gaming site or something for that kind of info :)

CG.p
10-30-2002, 06:40 AM
Originally posted by googlo
And if that is th case, wouldn't this mean that the larger the surface area you are mapping uv coordinates over, the more reduced the resolution of the uv space along the surface of the object is?

That is tricky. uv rez is limited by what you feed it. You can have to verts rally close to each other and still feed it a 4096 x 4096 image and get a bunch of detail there.

Without looking at all the variables it is almost like saying that an object modeled to be 1mm tall will exibit stretch too.

Tricky questions get tricky answers. :)

googlo
10-30-2002, 07:10 AM
Thanks Leigh and CG :)

EricChadwick
10-31-2002, 08:15 PM
Pixels = the little squares of solid color that make up a bitmap. Also the little squares of screen elements that make up your monitor.
Texels = distorted versions of the bitmap pixels when they're being rendered on a 3D surface. Texels do not control pixels... the word is just a way to describe what happens to pixels on a 3D surface.

>>Are UV coordinates 1:1 with the vertices that make up the model or is that only true for vertex color channels? Is each vertex an 'anchor' point where each UV coordinate is stored as well, and in between the coordinates along the surface of the model intermediate UV coordinates are interpolated between them (or is this only applicable to vertex color channels as well)?


You got it right. UVs are stored in the vertices. A square polygon has coords only in the four corners, since there's only four vertices. If the UV exactly fits the square, then on the left side of the square U would be 0, halfway across U would be 0.5, and at the right side U would be 1.

There are as many intermediate values across the square as your 3D program will allow with its limited amount of precision. Regardless of the size of the square, the values are always interpolated the same... well except if the 3D program has precision problems with really huge objects or really small objects.

UVs can be "tiled" in that one end of the square can be U=0, and the other end U=16, so the bitmap will be repeated across the surface 16 times. Or they can be clipped, so you might have a range of U=.25 to U=.5, making only 1/4 of the bitmap visible on the square.

UV coordinates can be thought of like vectors... they can scale without loss of resolution.
Pixels/texels are different. They lose resolution when scaled.

Hope that helps.

EricChadwick
10-31-2002, 08:19 PM
Though of more info to add...

If your bitmap is 100 pixels wide, and if U is a range of 0 - 16 across your square polygon, then you have 1600 texels across the polygon. Which represents your 100 bitmap pixels being tiled (repeated) 16 times.

If the U is a range of .25 - .5, then you have 25 texels across, representing 25 pixels from the bitmap.

CGTalk Moderation
01-13-2006, 08:00 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.