Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Render ¶
func Render(pageSize PageSize, unit Unit, imgWidthPx, imgHeightPx int, opts ImageOptions) (x, y, w, h float64, cropX1, cropY1, cropX2, cropY2 int, crop bool)
Returns an the image layout if rendered onto a the specified page in specified units. Cropping coordinates are in pixels on the image. Cropping is only necessary if crop returns true.
Types ¶
type Generator ¶
type Generator struct {
// contains filtered or unexported fields
}
func NewGenerator ¶
func (*Generator) AddImageFile ¶
func (g *Generator) AddImageFile(path string, opts ImageOptions) error
type ImageOptions ¶
Click to show internal directories.
Click to hide internal directories.