Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 3 of 3

Thread: non power of two texture mipmaps

  1. #1
    Member Regular Contributor
    Join Date
    Dec 2007
    Posts
    250

    non power of two texture mipmaps

    testing my program on some older ATI cards (x1950 and some mobiles ones) i have major problems with non power of two textures and mipmaps.

    I am creating mipmaps like this

    glTexParameteri(GL_TEXTURE_2D, GL_GENERATE_MIPMAP, GL_TRUE);
    then
    glTexImage2D(etc)

    This works fine with nvidia .. but on ATI no mipmaps are generated and I get weird corruption with some of the textures. The ATI cards I've tested claim opengl 2.1 and specifically they list the extension

    GL_ARB_texture_non_power_of_two

    Which according to the spec

    When this extension is supported, mipmapping, automatic mipmap generation, and all the conventional wrap modes are supported for non-power-of-two textures
    So what gives ? Is this a known fuck up on ATI cards ? How can I handle this. I don't really want to revert back to using gluBuild2DMipmaps. I've tried using the FBO extension to generate mipmaps but that doesn't seem to work either.

  2. #2
    Advanced Member Frequent Contributor
    Join Date
    Apr 2003
    Posts
    652
    some older ATI cards (x1950 and some mobiles ones)
    Those cards are probably only supported on very old drivers with many bugs in them :-)

    Instead of using GL_GENERATE_MIPMAP you might also use
    glGenerateMipmapEXT() (if EXT_framebuffer_object is supported) or
    glGenerateMipmap() (if ARB_framebuffer_object is supported or GL3.0+)
    to explicitly generate the mipmaps.

  3. #3
    Member Regular Contributor
    Join Date
    Dec 2007
    Posts
    250
    EXT_framebuffer_object is supported,
    but no
    glGenerateMipmapEXT() doesn't work either

Posting Permissions

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