DbLoadImage

Syntax
void dbLoadImage ( char* szFilename, int iImage ) void dbLoadImage ( char* szFilename, int iImage, int iFlag )

Usage
dbLoadImage loads a bmp, jpg, tga, dds, dib, or png image into memory and associates it with an image number. It does not display the image on the screen.

Filename is the name of the file containing the image. It can be just a file name if the file is in the project directory or it can be a complete path.

ImageNumber is a number that you assign to the image, an integer 1 through 65,535, which is used to identify the image in later operations.

Example: dbLoadImage(" MyPicture. bmp", 1); This statement loads the image stored in MyPicture. bmp and assigns it the image number 1.

After you have loaded an image using dbLoadImage, you can display it with dbPasteImage. The format is: dbPasteImage( ImageNumber, X, Y, Transparency);

Loaded images can also be used as textures. Applying an iFlag of 0 will treat the image as a texture.