Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Page 1 of 2 12 LastLast
Results 1 to 10 of 14

Thread: Strange Radeons

  1. #1
    Junior Member Regular Contributor
    Join Date
    Feb 2001
    Location
    UK
    Posts
    138

    Strange Radeons

    Hello

    I'm having some problems with cubemapping on radeon cards (8500).
    When I use the 0 cubemap (when you bind with 0 as texture object) I seem to get black borders at the edges of the cubemap faces.
    You can see it in action at http://studwww.rug.ac.be/~cholleme/lines.jpg
    I'm using GL_CLAMP as GL_TEXTURE_WRAP_(S/T) param.
    "The" problem now is that it looks perfectly normal on NVIDIA cards but all radeon users seem to experience this.
    (Also if anyone has an idea why this is caused on radeon http://studwww.rug.ac.be/~cholleme/seethrough.jpg
    It seems my depth fill pass is just skipped for some objects and only my light acummulation pass is done, again perfectly normal on nv cards.)

    Charles


    [This message has been edited by Pentagram (edited 08-25-2002).]

  2. #2
    Advanced Member Frequent Contributor
    Join Date
    Jun 2001
    Location
    Denmark
    Posts
    748

    Re: Strange Radeons

    Use should use CLAMP_TO_EDGE for cubemaps. The Radeons actually do it the correct way, NVIDIA does not ( a choice they made to support "broken but popular" apps ).

  3. #3
    Junior Member Regular Contributor
    Join Date
    Jun 2001
    Posts
    198

    Re: Strange Radeons

    Originally posted by Pentagram:
    Hello

    I'm having some problems with cubemapping on radeon cards (8500).
    When I use the 0 cubemap (when you bind with 0 as texture object) I seem to get black borders at the edges of the cubemap faces.
    You can see it in action at http://studwww.rug.ac.be/~cholleme/lines.jpg
    I'm using GL_CLAMP as GL_TEXTURE_WRAP_(S/T) param.
    If you want proper filtering at the cubemap edge (i.e. filtering texels from different faces), you have to download the cubemap with borders and replicate in the border texels the texels from the neighbour faces.

  4. #4
    Advanced Member Frequent Contributor
    Join Date
    Jun 2001
    Location
    Denmark
    Posts
    748

    Re: Strange Radeons

    The artifacts he's seeing is from using GL_CLAMP with his normalization cubemap, right Charles ? I had the same artifacts when I tried an old test ( using ARB extensions ) on a Radeon . It was initially developer on a GeForce1.

  5. #5
    Junior Member Regular Contributor
    Join Date
    Jun 2001
    Posts
    198

    Re: Strange Radeons

    Originally posted by PH:
    The artifacts he's seeing is from using GL_CLAMP with his normalization cubemap, right Charles ? I had the same artifacts when I tried an old test ( using ARB extensions ) on a Radeon . It was initially developer on a GeForce1.
    Sure, using GL_CLAMP_TO_EDGE is a partial solution. I'm just telling him that if he needs proper inter cubemap face filtering, he has to use a cubemap with borders.
    Clamping to the edge may be the solution you applied, but the real solution is to provide a cubemap with borders so the filtering of adjacent faces is done properly (otherwise you are changing the way you calculate the value at the border, with regard of the way you calculate the value at non-border texels). Don't you think?

  6. #6
    Advanced Member Frequent Contributor
    Join Date
    Jun 2001
    Location
    Denmark
    Posts
    748

    Re: Strange Radeons

    Yes, I agree.

    EDIT: CLAMP_TO_EDGE is sufficient for this particular case though.

    [This message has been edited by PH (edited 08-25-2002).]

  7. #7
    Junior Member Regular Contributor
    Join Date
    Feb 2001
    Location
    UK
    Posts
    138

    Re: Strange Radeons

    Tnks for all the suggestions.
    Well I don't really know what cubemap is causing the error, I use 2 cubemaps "per pixel", one normalization cubemap and one "light filter" cubemap (the light filter thing is what that huge discussion was about, call it a shadow map, a light map whatever)
    I somehow supposed it was my light filter cubemap (from the way the lines are positioned on my sufaces) but now you mention it it may also be the normalization cubemap.
    Anyway all my cubemaps use CLAMP_TO_EDGE now. (hope this fixes the line problem at least)
    And why doesn't nvidia fix that those old apps are not my problem, those 10's of people who mailed me about radeon problems are.

    Charles

  8. #8
    Senior Member OpenGL Guru Humus's Avatar
    Join Date
    Mar 2000
    Location
    Stockholm, Sweden
    Posts
    2,444

    Re: Strange Radeons

    Originally posted by evanGLizr:
    Clamping to the edge may be the solution you applied, but the real solution is to provide a cubemap with borders so the filtering of adjacent faces is done properly (otherwise you are changing the way you calculate the value at the border, with regard of the way you calculate the value at non-border texels). Don't you think?
    I'd guess in 99% of the cases the difference isn't discernable. I'm not sure how widely cubemap borders are supported in hardware either.

  9. #9
    Advanced Member Frequent Contributor
    Join Date
    Jun 2001
    Location
    Denmark
    Posts
    748

    Re: Strange Radeons

    I have one more suggestion - I think it's safer to use glGenTextures rather than to bind to 0. In fact, if I remember correctly id = 0 is somewhat special, meaning "no texture" ( don't quote me on that ).
    Maybe that'll fix the other problem you have ( you never know ).

    I'll try your q1 mod and see if I can find something ( I have a Radeon 8500 ).

  10. #10
    Advanced Member Frequent Contributor
    Join Date
    Jun 2001
    Location
    Denmark
    Posts
    748

    Re: Strange Radeons

    Hmm, strange. You should change your 'nudge' value to 0.995 ( or thereabouts ). The one that Cass originally used doesn't work on Radeon 8500 ( the value is too small, so there'll be some shadow artifacts ).

    The volumetric particle smoke is awesome btw.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •