Class: Mittsu::Scene
- Defined in:
- lib/mittsu/scenes/scene.rb,
lib/mittsu/renderers/opengl/scenes/scene.rb
Constant Summary
Constants inherited from Object3D
Instance Attribute Summary collapse
-
#auto_update ⇒ Object
Returns the value of attribute auto_update.
-
#fog ⇒ Object
Returns the value of attribute fog.
-
#override_material ⇒ Object
Returns the value of attribute override_material.
Attributes inherited from Object3D
#active, #cast_shadow, #children, #frustum_culled, #geometry, #id, #initted, #matrix, #matrix_auto_update, #matrix_world, #matrix_world_needs_update, #model_view_matrix, #morph_target_influences, #name, #parent, #position, #quaternion, #receive_shadow, #render_order, #renderer, #rotation, #rotation_auto_update, #scale, #type, #up, #user_data, #uuid, #visible
Instance Method Summary collapse
- #clone(object = Scene.new) ⇒ Object
-
#initialize ⇒ Scene
constructor
A new instance of Scene.
- #project(renderer) ⇒ Object
Methods inherited from Object3D
#active?, #add, #add_opengl_object, #apply_matrix, #buffer_material, #deinit, #get_object_by_id, #get_object_by_name, #get_object_by_property, #get_world_direction, #get_world_position, #get_world_quaternion, #get_world_rotation, #get_world_scale, #init, #init_geometry, #load_uniforms_matrices, #local_to_world, #look_at, #print_tree, #raycast, #remove, #rotate_on_axis, #rotate_x, #rotate_y, #rotate_z, #set_rotation_from_axis_angle, #set_rotation_from_euler, #set_rotation_from_matrix, #set_rotation_from_quaternion, #setup_matrices, #to_json, #to_s, #translate_on_axis, #translate_x, #translate_y, #translate_z, #traverse, #traverse_ancestors, #traverse_visible, #update_matrix, #update_matrix_world, #world_to_local
Methods included from EventDispatcher
#add_event_listener, #dispatch_event, #has_event_listener, #remove_event_listener
Constructor Details
#initialize ⇒ Scene
Returns a new instance of Scene.
6 7 8 9 10 11 12 |
# File 'lib/mittsu/scenes/scene.rb', line 6 def initialize super @type = 'Scene' @auto_update = true end |
Instance Attribute Details
#auto_update ⇒ Object
Returns the value of attribute auto_update.
4 5 6 |
# File 'lib/mittsu/scenes/scene.rb', line 4 def auto_update @auto_update end |
#fog ⇒ Object
Returns the value of attribute fog.
4 5 6 |
# File 'lib/mittsu/scenes/scene.rb', line 4 def fog @fog end |
#override_material ⇒ Object
Returns the value of attribute override_material.
4 5 6 |
# File 'lib/mittsu/scenes/scene.rb', line 4 def override_material @override_material end |
Instance Method Details
#clone(object = Scene.new) ⇒ Object
14 15 16 17 18 19 20 21 22 23 |
# File 'lib/mittsu/scenes/scene.rb', line 14 def clone(object = Scene.new) super object.fog = fog unless fog.nil? object.override_material = override_material unless override_material.nil? object.auto_update = auto_update object.matrix_auto_update = matrix_auto_update object end |
#project(renderer) ⇒ Object
3 4 5 6 7 |
# File 'lib/mittsu/renderers/opengl/scenes/scene.rb', line 3 def project(renderer) @renderer = renderer return unless visible project_children end |