Versions in this module Expand all Collapse all v0 v0.0.7 Apr 10, 2019 Changes in this version + const PATHNOOP + var AvailableColorModels = []ColorModel + var AvailableFileType = []FileType + var AvailablePPU []string = []string + var EmptyIntersectError = xrr.Xrror("Unable to crop empty intersect of %v and provided %v").Out + var Linear = ResampleFilter + var NearestNeighbor = ResampleFilter + var NoBlendPositionError = xrr.Xrror("no blend position") + var NoDirectionError = xrr.Xrror("'%s' is not a direction to flip").Out + var SaveNoopError = xrr.Xrror("cannot save a non operational canvas") + var WorkingColorModel = RGBA + var WorkingColorModelFn = color.RGBAModel + var WorkingColorModelNew = image.NewRGBA + var WorkingColorModelString = "RGBA" + var ZeroResizeError = xrr.Xrror("zero value prevents resizing\n\twidth %d\n\theight %d\n\tempty canvas: %t").Out + func HSLToRGB(h, s, l float64) color.RGBA + func HSVToRGB(h, s, v float64) color.RGBA + func OpenTo(path string) (image.Image, error) + func RGBToHSL(c color.RGBA) (float64, float64, float64) + func RGBToHSV(c color.RGBA) (h, s, v float64) + func Scratch(cm color.Model, X, Y int) *pxl + type Action int + const ACTIONCLONE + const ACTIONNEW + const ACTIONNOOP + const ACTIONOPEN + func (a Action) String() string + type Adjuster interface + Adjust func(AdjustmentFunc) error + type AdjustmentFunc func(color.RGBA) color.RGBA + type BlendFunc func(RGBA164, RGBA164) RGBA164 + type BlendPosition int + const BG + const FG + const NoBlendPosition + type Blender interface + Blend func(image.Image, BlendPosition, BlendFunc) error + type Canvas interface + func New(cnf ...Config) (Canvas, error) + type Cloner interface + Clone func() Canvas + CloneTo func(color.Model) Canvas + type ColorModel int + const ALPHA + const ALPHA16 + const CMYK + const COLORNOOP + const GRAY + const GRAY16 + const NRGBA + const NRGBA64 + const RGBA + const RGBA64 + func (c ColorModel) String() string + type ColorStats interface + Channel func(string) (*image.Gray, error) + RGBAHistogram func() *RGBAHistogram + Threshold func(l uint8) (*image.Gray, error) + type Config interface + Configure func(*canvas) error + Order func() int + func DefaultConfig(fn ConfigFn) Config + func NewConfig(order int, fn ConfigFn) Config + func SetColorModel(m string) Config + func SetFileType(k string) Config + func SetLogger(l log.Logger) Config + func SetMeasure(pp float64, ppu string) Config + func SetPaletteFn(fn PaletteFunc) Config + func SetPath(in, out string) Config + func SetRect(x, y int) Config + type ConfigFn func(*canvas) error + type Configuration interface + Add func(...Config) + AddFn func(...ConfigFn) + Configure func() error + Configured func() bool + type Convoluter interface + Convolve func(mth.Matrix, float64, bool, bool) error + type Cropper interface + Crop func(image.Rectangle) error + type FileType int + const BMP + const FILETYPENOOP + const JPG + const PNG + const TIFF + func (t FileType) String() string + type Histogram struct + Bins []int + func (h *Histogram) Cumulative() *Histogram + func (h *Histogram) Image() *image.Gray + func (h *Histogram) Max() int + func (h *Histogram) Min() int + type Identity interface + Action func() string + FileType func() string + type ImageImage interface + At func(x, y int) color.Color + Bounds func() image.Rectangle + ColorModel func() color.Model + Opaque func() bool + PixOffset func(int, int) int + Set func(x, y int, c color.Color) + SubImage func(image.Rectangle) image.Image + type Measure interface + Anchor func(string) Moint + Distance func(string, Moint, Moint) float64 + Height func() float64 + PP func(string) float64 + Radius func() float64 + SetAnchor func(string, MointFunc) + SetPP func(string, float64) + Width func() float64 + type Moint struct + X float64 + Y float64 + var ZM Moint = Moint{ ... } + func ToMoint(ip image.Point) Moint + func (p Moint) Add(o Moint) Moint + func (p Moint) Distance(o Moint) float64 + func (p Moint) Div(k float64) Moint + func (p Moint) Eq(o Moint) bool + func (p Moint) Fixed() fixed.Point26_6 + func (p Moint) IPoint() image.Point + func (p Moint) In(r image.Rectangle) bool + func (p Moint) Interpolate(o Moint, t float64) Moint + func (p Moint) Mod(r image.Rectangle) Moint + func (p Moint) Mul(k float64) Moint + func (p Moint) String() string + func (p Moint) Sub(o Moint) Moint + type MointFunc func(f Measure) Moint + type NoiseFunc func() uint8 + type Noiser interface + Noise func(NoiseFunc, bool) error + type Nooper interface + Noop func() bool + type Operator interface + type PaletteFunc func(color.Color) color.Color + type Paletter interface + Palettize func(color.Color) color.Color + type Paster interface + Overlay func(draw.Image, image.Point, float64) + Paste func(draw.Image, image.Point) + type Pather interface + Path func() string + SetPath func(string) + type Pix interface + Pix func() []uint8 + SetPix func([]uint8) + Stride func() int + type Pxl interface + type RGBA164 struct + A float64 + B float64 + G float64 + R float64 + func AlphaComp(bg, fg RGBA164) RGBA164 + func (c *RGBA164) Clamp() + type RGBAHistogram struct + A Histogram + B Histogram + G Histogram + R Histogram + func NewRGBAHistogram(img image.Image) *RGBAHistogram + func (h *RGBAHistogram) Cumulative() *RGBAHistogram + func (h *RGBAHistogram) Image() *image.RGBA + type ResampleFilter struct + Fn ResampleFilterFunc + Key string + Support float64 + func (r ResampleFilter) String() string + type ResampleFilterFunc func(float64) float64 + type Resizer interface + Resize func(w, h int, f ResampleFilter) error + type Saver interface + Save func() error + SaveTo func(string) error + type TDir int + const NoTDir + const THorizontal + const TVertical + type Transformer interface + type Translater interface + Flip func(TDir) error + Rotate func(float64, bool, image.Point) error + Shear func(TDir, float64) error + Translate func(int, int) error