Class: Gcloud::Vision::Annotation::Face::Features::Chin
- Inherits:
-
Object
- Object
- Gcloud::Vision::Annotation::Face::Features::Chin
- Defined in:
- lib/gcloud/vision/annotation/face.rb
Overview
# Chin
The landmarks of the chin in the features of a face.
Left and right are defined from the vantage of the viewer of the image, without considering mirror projections typical of photos. So ‘face.features.eyes.left` typically is the person’s right eye.
See Gcloud::Vision::Annotation::Face::Features and Gcloud::Vision::Annotation::Face.
Instance Attribute Summary collapse
-
#center ⇒ Landmark
readonly
The chin, gnathion.
-
#left ⇒ Landmark
readonly
The chin, left gonion.
-
#right ⇒ Landmark
readonly
The chin, right gonion.
Instance Method Summary collapse
-
#initialize(left, center, right) ⇒ Chin
constructor
A new instance of Chin.
- #inspect ⇒ Object
-
#to_a ⇒ Array
Returns the object’s property values as an array.
-
#to_ary ⇒ Array
Returns the object’s property values as an array.
-
#to_h ⇒ Hash
Deeply converts object to a hash.
-
#to_hash ⇒ Hash
Deeply converts object to a hash.
- #to_s ⇒ Object
Constructor Details
#initialize(left, center, right) ⇒ Chin
759 760 761 762 763 |
# File 'lib/gcloud/vision/annotation/face.rb', line 759 def initialize left, center, right @left = left @center = center @right = right end |
Instance Attribute Details
#center ⇒ Landmark (readonly)
The chin, gnathion.
754 755 756 |
# File 'lib/gcloud/vision/annotation/face.rb', line 754 def center @center end |
#left ⇒ Landmark (readonly)
The chin, left gonion.
754 755 756 |
# File 'lib/gcloud/vision/annotation/face.rb', line 754 def left @left end |
#right ⇒ Landmark (readonly)
The chin, right gonion.
754 755 756 |
# File 'lib/gcloud/vision/annotation/face.rb', line 754 def right @right end |
Instance Method Details
#inspect ⇒ Object
808 809 810 |
# File 'lib/gcloud/vision/annotation/face.rb', line 808 def inspect "#<Chin #{self}>" end |
#to_a ⇒ Array
Returns the object’s property values as an array.
770 771 772 |
# File 'lib/gcloud/vision/annotation/face.rb', line 770 def to_a to_ary end |
#to_ary ⇒ Array
Returns the object’s property values as an array.
779 780 781 |
# File 'lib/gcloud/vision/annotation/face.rb', line 779 def to_ary [left, center, right] end |
#to_h ⇒ Hash
Deeply converts object to a hash. All keys will be symbolized.
788 789 790 |
# File 'lib/gcloud/vision/annotation/face.rb', line 788 def to_h to_hash end |
#to_hash ⇒ Hash
Deeply converts object to a hash. All keys will be symbolized.
797 798 799 |
# File 'lib/gcloud/vision/annotation/face.rb', line 797 def to_hash { left: left.to_h, center: center.to_h, right: right.to_h } end |
#to_s ⇒ Object
802 803 804 805 |
# File 'lib/gcloud/vision/annotation/face.rb', line 802 def to_s format "(left: %s, center: %s, right: %s)", left.inspect, center.inspect, right.inspect end |