LBitmapBase::GetFixedPalette

#include "ltwrappr.h"

virtual L_INT LBitmapBase::GetFixedPalette(pPalette, nBitsPerPixel)

Retrieves a LEAD fixed palette, based on the bits per pixel.

Parameters

LPRGBQUAD pPalette

Pointer to an array of RGBQUAD structures that will be filled with the LEAD fixed palette. This array must be 256 elements.

L_INT nBitsPerPixel

Number of bits per pixel. This value is used to determine the palette to retrieve.

Returns

Value Meaning
SUCCESS The function was successful.
< 1 An error occurred. Refer to Return Codes.

Comments

Use this function to get the LEAD fixed palette for a specific bits per pixel. You can specify 0 bits per pixel to create an 8-bit grayscale palette.

Required DLLs and Libraries

Platforms

Win32, x64.

See Also

Functions

Topics

Example

L_INT LBitmapBase__GetFixedPaletteExample() 
{ 
 
   RGBQUAD  FixedPalette[256]; 
   LBitmapBase MyBitmap; 
 
   if(MyBitmap.GetFixedPalette( FixedPalette, 8)==SUCCESS) 
   { 
      //do something with the returned palette 
   } 
 
   return SUCCESS; 
} 
Help Version 21.0.2021.7.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C++ Class Library Help

Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.