utilities

package
v2.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 21, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Clamp added in v2.0.4

func Clamp[T float64 | int | uint](value, max, min T) T

func ClampMax added in v2.0.4

func ClampMax[T float64 | int | uint](value, max T) T

func CreateGrid added in v2.0.4

func CreateGrid(width, height int) [][]color.Color

func DecodeSource

func DecodeSource(file io.Reader) (*image.RGBA, string, error)

func EncodeGridResult

func EncodeGridResult(result [][]color.Color, format string) (io.Reader, string, error)

func EncodeResult

func EncodeResult(img *image.RGBA, format string) (io.Reader, string, error)

func GetAperture

func GetAperture(axisValue, axisMax, apertureMin, apertureMax int) (int, int)

func GetCoordinates

func GetCoordinates(pixel, width int) (int, int)

func GetPixPerThread added in v2.0.4

func GetPixPerThread(pixLen, threads int) int

func GetPixel

func GetPixel(x, y, width int) int

func GetThreads added in v2.0.4

func GetThreads() int

func GradientPoint

func GradientPoint(axisValue, shift, axisLength int) int

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL