PDA

View Full Version : Affine/Linear Texture Mapping



01-24-2001, 05:24 PM
Is there any way to specify what algorithm opengl uses to texture map a texture onto an object? I would like to use Affine Texture mapping, but it looks like opengl only supports some form of perspective texture mapping. Any ideas?

coco
01-24-2001, 08:47 PM
It does perspective-correct texture mapping and plain texture mapping.as far as I know. I guess that the exact way of doing it is implementation dependent, since the spec doesn't specify more.

j
01-25-2001, 06:34 AM
You can give it a hint to do affine texture mapping.




glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_FASTEST);


On some implementations this will give you affine texture mapping, on others it won't. Use GL_NICEST to ask for perspective correct texture mapping.

j

coco
01-25-2001, 10:16 AM
What is exactly affine texture mapping?

Serge K
01-26-2001, 12:39 AM
Linear texture coords. interpolation, no perspective correction.

Humus
01-26-2001, 04:34 AM
Why would one want that? It's not gonna be faster ...

coco
01-26-2001, 05:23 AM
"What is exactly affine texture mapping?"
"Linear"
I thought it was something new (english is not my native language).

Hummus:
Its faster only in software implementations. I'm 99% shure that no video card 2 years old or less will accelerate a bit by using linear texture mapping.

[This message has been edited by coco (edited 01-26-2001).]