ClientToBitmap example for Delphi

procedure TForm1.LEADRasterView1MouseDown (Sender: TObject; Button,
  Shift: Smallint; x, y: Single);
var
   sRet: Smallint;
   BitmapX: Single;
   BitmapY: Single;

begin
   BitmapX:= x;
   BitmapY:= y;
   LEADRasterView1.ClientToBitmap (BitmapX, BitmapY, sRet);
   //Change that pixel to White
   LEADRasterView1.Raster.Pixel [LEADRasterView1.ConvertX, LEADRasterView1.ConvertY]:= RGB(255, 255, 255);
end;