CreateBitmap method (ILEADRaster)

Visual Basic example

Visual C++ 5.0 example

Delphi 4 example

C++ Builder example

 

Syntax

short CreateBitmap (float fWidth, float fHeight, short iBitsPerPixel);

Overview

Refer to Copying and Creating Bitmaps.

Remarks

Initializes and allocates the bitmap, without loading any data.

If you specify 8 bits per pixel or less, the bitmap is created with LEAD's fixed palette. If you specify 0 bits per pixel, for grayscale, the bitmap is created as an 8-bit image with a grayscale palette. If you need to change the palette, refer to the ColorRes method.

Some image processing functions, such as the Rotate method and the ColorRes method need to re-allocate the image data. If you create a bitmap and pass it to these methods, they will change the bitmap to TYPE_CONV and re-allocate memory. So if you set your data using the SetBitmapDataPointer method it will no longer be used.

See Also

Topics

Raster Images: Creating and Deleting Images

 

Raster Images: Palettes