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
Click to show internal directories.
Click to hide internal directories.