ImageEn, unit iexBitmaps

TIOParams.JPEG_Scale_Used

TIOParams.JPEG_Scale_Used


Declaration

property JPEG_Scale_Used: Integer;


Description

Returns the denominator of the scale used to load the current Jpeg image (e.g. if it was loaded at 1/4 size, then 4 will be returned). It is used only when JPEG_Scale is ioJPEG_AUTOCALC.

Note: To get the actual size of the image use OriginalWidth and OriginalHeight

Default: 1


Example

ImageEnView1.IO.Params.LoadToWidth  := 150;
ImageEnView1.IO.Params.LoadToHeight := 100;
ImageEnView1.IO.Params.JPEG_Scale := ioJPEG_AUTOCALC;
ImageEnView1.IO.LoadFromFile('C:\my.jpg');
Case ImageEnView1.IO.Params.JPEG_Scale_Used of
  1: ShowMessage('Full-size');
  2: ShowMessage('Half-size');
  4: ShowMessage('Quarter-size');
  8: ShowMessage('Eighth-size');
end;