anchor.diff:    end;
     PStBttPoint = ^TStBttPoint;
   
  -  TStBttPointArray = array[0..32767] of TStBttPoint;
  -  PStBttPointArray = ^TStBttPointArray;
  +  TStBttPointArray = Record
  +    List:Array Of TStBttPoint;
  +    Count:Integer;
  +  End;
   
     TStBttActiveEdge = Class(TERRAObject)
       x,dx: Integer;
  
positive.code:       end;
        contour_lengths[n] := NumPoints - start;
     end;
  
     Result := points;
  end;
  
  procedure TTFFont.stbtt_Rasterize(resultBitmap:Image; FlatnessInPixels: Single; Vertices: PStBttVertexArray; NumVerts: Integer; ScaleX, ScaleY, ShiftX, ShiftY: Single; XOff, YOff, Invert: Integer);
  var
    Scale: Single;
    WindingCount: Integer;
    WindingLengths: PIntegerArray;
    Windings: PStBttPointArray;
  begin
     Scale := Min(ScaleX, ScaleY);
  
     Windings := stbtt_FlattenCurves(Vertices, NumVerts, FlatnessInPixels / Scale, WindingLengths, WindingCount);
     if windings<>nil then
     begin
        stbtt__rasterize(resultBitmap, Windings, WindingLengths, WindingCount, ScaleX, ScaleY, ShiftX, ShiftY, XOff, YOff, Invert);
        //FreeMem(Windings);
     end;
  end;
  
  Procedure TTFFont.stbtt__rasterize(resultBitmap:Image; Pts: PStBttPointArray; WCount: PIntegerArray; Windings: Integer; ScaleX, ScaleY, ShiftX,ShiftY: Single; XOff, YOff, Invert: Integer);
  Var
    YScaleInv: Single;
    i,j,k,m, a,b, VSubSample: Integer;
    e: EdgeList;
    p: PStBttPointArray;
    en: TStBttEdge;
  Begin
     If Invert<>0 Then
      YScaleInv := -ScaleY
  
negative.code: 
                 x := vertices[i].x;
                 y := vertices[i].y;
                 stbtt__add_point(Result, NumPoints, x,y);
                 Inc(NumPoints);
              end;
  
              STBTT_vline:
              begin
                 x := vertices[i].x;
                 y := vertices[i].y;
                 stbtt__add_point(Result, NumPoints, x, y);
                 Inc(NumPoints);
              end;
  
              STBTT_vcurve:
              begin
                 stbtt__tesselate_curve(Result, NumPoints, x,y,
                                          vertices[i].cx, vertices[i].cy,
                                          vertices[i].x,  vertices[i].y,
                                          objspace_flatness_squared, 0);
  