Albums: Downsize share preview image from 1600x900 to 1200x675 #3658
Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
parent
dbcaf775a8
commit
12608a7a31
1 changed files with 4 additions and 1 deletions
|
@ -141,8 +141,11 @@ func SharePreview(router *gin.RouterGroup) {
|
|||
// Create album preview from thumbnail images.
|
||||
preview, err := frame.Collage(frame.Polaroid, images)
|
||||
|
||||
// Downsize from 1600x900 to 1200x675.
|
||||
preview = imaging.Resize(preview, 1200, 0, imaging.Lanczos)
|
||||
|
||||
// Save the resulting album preview as JPEG.
|
||||
err = imaging.Save(preview, previewFilename)
|
||||
err = imaging.Save(preview, previewFilename, thumb.JpegQualitySmall.EncodeOption())
|
||||
|
||||
if err != nil {
|
||||
log.Error(err)
|
||||
|
|
Loading…
Reference in a new issue