Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Henry Wadsworth Longfello

What are UV Coordinates?

This topic is 5812 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I know that UV Coordinates are for coordinating vertically and horizontally on a bitmap, but for what? Why are they called "UV?" Could I make my own blender for texturing objects and not read anything about this UV system? What''s so special about them, and why on earth would you clamp their values to 1 ? Wouldn''t that leave you with indecisive places on a bitmap texture? why not make the coordinates from "bottom left" of the bitmap and say a clambing of 128X64 units, if those are the dimensions of the texture...

Share this post


Link to post
Share on other sites
Advertisement
UV Coordinates aren''t normal BMP coords.
when you change a value to 1.0f you''re not changing it to the
2nd pixel on the image/BMP, you''re changing it to the last pixel
on the image/BMP, i.e

int ImageWidth = 640;
int ImageHeight = 480;

float U = 0.5f; // this coordinate is refering to the 320th pixel (640 * 0.5 = 320)
float V = 1.0f; // this coordinate is refering to the 480th pixel (480 * 1.0 = 480)


Hope that helps...


KaMiKaZe

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
TANX!

Share this post


Link to post
Share on other sites
Also, using a value from 0 to 1 eases the problems when changing textures. For example, you can use a 32x32 texture at one moment, then switch it with a 256x256 texture without having to change the texture coordinates - those stay in the range of 0 to 1.

BTW - you don''t have to clamp to 1. Values over 1 typically signify wrapping. For example, a value of 2 means to repeat the texture twice when mapping.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!