Documentation ¶
Overview ¶
image/color.Color implementation for HSV representation
Index ¶
- Constants
- Variables
- func ApplyMaskOnMatrix[V any](dst [][]V, mask [][]bool, value V) ([][]V, error)
- func AsRGBA(img image.Image) *image.RGBA
- func MakeMatrix[V any](size int, value V) [][]V
- func MakeMatrixBool(size int) [][]bool
- func MakeMatrixWH[V any](width, height int, value V) [][]V
- func MakeRandMatrixBool(size, threshold int) [][]bool
- func MakeRandMatrixUint8(size, maxValue int) [][]uint8
- func Merge2Matrixes(matrixes [2][][]float32) ([][]mgl32.Vec2, error)
- type HSVColor
- type HexPlane
- type HexPoint
- type LineSquare
- type Point2D
- type TileMap
Constants ¶
View Source
const (
Sqrt3 = 1.732050807568877293527446341505872366942805253810380628055806
)
Variables ¶
Functions ¶
func ApplyMaskOnMatrix ¶
func MakeMatrix ¶
func MakeMatrixBool ¶
func MakeMatrixWH ¶
func MakeRandMatrixBool ¶
func MakeRandMatrixUint8 ¶
Types ¶
type HSVColor ¶
HSVColor defines a color in the Hue-Saturation-Value scheme. Hue is a value [0 - 360) specifying the color Saturation is a value [0 - 255] specifying the strength of the color Value is a value [0 - 255] specifying the brightness of the color
type HexPlane ¶
func NewHexBoard ¶
type HexPoint ¶
type HexPoint [3]float64 // Q R S
func Cube_round ¶
func Pixel_to_flat_hex ¶
func Pixel_to_pointy_hex ¶
type LineSquare ¶
func (*LineSquare) At ¶
func (ln *LineSquare) At(x int, y int) color.Color
At returns the color of the pixel at (x, y). At(Bounds().Min.X, Bounds().Min.Y) returns the upper-left pixel of the grid. At(Bounds().Max.X-1, Bounds().Max.Y-1) returns the lower-right one.
func (*LineSquare) Bounds ¶
func (ln *LineSquare) Bounds() image.Rectangle
Bounds returns the domain for which At can return non-zero color. The bounds do not necessarily contain the point (0, 0).
func (*LineSquare) ColorModel ¶
func (ln *LineSquare) ColorModel() color.Model
ColorModel returns the Image's color model.
Click to show internal directories.
Click to hide internal directories.