Description | Hierarchy | Fields | Methods | Properties |
type TImage = class(TReferenceCounted)
Interface for software image data.
Image loaders create these images from files. TVideoDrivers convert these images into their (hardware) textures.
![]() |
class function GetBitsPerPixelFromFormat(Format: TColorFormat): LongWord; inline; |
![]() |
function GetPixel(X, Y: LongWord): TARGBColor; inline; |
![]() |
class function IsRenderTargetOnlyFormat(Format: TColorFormat): Boolean; inline; |
![]() |
function Lock: Pointer; inline; |
![]() |
procedure CopyTo(Target: TImage; const Position: TPoint); overload; inline; |
![]() |
procedure CopyTo(Target: TImage); overload; inline; |
![]() |
procedure CopyTo(Target: TImage; const Position: TPoint; const SourceRect, ClipRect: TRect); overload; inline; |
![]() |
procedure CopyTo(Target: TImage; const Position: TPoint; const SourceRect: TRect); overload; inline; |
![]() |
procedure CopyToScaling(Target: TImage); overload; inline; |
![]() |
procedure CopyToScaling(Target: Pointer; Width, Height: LongWord; ColorFormat: TColorFormat = cfA8R8G8B8; Pitch: LongWord = 0); overload; inline; |
![]() |
procedure CopyToScalingBoxFilter(Target: TImage; Bias: LongInt = 0; Blend: BOolean = False); inline; |
![]() |
procedure CopyToWithAlpha(Target: TImage; const Position: TPoint; const SourceRect: TRect; Color: TARGBColor); overload; inline; |
![]() |
procedure CopyToWithAlpha(Target: TImage; const Position: TPoint; const SourceRect: TRect; Color: TARGBColor; const ClipRect: TRect); overload; inline; |
![]() |
procedure Fill(Color: TARGBColor); inline; |
![]() |
procedure SetPixel(X, Y: LongWord; Color: TARGBColor; Blend: Boolean = False); inline; |
![]() |
procedure Unlock; inline; |
![]() |
property AlphaMask: LongWord read GetAlphaMask; |
![]() |
property BitsPerPixel: LongWord read GetBitsPerPixel; |
![]() |
property BlueMask: LongWord read GetBlueMask; |
![]() |
property BytesPerPixel: LongWord read GetBytesPerPixel; |
![]() |
property ColorFormat: TColorFormat read GetColorFormat; |
![]() |
property GreenMask: LongWord read GetGreenMask; |
![]() |
property ImageDataBytes: LongWord read GetImageDataSizeInBytes; |
![]() |
property ImageDataPixels: LongWord read GetImageDataSizeInPixels; |
![]() |
property Pitch: LongWord read GetPitch; |
![]() |
property RedMask: LongWord read GetRedMask; |
![]() |
property Size: TSize read GetDimension; |
![]() |
class function GetBitsPerPixelFromFormat(Format: TColorFormat): LongWord; inline; |
Gets the number of Bits per Pixel of a given color format. |
![]() |
function GetPixel(X, Y: LongWord): TARGBColor; inline; |
![]() |
class function IsRenderTargetOnlyFormat(Format: TColorFormat): Boolean; inline; |
Test if a color format is only viable for RenderTarget textures. |
![]() |
function Lock: Pointer; inline; |
ReturnsPointer to the image data. What type of data is pointed to depends on the color format of the image. For example if the color format is cfA8R8G8B8, it is of LongWord. Be sure to call unlock() after you don't need the pointer any more. |
![]() |
procedure CopyTo(Target: TImage; const Position: TPoint); overload; inline; |
Copies the image to another one. Parameters
|
![]() |
procedure CopyTo(Target: TImage); overload; inline; |
Copies the image to another one. Parameters
|
![]() |
procedure CopyTo(Target: TImage; const Position: TPoint; const SourceRect, ClipRect: TRect); overload; inline; |
Copies a part of the image to another one. Parameters
|
![]() |
procedure CopyTo(Target: TImage; const Position: TPoint; const SourceRect: TRect); overload; inline; |
Copies a part of the image to another one. Parameters
|
![]() |
procedure CopyToScaling(Target: TImage); overload; inline; |
Copies the image to another one, scaling it to fit. Parameters
|
![]() |
procedure CopyToScaling(Target: Pointer; Width, Height: LongWord; ColorFormat: TColorFormat = cfA8R8G8B8; Pitch: LongWord = 0); overload; inline; |
Copies the image to raw memory, scaling it to fit. Parameters
|
![]() |
procedure CopyToScalingBoxFilter(Target: TImage; Bias: LongInt = 0; Blend: BOolean = False); inline; |
Copies the image to another one, scaling it to fit, applying a box filter. Parameters
|
![]() |
procedure CopyToWithAlpha(Target: TImage; const Position: TPoint; const SourceRect: TRect; Color: TARGBColor); overload; inline; |
Copies a part of the image to another one using the alpha mask. Parameters
|
![]() |
procedure CopyToWithAlpha(Target: TImage; const Position: TPoint; const SourceRect: TRect; Color: TARGBColor; const ClipRect: TRect); overload; inline; |
Copies a part of the image to another one using the alpha mask. Parameters
|
![]() |
procedure Fill(Color: TARGBColor); inline; |
Fills the image with a single color. Parameters
|
![]() |
procedure SetPixel(X, Y: LongWord; Color: TARGBColor; Blend: Boolean = False); inline; |
Sets a single pixel. Parameters
|
![]() |
procedure Unlock; inline; |
|
![]() |
property AlphaMask: LongWord read GetAlphaMask; |
The image's alpha channel mask. |
![]() |
property BitsPerPixel: LongWord read GetBitsPerPixel; |
The number of bits representing a single pixel. |
![]() |
property BlueMask: LongWord read GetBlueMask; |
The image's blue channel mask. |
![]() |
property BytesPerPixel: LongWord read GetBytesPerPixel; |
Like BitsPerPixel, but returns the size in bytes. |
![]() |
property ColorFormat: TColorFormat read GetColorFormat; |
The image's color format. |
![]() |
property GreenMask: LongWord read GetGreenMask; |
The image's green channel mask. |
![]() |
property ImageDataBytes: LongWord read GetImageDataSizeInBytes; |
The raw image data's size in bytes. |
![]() |
property ImageDataPixels: LongWord read GetImageDataSizeInPixels; |
The image data size in pixels. |
![]() |
property Pitch: LongWord read GetPitch; |
![]() |
property RedMask: LongWord read GetRedMask; |
![]() |
property Size: TSize read GetDimension; |
The image's width and height in pixels. |