Documentation ¶
Overview ¶
Package images generate thumbnails and converts between image formats.
Index ¶
- Variables
- func Duplicate(filename, suffix string) (name string, err error)
- func Fix(simulate bool) error
- func Generate(src, id string, remove bool) error
- func Info(name string) (height, width int, format string, err error)
- func Move(src, dest string) error
- func NewExt(name, ext string) string
- func ToPng(src, dest string, maxDimension int) (s string, err error)
- func ToThumb(src, dest string, sizeSquared int) (s string, err error)
- func ToWebp(src, dest string, vendorTempDir bool) (s string, err error)
- func Width(name string) (width int, err error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrFormat = errors.New("unsupported image format")
Functions ¶
func Move ¶
Move a file from the source location to the destination. This is used in situations where os.rename() fails due to multiple partitions.
func ToPng ¶
ToPng converts any supported format to a compressed PNG image. helpful: https://www.programming-books.io/essential/go/images-png-jpeg-bmp-tiff-webp-vp8-gif-c84a45304ec3498081c67aa1ea0d9c49
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.