Versions in this module Expand all Collapse all v0 v0.2.0 Nov 14, 2026 Changes in this version + func SetMaxThreads(n int) int + func TranscodeJPEGEffort(data []byte, effort int) (out []byte, err error) v0.1.0 Nov 13, 2026 Changes in this version + var ErrNoJPEG = errors.New("gojxl: no JPEG reconstruction data (jbrd box)") + var ErrUnsupportedColour = enc.ErrColourModel + func ConvertToJPEG(w io.Writer, data []byte, quality int, opt *Options) (err error) + func ConvertToJXL(data []byte, opt *EncodeOptions) (out []byte, err error) + func ConvertToPFM(w io.Writer, data []byte, opt *Options) (err error) + func ConvertToPNG(w io.Writer, data []byte, opt *Options) (err error) + func ConvertToPNM(w io.Writer, data []byte, opt *Options) (err error) + func Decode(r io.Reader) (image.Image, error) + func DecodeBytes(data []byte) (image.Image, error) + func DecodeBytesOptions(data []byte, opt *Options) (img image.Image, err error) + func DecodeConfig(r io.Reader) (image.Config, error) + func DecodeInput(data []byte) (img image.Image, err error) + func DistanceFromQuality(q float32) float32 + func Encode(w io.Writer, img image.Image, opt *EncodeOptions) error + func EncodeAnimation(anim *Animation, opt *EncodeOptions) ([]byte, error) + func EncodeBytes(img image.Image, opt *EncodeOptions) ([]byte, error) + func HasJPEG(data []byte) bool + func ReconstructJPEG(data []byte) (out []byte, err error) + func SSIMULACRA2(orig, dist image.Image) (float64, error) + func TranscodeJPEG(data []byte) (out []byte, err error) + type Animation struct + Frames []Frame + NumLoops int + func DecodeAll(data []byte) (anim *Animation, err error) + func DecodeAllOptions(data []byte, opt *Options) (anim *Animation, err error) + func DecodeAnimatedInput(data []byte) (*Animation, error) + type EncodeOptions struct + Distance float32 + Effort int + Exif []byte + ICC []byte + JPEGPixels bool + XMP []byte + type Frame struct + Duration float64 + Image image.Image + type Info struct + Animated bool + BitsPerSample int + CICP []byte + Colour string + Exif []byte + FloatSamples bool + Grey bool + HasAlpha bool + Height int + ICC []byte + NumExtraChannels int + Orientation int + OutputICC []byte + Width int + XMP []byte + XYB bool + func Stat(data []byte) (*Info, error) + type Options struct + Force16 bool + SRGB bool