AddImageTransparentFromFile
Image handling
Description
Adds an image from a file and immediately applies an RGB color-key transparency mask
Syntax
Delphi
Function TPDFlib.AddImageTransparentFromFile(Const FileName: WideString; FromRed, FromGreen, FromBlue, ToRed, ToGreen, ToBlue: Double; Options: Integer): Integer;
Parameters
| FileName | Image file to import |
|---|---|
| FromRed, FromGreen, FromBlue | Lower RGB color-key bound in the 0 to 1 range |
| ToRed, ToGreen, ToBlue | Upper RGB color-key bound in the 0 to 1 range |
| Options | Image import options passed to AddImageFromFile |
Return values
Returns the new ImageID, or 0 if the image import or mask assignment fails
Remarks
The helper keeps the new image selected and delegates mask construction to SetImageMask
See also
AddImageTransparentFromStream, AddImageTransparentFromString, SetImageMask