transcoder

package
v0.0.0-...-be54a21 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2021 License: ISC Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SupportsWebP

func SupportsWebP(headers http.Header) bool

Types

type Gif

type Gif struct {
	// contains filtered or unexported fields
}

func NewGif

func NewGif(quality int) *Gif

func (*Gif) Transcode

func (t *Gif) Transcode(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header) error

func (*Gif) TranscodeHead

func (t *Gif) TranscodeHead(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header)

type Identity

type Identity struct{}

func (*Identity) Transcode

func (i *Identity) Transcode(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header) error

func (*Identity) TranscodeHead

func (i *Identity) TranscodeHead(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header)

type Jpeg

type Jpeg struct {
	// contains filtered or unexported fields
}

func NewJpeg

func NewJpeg(imgsz uint, quality, wpquality int) *Jpeg

func (*Jpeg) Transcode

func (t *Jpeg) Transcode(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header) error

func (*Jpeg) TranscodeHead

func (t *Jpeg) TranscodeHead(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header)

type Minifier

type Minifier struct {
	// contains filtered or unexported fields
}

func NewMinifier

func NewMinifier() *Minifier

func (*Minifier) Transcode

func (t *Minifier) Transcode(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header) error

func (*Minifier) TranscodeHead

func (t *Minifier) TranscodeHead(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header)

type Png

type Png struct {
	// contains filtered or unexported fields
}

func NewPng

func NewPng(imgsz uint, quality int) *Png

func (*Png) Transcode

func (t *Png) Transcode(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header) error

func (*Png) TranscodeHead

func (t *Png) TranscodeHead(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header)

type WebP

type WebP struct {
	// contains filtered or unexported fields
}

func NewWebP

func NewWebP(imgsz uint, quality int) *WebP

func (*WebP) Transcode

func (t *WebP) Transcode(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header) error

func (*WebP) TranscodeHead

func (t *WebP) TranscodeHead(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header)

type Zip

type Zip struct {
	proxy.Transcoder
	BrotliCompressionLevel int
	GzipCompressionLevel   int
	SkipCompressed         bool
}

func (*Zip) Transcode

func (t *Zip) Transcode(w *proxy.ResponseWriter, r *proxy.ResponseReader, headers http.Header) error

Jump to

Keyboard shortcuts

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