vips

package
v0.0.0-...-a4359f9 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Initialize

func Initialize(logger *logger.Logger) error

Initialize libvips if it's not already started

func PrintDebugInfo

func PrintDebugInfo()

PrintDebugInfo prints libvips debug info to stdout

func SaveToJpegBuffer

func SaveToJpegBuffer(image Image) ([]byte, error)

SaveToJpegBuffer saves an image as JPEG to a buffer

func SaveToWebPBuffer

func SaveToWebPBuffer(image Image) ([]byte, error)

SaveToWebPBuffer saves an image as WebP to a buffer

func SetUserComment

func SetUserComment(image Image, comment string)

SetUserComment sets the UserComment field in the exif metadata for an image

func Shutdown

func Shutdown()

Shutdown libvips

func UnrefImage

func UnrefImage(image Image)

UnrefImage unrefs an image object

Types

type Image

type Image *C.VipsImage

Image is a representation of the *C.VipsImage type

func Blur

func Blur(image Image, blur int) (Image, error)

Blur applies gaussian blur to an image

func Grayscale

func Grayscale(image Image) (Image, error)

Grayscale converts an image to grayscale

func NewEmptyImage

func NewEmptyImage() Image

NewEmptyImage returns an empty image object

func ResizeImage

func ResizeImage(buffer []byte, width int, height int) (Image, error)

ResizeImage loads an image from a buffer and resizes it.

Jump to

Keyboard shortcuts

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