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: Loading Textures by glTexImage2D

  1. #1
    Junior Member Newbie
    Join Date
    Feb 2000
    Posts
    21

    Loading Textures by glTexImage2D

    Hi, ALL!

    Anyone now that glTexImage2D support different input and output data types, even GL_BGR_EXT and GL_BGRA_EXT for windows bitmap. But, does anyone know how use input data stored in 16 bits per pixel (555 or 565) without manually converting into supported type.

    Thanks.

  2. #2
    Intern Contributor
    Join Date
    Feb 2000
    Location
    Italy
    Posts
    79

    Re: Loading Textures by glTexImage2D

    Yes, you do it this way: check for the extension EXT_packed_pixel.
    If it's found use an internal_format of GL_RGB5_A1, or GL_RGBA4. Look the specs for more info/formats.
    Note that drivers without that ext, won't work with the mentioned formats.
    --
    Paolo M.

  3. #3
    Junior Member Newbie
    Join Date
    Feb 2000
    Posts
    21

    Re: Loading Textures by glTexImage2D

    Thanks, paolom!

    [This message has been edited by Mad Max (edited 02-17-2000).]

Posting Permissions

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