Documentation ¶
Index ¶
- Constants
- func Bmp(dest io.Writer, src multipart.File, fn ...ToImgFn) error
- func GetSize(path string) (int64, error)
- func Gif(dest io.Writer, src multipart.File, opt *gif.Options, fn ...ToImgFn) error
- func Jpeg(dest io.Writer, src multipart.File, quality int, fn ...ToImgFn) error
- func Png(dest io.Writer, src multipart.File, fn ...ToImgFn) error
- func Rotate180(m image.Image) image.Image
- func Rotate270(m image.Image) image.Image
- func Rotate90(m image.Image) image.Image
- func ValidPicFmt(filename string, mustFmt ...[]string) bool
- func Webp(dest io.Writer, src multipart.File, fn ...ToImgFn) error
- type ToImgFn
- type XImg
Constants ¶
View Source
const ( DirectResize uint8 // 直接压缩 EqualRatioResize // 等比压缩 )
Variables ¶
This section is empty.
Functions ¶
func ValidPicFmt ¶ added in v1.2.3
ValidPicFmt 验证图片格式
Types ¶
type XImg ¶
type XImg struct { SysSplit string // 系统路径分隔符 FileName string // 文件名 // contains filtered or unexported fields }
Click to show internal directories.
Click to hide internal directories.