public Circle(Point c, int r, FormPaint form) { f = form; graphicType = "Circle"; center = c; radius = r; points = Points(); }
public Ellipse(Point c, int x, int y, FormPaint form) { f = form; graphicType = "Ellipse"; center = c; rx = x; ry = y; points = Points(); }
public DashedRectangle(int tx, int ty, int w, int h, FormPaint form) { f = form; graphicType = "DashedRectangle"; x = tx; y = ty; width = w; height = h; points = Points(); }
// 多边形的几个顶点 public Polygon(List <Point> lp, FormPaint form) { f = form; graphicType = "Polygon"; // 由于我们的多边形在构造时是单击记录一个顶点 // 最后一个顶点是以双击来记录的 // 但是这样子经常会导致最后一个点被记录两次,具体原因我还没搞清楚 // 因此为了避免之后的裁剪出现问题,我们在这里就要清除重复的点 // make a deep copy of the list vertices = Helper.RemoveDuplicatedPoint(lp); // 多边形边界上的点 points = Points(); }
public BresenhamLine(Point pa, Point pb, FormPaint form) : base(pa, pb) { graphicType = "Bresenham"; f = form; points = Points(); }
public BresenhamLine(List <Point> lp, FormPaint form) : base(lp) { graphicType = "Bresenham"; f = form; points = Points(); }
public Block(List <Point> l, FormPaint form) { f = form; graphicType = "Block"; points = l; }
public Bspline(List <Point> lp, FormPaint form) : base(lp) { graphicType = "Bspline"; f = form; }
public Bezier(List <Point> lp, FormPaint form) : base(lp) { graphicType = "Bezier"; f = form; }
public DDALine(Point pa, Point pb, FormPaint form) : base(pa, pb) { graphicType = "DDA"; f = form; points = Points(); }
public DDALine(List <Point> lp, FormPaint form) : base(lp) { graphicType = "DDA"; f = form; points = Points(); }