Documentation ¶
Index ¶
- Constants
- func ClampF64(value float64, min float64, max float64) float64
- func ClampInt(value int, min int, max int) int
- func ForEachGrayPixel(img *image.Gray, f func(pixel color.Gray))
- func ForEachPixel(size image.Point, f func(x int, y int))
- func ForEachRGBAAlphaPixel(img *image.RGBA, f func(r uint8))
- func ForEachRGBABluePixel(img *image.RGBA, f func(r uint8))
- func ForEachRGBAGreenPixel(img *image.RGBA, f func(r uint8))
- func ForEachRGBAPixel(img *image.RGBA, f func(pixel color.RGBA))
- func ForEachRGBARedPixel(img *image.RGBA, f func(r uint8))
- func GetMax(v []uint64) uint64
- func ParallelForEachPixel(size image.Point, f func(x int, y int))
Constants ¶
const MaxUint16 = ^uint16(0)
MaxUint16 - maximum value which can be held in an uint16
const MaxUint8 = ^uint8(0)
MaxUint8 - maximum value which can be held in an uint8
const MinUint16 = 0
MinUint16 - minimum value which can be held in an uint8
const MinUint8 = 0
MinUint8 - minimum value which can be held in an uint8
Variables ¶
This section is empty.
Functions ¶
func ClampF64 ¶
ClampF64 returns min if value is lesser then min, max if value is greater them max or value if the input value is between min and max.
func ClampInt ¶
ClampInt returns min if value is lesser then min, max if value is greater them max or value if the input value is between min and max.
func ForEachGrayPixel ¶
ForEachGrayPixel loops through the image and calls f functions for each gray pixel.
func ForEachPixel ¶
ForEachPixel loops through the image and calls f functions for each [x, y] position.
func ForEachRGBAAlphaPixel ¶
ForEachRGBAAlphaPixel loops through the image and calls f functions for alpha component of each RGBA pixel
func ForEachRGBABluePixel ¶
ForEachRGBABluePixel loops through the image and calls f functions for blue component of each RGBA pixel.
func ForEachRGBAGreenPixel ¶
ForEachRGBAGreenPixel loops through the image and calls f functions for green component of each RGBA pixel.
func ForEachRGBAPixel ¶
ForEachRGBAPixel loops through the image and calls f functions for each RGBA pixel.
func ForEachRGBARedPixel ¶
ForEachRGBARedPixel loops through the image and calls f functions for red component of each RGBA pixel.
func ParallelForEachPixel ¶
ParallelForEachPixel loops through the image and calls f functions for each [x, y] position. The image is divided into N * N blocks, where N is the number of available processor threads. For each block a parallel Goroutine is started.
Types ¶
This section is empty.