Class: WR::Picture
- Inherits:
-
RWin::Picture
- Object
- RWin::Picture
- WR::Picture
- Defined in:
- lib/wrb/components/picture.rb
Overview
The very small subset of GDI+ functions, only for getting and saving sevral types of an image file.
This class is using the GDI+ Flat API functions written by C. So see ‘wrb/ext/rw_graphics.c’ and ‘rw_gdiplus.h’ for more information.
Instance Method Summary collapse
-
#_dump(encoder = 'image/png', resolution = nil) ⇒ Object
Dumps self to a string for Marshal object with specified encoder and resolution.
Give a string as encoder such as “png” or “jpeg”, and a float as resolution.
Instance Method Details
#_dump(encoder = 'image/png', resolution = nil) ⇒ Object
Dumps self to a string for Marshal object with specified encoder and resolution.
Give a string as encoder such as “png” or “jpeg”, and a float as resolution.
50 51 52 53 |
# File 'lib/wrb/components/picture.rb', line 50 def _dump(encoder='image/png', resolution=nil) encoder[0, 0] = 'image/' if encoder.split('/').size == 1 super(encoder, resolution) end |