image

package
v0.0.0-...-6237511 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LanczosResizer

type LanczosResizer struct{}

LanczosResizer does resizing the image with Lanczos algorithm, https://en.wikipedia.org/wiki/Lanczos_algorithm

func NewLanczosResizer

func NewLanczosResizer() LanczosResizer

NewLanczosResizer returns a new Lanczos instance

func (LanczosResizer) Resize

func (r LanczosResizer) Resize(img io.Reader, width, height int) (io.Reader, error)

type Resizer

type Resizer interface {
	Resize(img io.Reader, width, height int) (io.Reader, error)
}

Resizer uses to resize an image file to the given width and height. The resize function should treat aspect ratio if one of them equal to zero.

Directories

Path Synopsis
Package mock_image is a generated GoMock package.
Package mock_image is a generated GoMock package.

Jump to

Keyboard shortcuts

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