MaskPosition class abstract
This object describes the position on faces where a mask should be placed by default.
- Annotations
-
- @freezed
Constructors
- MaskPosition.new({@JsonKey(name: 'point') required MaskPositionPoint point, @JsonKey(name: 'x_shift') required double xShift, @JsonKey(name: 'y_shift') required double yShift, @JsonKey(name: 'scale') required double scale})
-
Constructs a MaskPosition object
constfactory
-
MaskPosition.fromJson(Map<
String, dynamic> json) -
Creates a MaskPosition object from a JSON map
factory
Properties
-
copyWith
→ $MaskPositionCopyWith<
MaskPosition> -
Create a copy of MaskPosition
with the given fields replaced by the non-null parameter values.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- point → MaskPositionPoint
-
The part of the face relative to which the mask should be placed. One of
"forehead", "eyes", "mouth", or "chin".
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scale → double
-
Mask scaling coefficient. For example, 2.0 means double size.
no setterinherited
- xShift → double
-
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.
no setterinherited
- yShift → double
-
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.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
Serializes this MaskPosition to a JSON map.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited