search for: city_photo

Displaying 1 result from an estimated 1 matches for "city_photo".

2008 Jul 29
1
can't crop images using ImageMagick
...gick'' top_square = params[:top_square].to_d left_square = params[:left_square].to_d width_square = params[:width_square].to_d height_square = params[:height_square].to_d source_file = "#{RAILS_ROOT}/public#{@photo.public_filename}" destination_file = "#{RAILS_ROOT}/public#{city_photo.public_filename}" img = Magick::Image.read(source_file).first img.crop!(left_square, top_square, width_square, height_square) img.write destination_file Thanks, Andy --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Grou...