Rectangle

function Rectangle(const rec: TRect): TArrayOfPointD; overload;

function Rectangle(const rec: TRectD): TArrayOfPointD; overload;

function Rectangle(l, t, r, b: double): TArrayOfPointD; overload;


This function returns the points representing the rectangle's 4 corners: top-left, top-right, bottom-right & bottom-left (in that order).

uses Image32, Image32_PNG, 
  Image32_Vector, Image32_Transform;
...
var
  img: TImage32;
  dst: TArrayOfPointD;
begin
  img := TImage32.Create;
  img.LoadFromFile('clouds.png');
  
  //setup the transformation geometry
  dst := Rectangle(src.Bounds); 
  dst[0].Y := 20;
  dst[3].Y := img.Height-20; 
  
  //transform and save
  ProjectiveTransform(img, dst);
  img.SaveToFile('clouds_proj.png');
  img.Free;
end;