imagemagick

package
v1.0.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUnavailable = errors.New("imagemagick is unavailable")

ErrUnavailable ImageMagickが使用できません

View Source
var ErrUnsupportedType = errors.New("unsupported file type")

ErrUnsupportedType 未サポートのファイルタイプです

Functions

func ConvertToPNG

func ConvertToPNG(ctx context.Context, execPath string, src io.Reader, maxWidth, maxHeight int) (*bytes.Buffer, error)

ConvertToPNG srcをimagemagickでPNGに変換します。5秒以内に変換できなかった場合はエラーとなります

func ResizeAnimationGIF

func ResizeAnimationGIF(ctx context.Context, execPath string, src io.Reader, maxWidth, maxHeight int, expand bool) (*bytes.Buffer, error)

ResizeAnimationGIF Animation GIF画像をimagemagickでリサイズします expandがfalseの場合、縮小は行いますが拡大は行いません

Types

This section is empty.

Jump to

Keyboard shortcuts

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