C# Class Renderer.SkiaSharp.SkiaRenderer

Native SkiaSharp shape renderer.
Inheritance: Core2D.Renderer.ShapeRenderer
显示文件 Open project: Core2D/Core2D Class Usage Examples

Public Methods

Method Description
ClearCache ( bool isZooming ) : void
Create ( ) : ShapeRenderer

Creates a new SkiaRenderer instance.

Draw ( object dc, XArc arc, double dx, double dy, ImmutableArray db, XRecord r ) : void
Draw ( object dc, XCubicBezier cubicBezier, double dx, double dy, ImmutableArray db, XRecord r ) : void
Draw ( object dc, XEllipse ellipse, double dx, double dy, ImmutableArray db, XRecord r ) : void
Draw ( object dc, XImage image, double dx, double dy, ImmutableArray db, XRecord r ) : void
Draw ( object dc, XLine line, double dx, double dy, ImmutableArray db, XRecord r ) : void
Draw ( object dc, XPath path, double dx, double dy, ImmutableArray db, XRecord r ) : void
Draw ( object dc, XQuadraticBezier quadraticBezier, double dx, double dy, ImmutableArray db, XRecord r ) : void
Draw ( object dc, XRectangle rectangle, double dx, double dy, ImmutableArray db, XRecord r ) : void
Draw ( object dc, XText text, double dx, double dy, ImmutableArray db, XRecord r ) : void
Fill ( object dc, double x, double y, double width, double height, ArgbColor color ) : void
SkiaRenderer ( bool isAntialias = true, double targetDpi = 72.0 ) : System

Initializes a new instance of the SkiaRenderer class.

Private Methods

Method Description
CreateRect ( XPoint tl, XPoint br, double dx, double dy, float>.Func scale ) : SKRect
DrawBackgroundInternal ( SKCanvas canvas, ArgbColor color, Rect2 rect ) : void
DrawEllipseInternal ( SKCanvas canvas, SKPaint brush, SKPaint pen, bool isStroked, bool isFilled, SKRect &rect ) : void
DrawGridInternal ( SKCanvas canvas, SKPaint stroke, SKRect &rect, double offsetX, double offsetY, double cellWidth, double cellHeight, bool isStroked ) : void
DrawLineArrowInternal ( SKCanvas canvas, SKPaint pen, SKPaint brush, float x, float y, double angle, ArrowStyle style ) : SKPoint
DrawLineArrowsInternal ( SKCanvas canvas, XLine line, double dx, double dy, SKPoint &pt1, SKPoint &pt2 ) : void
DrawLineCurveInternal ( SKCanvas canvas, SKPaint pen, bool isStroked, SKPoint &pt1, SKPoint &pt2, double curvature, CurveOrientation orientation, PointAlignment pt1a, PointAlignment pt2a ) : void
DrawLineInternal ( SKCanvas canvas, SKPaint pen, bool isStroked, SKPoint &p0, SKPoint &p1 ) : void
DrawPathInternal ( SKCanvas canvas, SKPaint brush, SKPaint pen, bool isStroked, bool isFilled, SKPath path ) : void
DrawRectangleInternal ( SKCanvas canvas, SKPaint brush, SKPaint pen, bool isStroked, bool isFilled, SKRect &rect ) : void
GetTextOrigin ( ShapeStyle style, SKRect &rect, SKRect &size ) : SKPoint
ToSKColor ( ArgbColor color ) : SKColor
ToSKPaintBrush ( ArgbColor color ) : SKPaint
ToSKPaintPen ( BaseStyle style, float>.Func scale, double sourceDpi, double targetDpi ) : SKPaint
ToSKRect ( double x, double y, double width, double height ) : SKRect

Method Details

ClearCache() public method

public ClearCache ( bool isZooming ) : void
isZooming bool
return void

Create() public static method

Creates a new SkiaRenderer instance.
public static Create ( ) : ShapeRenderer
return Core2D.Renderer.ShapeRenderer

Draw() public method

public Draw ( object dc, XArc arc, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
arc Core2D.Shapes.XArc
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Draw() public method

public Draw ( object dc, XCubicBezier cubicBezier, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
cubicBezier Core2D.Shapes.XCubicBezier
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Draw() public method

public Draw ( object dc, XEllipse ellipse, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
ellipse Core2D.Shapes.XEllipse
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Draw() public method

public Draw ( object dc, XImage image, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
image Core2D.Shapes.XImage
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Draw() public method

public Draw ( object dc, XLine line, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
line Core2D.Shapes.XLine
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Draw() public method

public Draw ( object dc, XPath path, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
path Core2D.Shapes.XPath
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Draw() public method

public Draw ( object dc, XQuadraticBezier quadraticBezier, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
quadraticBezier Core2D.Shapes.XQuadraticBezier
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Draw() public method

public Draw ( object dc, XRectangle rectangle, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
rectangle Core2D.Shapes.XRectangle
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Draw() public method

public Draw ( object dc, XText text, double dx, double dy, ImmutableArray db, XRecord r ) : void
dc object
text Core2D.Shapes.XText
dx double
dy double
db ImmutableArray
r Core2D.Data.Database.XRecord
return void

Fill() public method

public Fill ( object dc, double x, double y, double width, double height, ArgbColor color ) : void
dc object
x double
y double
width double
height double
color Core2D.Style.ArgbColor
return void

SkiaRenderer() public method

Initializes a new instance of the SkiaRenderer class.
public SkiaRenderer ( bool isAntialias = true, double targetDpi = 72.0 ) : System
isAntialias bool The flag indicating whether paint is antialiased.
targetDpi double The target renderer dpi.
return System