ImageEn, unit imageenview |
|
TImageEnView.ChangeResolution
Declaration
procedure ChangeResolution(NewDPI: Integer; ResampleFilter: TResampleFilter);
Description
Modifies the DPI of the image (
IO.Params.DpiX and
IO.Params.DpiY), resampling it and setting the new DPI values.
Note: You should ensure the source DPI contains valid values before calling ChangeResolution. This method has no effect if DPI is 0.
// load input.jpg which has 100 dpi
ImageEnView1.IO.LoadFromFile('C:\input.jpg');
// we want 75 dpi
ImageEnView1.ChangeResolution(75, rfTriangle);
// save back as 75 dpi
ImageEnView1.IO.SaveToFile('C:\output.jpg');