TRadialGradientRenderer

Ancestors

   |
TCustomRenderer
   |
TCustomGradientRenderer

uses Img32, Img32.Fmt.PNG, Img32.vector, Img32.Draw;
  ...
var
  rec: TRect;
  path: TPathD;
  rgr: TRadialGradientRenderer;
  img: TImage32;
begin
  img := TImage32.Create(256,256);
  rec := Rect(86,86, 170,170);
  path := Rectangle(img.Bounds);  
  rgr := TSvgRadialGradientRenderer.Create;
  rgr.SetParameters(rec, clFuchsia32, $FF3333FF, gfsMirror);
  rgr.InsertColorStop(0.3, clRed32);
  rgr.InsertColorStop(0.4, clYellow32);
  rgr.InsertColorStop(0.5, clYellow32);
  rgr.InsertColorStop(0.7, clLime32);
  rgr.InsertColorStop(0.8, clAqua32);
  DrawPolygon(img, path, frEvenOdd, rgr);
  DrawLine(img, path, 3, clMaroon32, esPolygon);
  img.SaveToFile('radial_gradient.png');
  rgr.Free;
  img.Free;
end;
    

Reference

Methods
In TRadialGradientRenderer:
Initialize
InsertColorStop
RenderProc
SetGradientFillStyle
SetParameters
In TCustomGradientRenderer:
Clear