PDA

View Full Version : Radeon Texture filtering problem



DaManu
06-05-2003, 09:12 AM
Hi!
i have a strange problem:
When i use multitexturing on a Radeon 9500
and zoom very near to a polygon, or use very
large polygons, the texel's aren't proper filtered. On a GF2 its looking good.

thanks

dorbie
06-05-2003, 10:24 AM
This depends on the exact nature of the visual artifacts you are seeing, but different implementations will have different precision in their coordinate interpolators, I suspect that your problem is related to this.

Other things can affect this in my experience, for example the precision of any clipping interpolation etc. I once looked at this in great detail and it's not always simple to figure out where your problem lies without detailed knowledge of the hardware.

One suggestion I have is that if you are *tiling* texture on a large polygon, try dividing the polygon up into smaller tiles instead of relying excessively on texture repeat filtering.


[This message has been edited by dorbie (edited 06-05-2003).]

Sephiroth
06-05-2003, 09:04 PM
Your problem is the Radeon. They are not 100% GL-compliant. I suggest getting a good freeware GL-wrapper for you Radeon. That is what made it possible for a friend of mine to use OpenGL in his games and such. He ditched his Radeon shortly thereafter and got a GF4 and has had no problems since. On a side note, the Radeon did give him an advantage in UT at times. It wouldn't z-buffer (maybe it drew something in the wrong order also) properly and sometimes you could see actors (players, guns, health, etc) through the walls and such.

DaManu
06-05-2003, 10:43 PM
@dorbie: if i subdivide the surface there is
no difference. http://www.opengl.org/discussion_boards/ubb/frown.gif
i'am operating in a relatively "normal"
range.

The texture is looking something like
this, instead of beeing proper blured together.

aaaaa______
_____|_aaaa|____
|aaaax|aaax|aaaa| (sorry, not the best
|aaaax|aaax|aaaa| (ascii art http://www.opengl.org/discussion_boards/ubb/smile.gif
|aaaax|aaax|aaaa|
-------____|-----

I thought the Radeon has meantime good
opengl drivers, thats bad.


[This message has been edited by DaManu (edited 06-06-2003).]

[This message has been edited by DaManu (edited 06-06-2003).]

Lev
06-09-2003, 01:15 PM
Originally posted by Sephiroth:
Your problem is the Radeon. They are not 100% GL-compliant.
....
....

Nonsense

DaManu
06-12-2003, 08:07 AM
Does anyone know a solution or work around
for this problem? I have tried anisotropic
filtering but it doesnt matter. Are there
any texture modulations i should avoid?
my current code is that:

glActiveTextureARB(GL_TEXTURE0_ARB);
glenable(GL_TEXTURE_2D);
glBindTexture(GL_TEXTURE_2D,tex[21]);
glTexEnvf(GL_TEXTURE_ENV,GL_TEXTURE_ENV_MODE,GL_CO MBINE_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_COMBINE_RGB_EXT,GL_REP LACE);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE0_RGB_EXT,GL_TEX TURE);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND0_RGB_EXT,GL_SR C_COLOR);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE1_RGB_EXT,GL_PRE VIOUS_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND1_RGB_EXT,GL_SR C_COLOR);
// alpha
glTexEnvf(GL_TEXTURE_ENV,GL_COMBINE_ALPHA_EXT,GL_A DD_SIGNED_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE0_ALPHA_EXT,GL_T EXTURE);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND0_ALPHA_EXT,GL_ SRC_ALPHA);

glActiveTextureARB(GL_TEXTURE1_ARB);
glEnable(GL_TEXTURE_2D);
glBindTexture(GL_TEXTURE_2D,tex[22]);
glTexEnvf(GL_TEXTURE_ENV,GL_TEXTURE_ENV_MODE,GL_CO MBINE_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_COMBINE_RGB_EXT,GL_REP LACE);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE0_RGB_EXT,GL_PRE VIOUS_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND0_RGB_EXT,GL_SR C_COLOR);
// alpha
glTexEnvf(GL_TEXTURE_ENV,GL_COMBINE_ALPHA_EXT,GL_A DD_SIGNED_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE0_ALPHA_EXT,GL_T EXTURE);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND0_ALPHA_EXT,GL_ ONE_MINUS_SRC_ALPHA);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE1_ALPHA_EXT,GL_P REVIOUS_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND1_ALPHA_EXT,GL_ SRC_ALPHA);

glActiveTextureARB(GL_TEXTURE2_ARB);
glEnable(GL_TEXTURE_2D);
glBindTexture(GL_TEXTURE_2D,tex[22]);
glTexEnvf(GL_TEXTURE_ENV,GL_TEXTURE_ENV_MODE,GL_CO MBINE_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_COMBINE_RGB_EXT,GL_REP LACE);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE0_RGB_EXT,GL_PRE VIOUS_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND0_RGB_EXT,GL_SR C_COLOR);
// alpha
glTexEnvf(GL_TEXTURE_ENV,GL_COMBINE_ALPHA_EXT,GL_A DD_SIGNED_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE0_ALPHA_EXT,GL_T EXTURE);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND0_ALPHA_EXT,GL_ ONE_MINUS_SRC_ALPHA);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE1_ALPHA_EXT,GL_P REVIOUS_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND1_ALPHA_EXT,GL_ SRC_ALPHA);

glActiveTextureARB(GL_TEXTURE3_ARB);
glEnable(GL_TEXTURE_2D);
glBindTexture(GL_TEXTURE_2D,tex[22]);
glTexEnvf(GL_TEXTURE_ENV,GL_TEXTURE_ENV_MODE,GL_CO MBINE_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_COMBINE_RGB_EXT,GL_REP LACE);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE0_RGB_EXT,GL_PRE VIOUS_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND0_RGB_EXT,GL_SR C_COLOR);
// alpha
glTexEnvf(GL_TEXTURE_ENV,GL_COMBINE_ALPHA_EXT,GL_A DD_SIGNED_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE0_ALPHA_EXT,GL_T EXTURE);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND0_ALPHA_EXT,GL_ ONE_MINUS_SRC_ALPHA);
glTexEnvf(GL_TEXTURE_ENV,GL_SOURCE1_ALPHA_EXT,GL_P REVIOUS_EXT);
glTexEnvf(GL_TEXTURE_ENV,GL_OPERAND1_ALPHA_EXT,GL_ SRC_ALPHA);

but even with a simplier modulation
(without alpha) it looks ugly...