filters

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: 6 Imported by: 0

Documentation

Index

Constants

View Source
const DEG float64 = math.Pi / 180
View Source
const K float64 = 6

Variables

View Source
var COLORS = [8]Color{
	{255, 0, 0},
	{0, 255, 0},
	{0, 0, 255},
	{255, 255, 0},
	{255, 0, 255},
	{0, 255, 255},
	{255, 255, 255},
	{0, 0, 0},
}

Functions

func Binary

func Binary(file io.Reader, threshold uint8) (io.Reader, string, error)

func BoxBlur

func BoxBlur(file io.Reader, radius uint) (io.Reader, string, error)

func Brightness

func Brightness(file io.Reader, amount int) (io.Reader, string, error)

func ColorInversion

func ColorInversion(file io.Reader) (io.Reader, string, error)

func Contrast

func Contrast(file io.Reader, amount int) (io.Reader, string, error)

func EightColors

func EightColors(file io.Reader) (io.Reader, string, error)

func Emboss

func Emboss(file io.Reader) (io.Reader, string, error)

func Flip

func Flip(file io.Reader, direction string) (io.Reader, string, error)

func GammaCorrection

func GammaCorrection(file io.Reader, amount float64) (io.Reader, string, error)

func GaussianBlur added in v2.0.4

func GaussianBlur(file io.Reader, sigma float64) (io.Reader, string, error)

func Grayscale

func Grayscale(file io.Reader, grayscaleType string) (io.Reader, string, error)

func HueRotate

func HueRotate(file io.Reader, angle int) (io.Reader, string, error)

func Kuwahara

func Kuwahara(file io.Reader, radius uint) (io.Reader, string, error)

func Laplacian

func Laplacian(file io.Reader) (io.Reader, string, error)

func RotateFixed

func RotateFixed(file io.Reader, angle uint) (io.Reader, string, error)

func Sepia

func Sepia(file io.Reader) (io.Reader, string, error)

func Sharpen

func Sharpen(file io.Reader, amount uint) (io.Reader, string, error)

func Sobel

func Sobel(file io.Reader) (io.Reader, string, error)

func Solarize

func Solarize(file io.Reader, threshold uint8) (io.Reader, string, error)

Types

type Color

type Color struct {
	R, G, B int
}

Jump to

Keyboard shortcuts

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