Documentation ¶
Index ¶
- Variables
- func MaxSize(w, h, maxW, maxH int) (int, int)
- func Process(src io.Reader, processors []Processor) (image.Image, error)
- func ProcessAnimation(src io.Reader, processors []Processor) (*gif.GIF, error)
- func ProcessAnimationStream(dst io.Writer, src io.Reader, processors []Processor) error
- func ProcessStream(dst io.Writer, src io.Reader, processors []Processor) error
- type Processor
Constants ¶
This section is empty.
Variables ¶
View Source
var PNGEncoder = &png.Encoder{ CompressionLevel: png.NoCompression, }
Functions ¶
func MaxSize ¶
MaxSize returns the maximum size that can fit within the given max width and height. Aspect ratio is preserved.
func Process ¶
Process takes a processor and run them through the image decoded from the stream. The returned image is the processed image.
func ProcessAnimation ¶
ProcessAnimation works similarly to Process, but parses a GIF.
func ProcessAnimationStream ¶
ProcessAnimationStream works similarly to ProcessStream, but parses a GIF.
Types ¶
Click to show internal directories.
Click to hide internal directories.