示例#1
0
文件: canvas.go 项目: phacops/canvas
// Draws a line starting on the current coordinate system origin and ending on the specified coordinates.
func (self *Canvas) Line(x float64, y float64) {
	C.DrawLine(self.drawing, C.double(0), C.double(0), C.double(x), C.double(y))
}
示例#2
0
// Draws a line starting on the current coordinate system origin and ending on the specified coordinates.
func (cv Canvas) Line(x float64, y float64) {
	C.DrawLine(cv.drawing, C.double(0), C.double(0), C.double(x), C.double(y))
}
示例#3
0
// Draws a line on the image using the current stroke color, stroke opacity,
// and stroke width.
//
//sx: starting x ordinate
//
//sy: starting y ordinate
//
//ex: ending x ordinate
//
//ey: ending y ordinate
//
func (dw *DrawingWand) Line(sx, sy, ex, ey float64) {
	C.DrawLine(dw.dw, C.double(sx), C.double(sy), C.double(ex), C.double(ey))
}