aboutsummaryrefslogtreecommitdiff
path: root/vendor/github.com/llgcode/draw2d/draw2dpdf/vectorizer.go
blob: 556c2e08e6ab3fff47c9b1e754d71f4c67b0abda (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Copyright 2015 The draw2d Authors. All rights reserved.
// created: 26/06/2015 by Stani Michiels

package draw2dpdf

// Vectorizer defines the minimal interface for gofpdf.Fpdf
// to be passed to a PathConvertor.
// It is also implemented by for example VertexMatrixTransform
type Vectorizer interface {
	// MoveTo creates a new subpath that start at the specified point
	MoveTo(x, y float64)
	// LineTo adds a line to the current subpath
	LineTo(x, y float64)
	// CurveTo adds a quadratic bezier curve to the current subpath
	CurveTo(cx, cy, x, y float64)
	// CurveTo adds a cubic bezier curve to the current subpath
	CurveBezierCubicTo(cx1, cy1, cx2, cy2, x, y float64)
	// ArcTo adds an arc to the current subpath
	ArcTo(x, y, rx, ry, degRotate, degStart, degEnd float64)
	// ClosePath closes the subpath
	ClosePath()
}