View Full Version : What's the DIB file?

08-22-2001, 06:07 PM
When I use an OPENGL software to do the texture mapping, the software tell me that it initializes a texture map from a dib file.I want to make a texture map for the application it used.So could you explain me what is the DIB file.
And could you tell me where can I find the introduction about the functions with aux at first?Thanks.

08-23-2001, 03:28 AM
Originally posted by tnt100:
So could you explain me what is the DIB file

As stated in Charles Petzold's book

"The DDB (device-dependent bitmap) is inadequate for the purpose of image interchange because the format of the bitmap bits is highly device-dependent. There is no color table in a DDB that specifies a correspondence between the bitmap bits and color. The DDB makes sense only when it is created and destroyed within the lifetime of a Windows session.

The device-independent bitmap (or DIB) was introduced in Windows 3.0 to provide a sorely needed image file format suitable for interchange. As you may know, other image file formats, such as .GIF or .JPEG, are much more common than DIB files on the Internet. This is mostly because the .GIF and .JPEG formats implement compression schemes that significantly reduce downloading time. Although there is a compression scheme defined for DIBs, it is rarely used. The bitmap bits in most DIBs are almost always uncompressed. This is actually a major advantage if you want to manipulate the bitmap bits in your program. Unlike .GIF and .JPEG files, the DIB is directly supported by the Windows API. If you have a DIB in memory, you can supply pointers to that DIB as arguments to several functions that let you display the DIB or convert it into a DDB."

So Basicly DIB is just a Bitmap

Originally posted by tnt100:
could you tell me where can I find the introduction about the functions with aux at first

Sorry but I myslef am new to OpenGL and don't know the Auxiliary Library much.

hope it helps...

[This message has been edited by Akash (edited 08-23-2001).]

08-23-2001, 04:41 AM
i would suggest looking at several tutorial websites, for one: http://nehe.gamedev.net
there are several more, but this site has become _the_ place to be for beginners. i believe tutorial #6 is the introduction to texture mapping.
and as far as aux is concerned, it may be not worth the effort to start with when glut is around. glut does all the aux stuff you need with minimal (subjective word, i know) changes to your code if you already set up a project using aux exclusively.