Class: Artoo::Drivers::Leapmotion::Frame
- Inherits:
-
Object
- Object
- Artoo::Drivers::Leapmotion::Frame
- Defined in:
- lib/artoo/drivers/leapmotion/frame.rb
Instance Attribute Summary collapse
-
#gestures ⇒ Object
readonly
Returns the value of attribute gestures.
-
#hands ⇒ Object
readonly
Returns the value of attribute hands.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#pointables ⇒ Object
readonly
Returns the value of attribute pointables.
-
#r ⇒ Object
readonly
Returns the value of attribute r.
-
#s ⇒ Object
readonly
Returns the value of attribute s.
-
#t ⇒ Object
readonly
Returns the value of attribute t.
-
#timestamp ⇒ Object
readonly
Returns the value of attribute timestamp.
Instance Method Summary collapse
-
#initialize(data) ⇒ Frame
constructor
A new instance of Frame.
Constructor Details
#initialize(data) ⇒ Frame
Returns a new instance of Frame.
11 12 13 14 15 16 17 18 19 20 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 11 def initialize(data) @hands = Artoo::Drivers::Leapmotion::Hand.list(data) @gestures = Artoo::Drivers::Leapmotion::Gesture.list(data) @pointables = Artoo::Drivers::Leapmotion::Pointable.list(data) @id = data["id"] @timestamp = data["timestamp"] @r = data["r"] @s = data["s"] @t = data["t"] end |
Instance Attribute Details
#gestures ⇒ Object (readonly)
Returns the value of attribute gestures.
10 11 12 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 10 def gestures @gestures end |
#hands ⇒ Object (readonly)
Returns the value of attribute hands.
10 11 12 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 10 def hands @hands end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
10 11 12 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 10 def id @id end |
#pointables ⇒ Object (readonly)
Returns the value of attribute pointables.
10 11 12 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 10 def pointables @pointables end |
#r ⇒ Object (readonly)
Returns the value of attribute r.
10 11 12 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 10 def r @r end |
#s ⇒ Object (readonly)
Returns the value of attribute s.
10 11 12 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 10 def s @s end |
#t ⇒ Object (readonly)
Returns the value of attribute t.
10 11 12 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 10 def t @t end |
#timestamp ⇒ Object (readonly)
Returns the value of attribute timestamp.
10 11 12 |
# File 'lib/artoo/drivers/leapmotion/frame.rb', line 10 def @timestamp end |