Class: Disp3D::PickedResult

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(node_path_info_ary, screen_position, world_position, near, far) ⇒ PickedResult

Returns a new instance of PickedResult.



11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/picked_result.rb', line 11

def initialize(node_path_info_ary, screen_position, world_position, near, far)
  Util3D.check_arg_type(Array, node_path_info_ary)
  Util3D.check_arg_type(Vector3, screen_position)
  Util3D.check_arg_type(Vector3, world_position)
  Util3D.check_arg_type(::Numeric, near)
  Util3D.check_arg_type(::Numeric, far)

  @node_path_info = node_path_info_ary
  @screen_position = screen_position
  @world_position = world_position
  @near = near
  @far = far
end

Instance Attribute Details

#farObject (readonly)

Returns the value of attribute far.



9
10
11
# File 'lib/picked_result.rb', line 9

def far
  @far
end

#nearObject (readonly)

Returns the value of attribute near.



8
9
10
# File 'lib/picked_result.rb', line 8

def near
  @near
end

#node_path_infoObject (readonly)

Array of NodeInfo



5
6
7
# File 'lib/picked_result.rb', line 5

def node_path_info
  @node_path_info
end

#screen_positionObject (readonly)

Returns the value of attribute screen_position.



7
8
9
# File 'lib/picked_result.rb', line 7

def screen_position
  @screen_position
end

#world_positionObject (readonly)

Returns the value of attribute world_position.



6
7
8
# File 'lib/picked_result.rb', line 6

def world_position
  @world_position
end