image

package
v0.0.0-...-f0b9b21 Latest Latest
Warning

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

Go to latest
Published: Feb 14, 2024 License: GPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUninitializedBuffer = errors.New("uninitialized buffer")

ErrUninitializedBuffer is returned when *bytes.Buffer is nil

Functions

This section is empty.

Types

type ImageService

type ImageService interface {
	Banner() BannerService
	Poster() PosterService
	Thumbnail() ThumbnailService
	Processor() ProcessorService

	DeleteUnused(ctx context.Context) (*domain.UnusedImages, error)
}

func NewImageService

func NewImageService(
	banner BannerService,
	poster PosterService,
	thumbnail ThumbnailService,
	processor ProcessorService,
) ImageService

type ProcessorService

type ProcessorService interface {
	DominantColour(ctx context.Context, reader io.Reader) *string
	ReadImage(ctx context.Context, uri string) (imageBytes []byte, err error)
}

func NewProcessorService

func NewProcessorService() ProcessorService

Jump to

Keyboard shortcuts

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