fisheye

package
v0.0.0-...-ddb766c Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrDetectDistance = errors.New("fisheye: can not detect distance")
)

Functions

func ApplyFishEye

func ApplyFishEye(dest draw.Image, src image.Image, distance int) draw.Image

func CloneImage

func CloneImage(dst draw.Image, src image.Image) draw.Image

func DistanceRange

func DistanceRange(dx int) (int, int)

func FindDistance

func FindDistance(src image.Image, testRowIndex int) (image.Image, int)

func Formula

func Formula(s float64) float64

func GenFile

func GenFile(path string, testRowIndex int) (image.Image, error)

func MakeNoise

func MakeNoise(img image.Image, distance int, factory func() draw.Image) draw.Image

func RemoveFishEye

func RemoveFishEye(dest draw.Image, src image.Image, distance int) draw.Image

func WhitePoints

func WhitePoints(src image.Image, y int) int

Types

type FisheyePreprocessor

type FisheyePreprocessor struct {
	TestRowIndex int
}

func NewPreprocessor

func NewPreprocessor() *FisheyePreprocessor

func (*FisheyePreprocessor) Preprocess

func (p *FisheyePreprocessor) Preprocess(_ context.Context, img image.Image) (image.Image, error)

Jump to

Keyboard shortcuts

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