class
Hamilton::Types::MaskPosition
- Hamilton::Types::MaskPosition
- Reference
- Object
Overview
This object describes the position on faces where a mask should be placed by default.
Included Modules
- Hamilton::Types::Common
- JSON::Serializable
Defined in:
types/mask_position.crConstructors
- .new(pull : JSON::PullParser)
- .new(params)
- .new(*, __pull_for_json_serializable pull : JSON::PullParser)
- .new(**params)
Instance Method Summary
-
#non_nil_fields : Array(String)
List of available non-nil fields.
-
#non_nil_fields=(non_nil_fields : Array(String))
List of available non-nil fields.
-
#point : String
The part of the face relative to which the mask should be placed.
-
#point=(point : String)
The part of the face relative to which the mask should be placed.
-
#scale : Float32
Mask scaling coefficient.
-
#scale=(scale : Float32)
Mask scaling coefficient.
-
#x_shift : Float32
Shift by X-axis measured in widths of the mask scaled to the face size, from left to right.
-
#x_shift=(x_shift : Float32)
Shift by X-axis measured in widths of the mask scaled to the face size, from left to right.
-
#y_shift : Float32
Shift by Y-axis measured in heights of the mask scaled to the face size, from top to bottom.
-
#y_shift=(y_shift : Float32)
Shift by Y-axis measured in heights of the mask scaled to the face size, from top to bottom.
Instance methods inherited from class Reference
==(other : Hamilton::Any)
==
Instance methods inherited from class Object
===(other : Hamilton::Any)
===
Constructor Detail
Instance Method Detail
The part of the face relative to which the mask should be placed. One of “forehead”, “eyes”, “mouth”, or “chin”.
The part of the face relative to which the mask should be placed. One of “forehead”, “eyes”, “mouth”, or “chin”.
Shift by X-axis measured in widths of the mask scaled to the face size, from left to right. For example, choosing -1.0 will place mask just to the left of the default mask position.
Shift by X-axis measured in widths of the mask scaled to the face size, from left to right. For example, choosing -1.0 will place mask just to the left of the default mask position.
Shift by Y-axis measured in heights of the mask scaled to the face size, from top to bottom. For example, 1.0 will place the mask just below the default mask position.
Shift by Y-axis measured in heights of the mask scaled to the face size, from top to bottom. For example, 1.0 will place the mask just below the default mask position.