0
Rmagick文檔不是最清楚的,我試過所有,但它不喜歡它?也許我誤解Magick :: Info如何工作?更改圖像文件名稱rmagick
http://www.imagemagick.org/RMagick/doc/info.html
def crop_photo(url, x, y, w, h)
image = Magick::ImageList.new
urlimage = open(url)
format = url.split('/')[-1].strip.split('?')[0].strip
image.from_blob(urlimage.read)
crop = image.crop(x,y,w,h)
image = crop.to_blob
image.filename = format #doesn't work
self.filename = format #doesn't work
end
的幫助感激
更改文件名我必須寫? – 2014-09-21 12:05:55