Module: Imogen::Cropped

Defined in:
lib/imogen.rb

Class Method Summary collapse

Class Method Details

.convert(img, dest_path, edges, scale = nil, format = :jpeg) ⇒ Object



27
28
29
# File 'lib/imogen.rb', line 27

def self.convert(img, dest_path, edges, scale=nil, format=:jpeg)
  img.crop(*edges).write_to_file(dest_path, background: [255, 255, 255])
end