TBitmap.InitializeReader procedure
Initializes the image reader to use the transparency settings in the class instance.
Declaration
procedure InitializeReader(AImage: TLazIntfImage;
AReader: TFPCustomImageReader); overrideArguments
AImage | Provides access to the raw data for the image. |
AReader | Reader used to access raw data for the image. |
Description
InitializeReader is an overridden procedure used to apply
transparency settings to the image reader in
AReader.
InitializeReader calls the inherited method on entry to signal the
OnProgress event handler (when assigned).
InitializeReader ensures that AReader is derived from
TLazReaderBMP. No additional actions are performed in the method
when AReader is not a TLazReaderBMP class instance.
InitializeReader applies values from the TransparentMode and
TransparentColor properties to the mask settings in AReader.
TransparentMode
Determines whether the transparency color is auto-detected in the image data, or a fixed transparency color is used.
- tmAuto
- The bottom left pixel in the image data contains the transparency color.
- tmFixed
- Uses a predefined color in TransparentColor as the transparency color.
TransparentColor
Determines the color used to represent transparent areas in the image data.
- clDefault
- Uses the bottom left pixel as the transparency color. This is a Lazarus extension.
- clNone
- Ignores transparency in the image data. This is a Lazarus extension.
All other color constants represent the color for transparent pixels in the image.
Values in TransparentMode and TransparentColor are assigned to the MaskMode and MaskColor properties in AReader as required.
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
