FMX.Graphics.TBitmapCodecManager.GetImageSize

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

class function GetImageSize(const AFileName: string): TPointF;

C++

__classmethod System::Types::TPointF __fastcall GetImageSize(const System::UnicodeString AFileName);

Properties

Type Visibility Source Unit Parent
function public
FMX.Graphics.pas
FMX.Graphics.hpp
FMX.Graphics TBitmapCodecManager

Description

Gets the size of an image read from a specified file.

Use GetImageSize to get the size of an image read from a file specified by the AFileName parameter.

GetImageSize returns a TPointF. TPointF.X is the width of the image and TPointF.Y is the height.

For TBitmapCodecManager, GetImageSize returns TPointF(0,0). The decoder for each different supported device overrides this method to evaluate and returns the size.

When calling GetImageSize, the method of the proper decoder will be called automatically.

See Also