Loading an image into memory using OpenGL

This is a discussion on Loading an image into memory using OpenGL within the C++ Programming forums, part of the General Programming Boards category; Hi there, I am having some difficulty with loading an image into memory (for texture mapping) with OpenGL. I've tried ...

  1. #1
    Registered User
    Join Date
    Feb 2005
    Posts
    44

    Loading an image into memory using OpenGL

    Hi there,

    I am having some difficulty with loading an image into memory (for texture mapping) with OpenGL.

    I've tried

    Code:
    value = auxDIBImageLoad(Filename);
    But I'm not sure - it seems as though this function has become deprecated or something? As far as I know, it used to be a valid way of loading a texture.

    Has anybody else encountered this problem? Is there a simple substitution I can make?

    Thanks for any help!

    -Edit-
    The error I'm getting is a linker error. "Unresolved external...."

  2. #2
    Registered User
    Join Date
    Feb 2005
    Posts
    5
    I always use the glTexImage2D() or gluBuild2DMipmaps() functions to generate textures. You just have to handle loading the image and converting it into a format these functions can use is all. This is really the only way I know of doing it, so it's the only way I can recommend.

  3. #3
    Registered User
    Join Date
    Feb 2005
    Posts
    44
    Great, I'll give that a shot

    Thanks!

  4. #4
    Registered User
    Join Date
    Feb 2005
    Posts
    44
    Hmm, after going through my code (I'm very new to OpenGL) it looks like those functions are not where my problem is - I'm using them as well. It's the

    Code:
    auxDIBImageLoad(Filename);
    function that actually grabs the file from the disk that I am having my dilemma with.

    I've searched everywhere and can't find ANYTHING. Apparently learning OpenGL is something best done in a school environment

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Loading process from memory
    By X PaYnE X in forum Windows Programming
    Replies: 15
    Last Post: 05-03-2009, 04:34 PM
  2. tools for finding memory leaks
    By stanlvw in forum C++ Programming
    Replies: 4
    Last Post: 04-03-2009, 11:41 AM
  3. To find the memory leaks without using any tools
    By asadullah in forum C Programming
    Replies: 2
    Last Post: 05-12-2008, 07:54 AM
  4. Why only 32x32? (OpenGL) [Please help]
    By Queatrix in forum Game Programming
    Replies: 2
    Last Post: 01-23-2006, 01:39 PM
  5. Linking OpenGL in Dev-C++
    By linkofazeroth in forum Game Programming
    Replies: 4
    Last Post: 09-13-2005, 10:17 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21