Options
All
  • Public
  • Public/Protected
  • All
Menu

The plane constraint is used for dragging and allows to specify a plane on which an object can be dragged. The transformation and optional rotation of this constraint get applied to the node if it is the constraint with the closest distance to the ray that was used for the drag event. As this is a difficult topic, please visit our help desk section on interactions where we go through the process of setting everything up with examples.

deprecated

This class is deprecated and will be removed in the future. Please use the PlaneRestriction instead.

Hierarchy

  • PlaneConstraint

Implements

  • IDragConstraint

Index

Constructors

  • new PlaneConstraint(_normal: vec3, _coplanarPoint?: vec3, _rotation?: { angle: number; axis: vec3 }): PlaneConstraint
  • Parameters

    • _normal: vec3

      the normal vector of the plane

    • Optional _coplanarPoint: vec3

      a coplanar point on the plane

    • Optional _rotation: { angle: number; axis: vec3 }

      the rotation in axis-angle representation that is applied to the node if the drag contraint becomes active

      • angle: number
      • axis: vec3

    Returns PlaneConstraint

Accessors

  • get coplanarPoint(): undefined | vec3
  • Returns undefined | vec3

  • get normal(): vec3
  • Returns vec3

  • get rotation(): undefined | { angle: number; axis: vec3 }
  • Returns undefined | { angle: number; axis: vec3 }