Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PrepareOptions ¶
type PreparedImage ¶
type PreparedImage struct {
Data []byte
MIMEType string
OriginalBytes int
FinalBytes int
OriginalWidth int
OriginalHeight int
FinalWidth int
FinalHeight int
OriginalContentType string
Reencoded bool
}
func PrepareImageBytes ¶
func PrepareImageBytes(data []byte, contentType string, options PrepareOptions) (*PreparedImage, error)
func PrepareImageForService ¶
func PrepareImageForService(ctx context.Context, imageURL string, options PrepareOptions) (*PreparedImage, error)
func (*PreparedImage) DataURL ¶
func (p *PreparedImage) DataURL() string
Click to show internal directories.
Click to hide internal directories.