Class: RGBQuad
- Inherits:
-
Object
- Object
- RGBQuad
- Defined in:
- lib/ruby-doom.rb
Instance Method Summary collapse
-
#initialize(bytes) ⇒ RGBQuad
constructor
A new instance of RGBQuad.
- #to_s ⇒ Object
Constructor Details
#initialize(bytes) ⇒ RGBQuad
Returns a new instance of RGBQuad.
8 9 10 |
# File 'lib/ruby-doom.rb', line 8 def initialize(bytes) @r,@g,@b,@res = *bytes end |
Instance Method Details
#to_s ⇒ Object
11 12 13 |
# File 'lib/ruby-doom.rb', line 11 def to_s return @r.to_s + "," + @g.to_s + "," + @b.to_s end |