Class: Rays::Image
Instance Method Summary collapse
- #bitmap(modify = false) ⇒ Object
- #bounds ⇒ Object
-
#initialize(*args, pixel_density: 1, smooth: false) ⇒ Image
constructor
A new instance of Image.
- #paint(&block) ⇒ Object
- #size ⇒ Object
Constructor Details
#initialize(*args, pixel_density: 1, smooth: false) ⇒ Image
Returns a new instance of Image.
16 17 18 |
# File 'lib/rays/image.rb', line 16 def initialize(*args, pixel_density: 1, smooth: false) initialize! args, pixel_density, smooth end |
Instance Method Details
#bitmap(modify = false) ⇒ Object
33 34 35 |
# File 'lib/rays/image.rb', line 33 def bitmap(modify = false) get_bitmap modify end |
#bounds ⇒ Object
29 30 31 |
# File 'lib/rays/image.rb', line 29 def bounds() Bounds.new 0, 0, width, height end |
#paint(&block) ⇒ Object
20 21 22 23 |
# File 'lib/rays/image.rb', line 20 def paint(&block) painter.paint self, &block self end |
#size ⇒ Object
25 26 27 |
# File 'lib/rays/image.rb', line 25 def size() return width, height end |