imager

package
v0.0.0-...-6dfde0d Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2017 License: GPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ImageProcessor

type ImageProcessor struct {
	File multipart.File

	Image image.Image
	// contains filtered or unexported fields
}

ImageProcessor holds info about image for processing

func (*ImageProcessor) FileName

func (i *ImageProcessor) FileName() (string, error)

FileName generates a random filename plus extension

func (*ImageProcessor) Resize

func (i *ImageProcessor) Resize(maxWidth uint) (err error)

Resize saves a resized image

func (*ImageProcessor) Save

func (i *ImageProcessor) Save(path string) (string, error)

Save saves the new image in the specified path

func (*ImageProcessor) Thumbnail

func (i *ImageProcessor) Thumbnail(size int) (err error)

Thumbnail makes a thumbnail of the image

Jump to

Keyboard shortcuts

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