Contents

init(constrainedToAxis:minimumAngleDelta:inputKinds:)

Creates a rotation gesture with a minimum delta for the gesture to start, an axis to constrain measurement of rotation, and the input kinds the gesture should recognize.

Declaration

nonisolated init(constrainedToAxis: RotationAxis3D? = nil, minimumAngleDelta: Angle = .degrees(1), inputKinds: GestureInputKinds = .all)

Parameters

  • constrainedToAxis:

    The 3D axis about which rotation is measured.

  • minimumAngleDelta:

    The minimum delta required before the gesture starts. The default value is a one-degree angle.

  • inputKinds:

    A set of input kinds that this gesture recognizes. If not specified, the gesture will recognize all applicable input kinds that a person can use to perform it.

Discussion

If the constrained axis is nil, the gesture measures unconstrained 3D rotation.

See Also

Creating the gesture