Ruby / Paerclip水印和图像大小调整不起作用

时间:2012-09-10 12:04:23

标签: ruby-on-rails resize amazon-web-services paperclip watermark

我在AWS上运行了一个ROR应用。我上传了过去使用回形针的过程,在添加水印并改变了“高”图像的大小后,更改没有生效。任何想法?

has_attached_file :photo,
    :styles => {    
        :high => {
          :processors => [:watermark, :thumbnail],
          :geometry => '820x820>',
          :watermark_path => Rails.root.join('public/images/watermark.png'),
          :position => 'SouthWest' },           
        :original => "400x400",
        :thumb => "120x120>",
        :square_thumb => "126x126#",
        :convert_options => { :high => '-quality 96', :original => '-quality 96', :thumb => '-quality 96', :square_thumb => '-quality 96'},
        :preview => Proc.new { |instance| instance.preview_size } 
    },
    :storage => :s3,
    :s3_credentials => "#{RAILS_ROOT}/config/s3.yml",
    :path => ":attachment/:id/:style.:extension"

0 个答案:

没有答案