# uv coordinates

I have a question about uv coordinates. Just a reality check.

Typically, these coordinates are in the range of [0,1].

But in a particular model I see coordinates like 4.3 or 2.5 etc. There is a group in the model that might have 7 materials applied to it. Yet, these coordinates are outside of that range. When drawing should I always take the fractional remainder? Or is this a texture repeat kind of deal where its going to take the fraction for you? When I look at the model in my 3d model editor ( cheetah ) I see spaghetti in the uv and there is no way to unwrap. ( which is probably what god intended )

I think its a situation where the content creator made uv spaghetti. Makes it hard to edit the model or change anything etc. Triangles too. But sure looks nice.

Hmm, I think there is a texture rectangle involved. So, uv coords are not between [0,1]. That answers that question.

Captain obvious. Move along…

Hi, I think,I am sure that is texture repeat kind of deal.
please let me know if i am wrong.

OpenGL does that – texture repeat : taking the fraction – automatically. Refer to the specification for more detail. Hovewer, while I know nothign about modelling, I think it is a bad style to specify such coordinates on a model…

Maybe he’s using some kind of projective texturing where he specifies a projective matrix that transform those coordinates onto the texture, just like texture fetching a shadow map.

N.

Found most of my issues. Mainly the model.

Think your right about the repeat issue. The artist moved certain texture coordinate sets for different model groupings to different locations with offsets of 1. I guess its all repeating. Also, these texture uv sets overlap and form spaghetti which I could not unwrap if I wanted to.

First, in Cheetah, when I looked at the supplied uv coordinates they were all shifted off the unit square north by 1 unit – I assume this is the typical box with the range [0,1]. Maybe there was some kind of file conversion that did this. The odd part is it would render perfect in the raytrace of the model. I figure this is probably what most people want. Yet, in my application and in the modeler it would not render the textures in opengl. So, I selected all the uv coordinates and moved them south by one unit. Now the texture shows up in both applications! Most of the textures happened to be rectangles also.

Had to strip things down for my app. Reducing texture sizes and ripping out pieces of the model. Its for a game application. Still too big … must rip out more … ooga booga .