Skip to content

Commit f83b73a

Browse files
realsimDarthSim
authored andcommitted
Use image height to calculate watermark top offset (imgproxy#313)
1 parent 8b87504 commit f83b73a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

process.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ func prepareWatermark(wm *vipsImage, wmData *imageData, opts *watermarkOptions,
261261
return wm.Replicate(imgWidth, imgHeight)
262262
}
263263

264-
left, top := calcPosition(imgWidth, imgWidth, wm.Width(), wm.Height(), &opts.Gravity, true)
264+
left, top := calcPosition(imgWidth, imgHeight, wm.Width(), wm.Height(), &opts.Gravity, true)
265265

266266
return wm.Embed(imgWidth, imgHeight, left, top, rgbColor{0, 0, 0})
267267
}

0 commit comments

Comments
 (0)