Class: Camouflage::CamouflageUploader
- Inherits:
-
CarrierWave::Uploader::Base
- Object
- CarrierWave::Uploader::Base
- Camouflage::CamouflageUploader
- Includes:
- CarrierWave::MiniMagick
- Defined in:
- lib/camouflage.rb
Instance Attribute Summary collapse
-
#blur_radius ⇒ Object
Returns the value of attribute blur_radius.
-
#blur_sigma ⇒ Object
Returns the value of attribute blur_sigma.
-
#height ⇒ Object
Returns the value of attribute height.
-
#width ⇒ Object
Returns the value of attribute width.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ CamouflageUploader
constructor
A new instance of CamouflageUploader.
- #store_dir ⇒ Object
Constructor Details
#initialize(options = {}) ⇒ CamouflageUploader
Returns a new instance of CamouflageUploader.
45 46 47 48 49 50 51 |
# File 'lib/camouflage.rb', line 45 def initialize( = {}) @blur_radius = .fetch(:blur_radius, 0) @blur_sigma = .fetch(:blur_sigma, 30) @width = .fetch(:width, 300) @height = .fetch(:height, 300) super(nil, nil) end |
Instance Attribute Details
#blur_radius ⇒ Object
Returns the value of attribute blur_radius.
43 44 45 |
# File 'lib/camouflage.rb', line 43 def blur_radius @blur_radius end |
#blur_sigma ⇒ Object
Returns the value of attribute blur_sigma.
43 44 45 |
# File 'lib/camouflage.rb', line 43 def blur_sigma @blur_sigma end |
#height ⇒ Object
Returns the value of attribute height.
43 44 45 |
# File 'lib/camouflage.rb', line 43 def height @height end |
#width ⇒ Object
Returns the value of attribute width.
43 44 45 |
# File 'lib/camouflage.rb', line 43 def width @width end |
Instance Method Details
#store_dir ⇒ Object
53 54 55 |
# File 'lib/camouflage.rb', line 53 def store_dir '/tmp' end |