diff --git a/app/uploaders/image_uploader.rb b/app/uploaders/image_uploader.rb index d372e4f..0167487 100644 --- a/app/uploaders/image_uploader.rb +++ b/app/uploaders/image_uploader.rb @@ -4,7 +4,7 @@ class ImageUploader < Shrine ALLOWED_TYPES = %w[image/jpeg image/png image/webp] MAX_SIZE = 5*1024*1024 # 5 MB - MAX_DIMENSIONS = [4000, 4000] # 2000x2000 + MAX_DIMENSIONS = [8000, 8000] # larger than 2000x2000 will be resized plugin :remove_attachment plugin :pretty_location @@ -29,7 +29,7 @@ class ImageUploader < Shrine thumb: magick.resize_to_limit!(160,120), small: magick.resize_to_limit!(320, 240), #medium: magick.resize_to_limit!(800, 600), - large: magick.composite!('public/logo/watermark.png', gravity: 'east') + large: magick.resize_to_limit(2000,2000).composite!('public/logo/watermark.png', gravity: 'east') } # GenerateThumbnail.call(original, width, height) # lib/generate_thumbnail.rb