I would like to alter the processing of thumbnails in paperclip by having imagemagick apply a drop shadow to all the thumbnails. What I'm stuck on is the actual imagemagick command that would pull this little miracle off. Everything I've tried returns an incorrectly scaled drop shadow without the original image.
def transformation_command
scale, crop = @current_geometry.transformation_to(@target_geometry, crop?)
trans = ""
trans << " -resize \"#{scale}\""
trans << " -crop \"#{crop}\" +repage" if crop
# Apply Drop Shadow
trans << " #{convert_options}" if convert_options?
trans
end
One I've tried...
def transformation_command
scale, crop = @current_geometry.transformation_to(@target_geometry, crop?)
trans = ""
trans << " -resize \"#{scale}\""
trans << " -crop \"#{crop}\" +repage" if crop
trans << " \( +clone -background black -shadow 60x5+10+10 \) +swap -background none -layers merge +repage"
trans << " #{convert_options}" if convert_options?
trans
end
I'm completely new to imagemagick, any help would be greatly appreciated.