mirror of
https://github.com/talgo-cloud/bimg.git
synced 2026-03-14 01:46:18 -07:00
fix(#28): zoom requires extract params
This commit is contained in:
parent
3f063b6a2f
commit
924be1d3f4
3 changed files with 24 additions and 15 deletions
7
image.go
7
image.go
|
|
@ -81,9 +81,10 @@ func (i *Image) Watermark(w Watermark) ([]byte, error) {
|
|||
return i.Process(options)
|
||||
}
|
||||
|
||||
// Zoom the image by the given factor
|
||||
func (i *Image) Zoom(level int) ([]byte, error) {
|
||||
options := Options{Zoom: level}
|
||||
// Zoom the image by the given factor.
|
||||
// You should probably call Extract() before
|
||||
func (i *Image) Zoom(factor int) ([]byte, error) {
|
||||
options := Options{Zoom: factor}
|
||||
return i.Process(options)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue