Class: Rays::Texture

Inherits:
Object
  • Object
show all
Defined in:
lib/rays/texture.rb

Instance Method Summary collapse

Constructor Details

#initialize(width, height, color_space = :RGBA, alpha_only = false) ⇒ Texture

Returns a new instance of Texture.



13
14
15
# File 'lib/rays/texture.rb', line 13

def initialize (width, height, color_space = :RGBA, alpha_only = false)
  setup width, height, ColorSpace.get_color_space(color_space), alpha_only
end

Instance Method Details

#boundsObject



17
18
19
# File 'lib/rays/texture.rb', line 17

def bounds ()
  Bounew.new 0, 0, width, height
end