Documentation
¶
Index ¶
- func CalcResizedRect(src image.Rectangle, width int, height int, centerAlign bool) image.Rectangle
- func RotatePoint(x, y, sin, cos float64) (float64, float64)
- func RotatedSize(w, h int, angle float64) (int, int)
- type AreaRect
- type DrawStringParams
- type Matrix
- type NRGBA
- type Palette
- type PositionRect
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CalcResizedRect ¶ added in v2.0.3
func RotatePoint ¶
RotatePoint is to the point of rotation
Types ¶
type DrawStringParams ¶
type DrawStringParams struct { Color color.Color Size int Width int Height int FontDPI int Text string Font *truetype.Font }
DrawStringParams .
type Matrix ¶
type Matrix struct {
XX, YX, XY, YY, X0, Y0 float64
}
Matrix .
type NRGBA ¶
type NRGBA interface { image.Image Get() *image.NRGBA DrawImage(img Palette, dotRect *PositionRect, posRect *AreaRect) DrawString(params *DrawStringParams, pt fixed.Point26_6) error CalcMarginBlankArea() *AreaRect Rotate(angle int, overCrop bool) Scale(zoomSize int, keepRatio, centerAlign bool) CropCircle(x, y, radius int) CropScaleCircle(x, y, radius int, zoomSize int) SubImage(r image.Rectangle) }
NRGBA .
func CreateNRGBACanvas ¶
CreateNRGBACanvas is to the canvas that creates the NRGBA
type Palette ¶
type Palette interface { image.Image Get() *image.Paletted CalcMarginBlankArea() *AreaRect Rotate(angle int) Distort(amplude float64, period float64) DrawBeeline(point1 image.Point, point2 image.Point, lineColor color.RGBA) DrawCircle(x, y, radius int, c color.RGBA) DrawHorizLine(fromX, toX, y int, c color.RGBA) AngleSwapPoint(x, y, r, angle float64) (tarX, tarY float64) DrawString(params *DrawStringParams, pt fixed.Point26_6) error }
Palette .
func CreatePaletteCanvas ¶
CreatePaletteCanvas is to the canvas that creates the palette
Click to show internal directories.
Click to hide internal directories.