示例#1
0
//Draws the image at the given coordinates.
func (me *Canvas) DrawImage(img *Image, x, y int) {
	p.DrawImage(img.img, x, y, img.clipX(), img.clipY(), img.clipW(), img.clipH())
}
示例#2
0
//Draws the image at the given coordinates.
func (me *Canvas) DrawImageCrop(img *Image, x, y int, srcBnds starfish.Bounds) {
	p.DrawImage(img.img, x, y, srcBnds.X, srcBnds.Y, srcBnds.Width, srcBnds.Height)
}
示例#3
0
//Draws the text at the given coordinates.
func (me *Canvas) DrawText(text *Text, x, y int) {
	p.DrawImage(text.text, x, y, 0, 0, text.Width(), text.Height())
}