public DrawLine(IList <ScreenPoint> points, OxyColor stroke, double thickness, double[] dashArray, LineJoin lineJoin, bool aliased, DrawLineType type) { Points = points; Stroke = stroke; Thickness = thickness; DashArray = dashArray; LineJoin = lineJoin; Aliased = aliased; }
public static void DrawLine(Vertex2D p1, Vertex2D p2, AddPixelHandler handler, DrawLineType drawType, ZTestHandler zTest) { switch (drawType) { case DrawLineType.DDA: DrawDDALine(p1, p2, handler, zTest); break; case DrawLineType.Bresenham: DrawBresenhamLine(p1, p2, handler, zTest); break; } }
public static Polyline Draw(this Polyline line, Canvas canvas, DrawLineType type) { switch (type) { case DrawLineType.HorizontalBottom: line.DrawBottomHorizontal(canvas); break; case DrawLineType.HorizontalMiddleLeft: line.DrawMiddleLeftHorizontal(canvas); break; case DrawLineType.HorizontalMiddleRight: line.DrawMiddleRightHorizontal(canvas); break; case DrawLineType.HorizontalTop: line.DrawTopHorizontal(canvas); break; case DrawLineType.ObliqueLeftBottom: line.DrawObliqueLeftBottom(canvas); break; case DrawLineType.ObliqueLeftTop: line.DrawObliqueLeftTop(canvas); break; case DrawLineType.ObliqueRightBottom: line.DrawObliqueRightBottom(canvas); break; case DrawLineType.ObliqueRightTop: line.DrawObliqueRightTop(canvas); break; case DrawLineType.VerticalBottomLeft: line.DrawVerticalLeftBottom(canvas); break; case DrawLineType.VerticalBottomMiddle: line.DrawVerticalMiddleBottom(canvas); break; case DrawLineType.VerticalBottomRight: line.DrawVerticalRightBottom(canvas); break; case DrawLineType.VerticalTopLeft: line.DrawVerticalLeftTop(canvas); break; case DrawLineType.VerticalTopMiddle: line.DrawVerticalMiddleTop(canvas); break; case DrawLineType.VerticalTopRight: line.DrawVerticalRightTop(canvas); break; default: break; } return(line); }