2 # -*- coding: utf-8 -*-
7 def self.create_thumbs(fname)
8 $LOAD_PATH.push("/home/lunardial/local/lib")
9 $LOAD_PATH.push("/home/lunardial/local/lib/ruby/gem/gems/rmagick-2.13.1/lib")
14 img = Magick::Image.read(fname).first
16 img.resize_to_fit!(THUMBS_SIZE, THUMBS_SIZE)
17 thumbs_name = fname.gsub(/#{File.extname(fname)}\Z/, "") + "_thumbs" + File.extname(fname)
18 img.write(thumbs_name)