Why are these UV mapping coordinates represented in 0-1 and pixels? Shouldn't they use only the 0-1 system?

StackOverflow https://stackoverflow.com/questions/3737043

Question

Well, I've got many UV coordinates of a 3D model clearly in the range 0-1 and many coords in seemingly pixel values in the range 100-300.

How do I know which one to interpret the coordinates as? Is there a standard or system for this?

I notice that each 3d meshes in the exported file may use either system. Is this normal procedure, and if so, how do I interpret the UV texture mapping coordinates to display them correctly in my 3d engine?

Examples of coordinates in the 0-1 system:

vt 1.04017 2.60853

vt -0.984585 -0.0106576

Examples of coordinates measuring by the pixel:

vt -208.397 776.637

vt -208.397 32.6369
Was it helpful?

Solution

What is the file format of your 3D model? Also note that it's perfectly valid to have UV mapping coordinates ranging outside 0-1, e.g. for wrap or repeat texturing modes (refer to OpenGL or Direct3D texturing mode).

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top