Created
October 29, 2010 12:05
-
-
Save klebervirgilio/653421 to your computer and use it in GitHub Desktop.
the error occurs whenever I try to use the class method 'Image.read'
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def img(opt={}) | |
opt[:background_path] ||= "#{Rails.root.to_s}/public/images/citywaypass/card_background.png" | |
opt[:background_density] ||= "300x300" | |
opt[:font] ||= 'arial' | |
opt[:font_weight] ||= 900 | |
opt[:pointsize] ||= 24 | |
opt[:width] ||= 2603 | |
opt[:heigth] ||= 1620 | |
opt[:text] ||= "Something...." | |
background = Image.read(opt[:background_path]) | |
background.first.density = opt[:background_density] | |
... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment