Documentation
¶
Index ¶
- Variables
- func JsonPlotter(out io.Writer, p Canvas, d Drawing) error
- func Run(p Canvas, d DrawFunc)
- type Arc
- type BezierCurve
- type Canvas
- type Debug
- type DrawFunc
- type Drawable
- type Drawing
- type GCodeCommand
- type GCodeLift
- type GCodeLinearMoveXY
- type GCodeOpts
- type Line
- type OptimisationFunc
- type PlotFunc
- type XY
Constants ¶
This section is empty.
Variables ¶
View Source
var A4 = XY{210, 297}
Functions ¶
Types ¶
type BezierCurve ¶
type BezierCurve struct {
ControlPoints []XY
}
BezierCurve is a drawable bezier curve
type Canvas ¶
Canvas describes the canvas on which we'll draw
func (Canvas) FrameBleed ¶
Frame returns a frame around the canvas respecting the bleed
type Debug ¶
type Debug struct {
D Drawable
}
Debug helps debugging other drawables. Use `AsDebug()`.
type Drawable ¶
type Drawable interface {
// contains filtered or unexported methods
}
Drawable marks all drawable elements
type GCodeCommand ¶
type GCodeLift ¶
func (GCodeLift) ModifyState ¶
func (l GCodeLift) ModifyState(s *gcodeState)
type GCodeLinearMoveXY ¶
func (GCodeLinearMoveXY) ModifyState ¶
func (l GCodeLinearMoveXY) ModifyState(s *gcodeState)
func (GCodeLinearMoveXY) String ¶
func (l GCodeLinearMoveXY) String() string
type GCodeOpts ¶
type GCodeOpts struct { DrawFeed int `json:"drawFeed"` DrawLift int `json:"drawLift"` TravelFeed int `json:"travelFeed"` TravelLift int `json:"travelLift"` Scale float64 `json:"scale"` Offset XY `json:"offset"` }
func NewDefaultGCodeOpts ¶
func NewDefaultGCodeOpts() *GCodeOpts
type PlotFunc ¶
PlotFunc plots a drawing to some output device
func NewGCodePlotter ¶
func NewPNGPlotter ¶
func NewPNGPlotter() PlotFunc
Click to show internal directories.
Click to hide internal directories.