Hierarchy

Constructors

Properties

_cursor: Cursor
_oc: any
_ocVector: any
_x: number = 0
_y: number = 0
_z: number = 0

Accessors

  • get x(): number
  • Returns number

  • set x(x: number): void
  • Parameters

    • x: number

    Returns void

  • get y(): number
  • Returns number

  • set y(y: number): void
  • Parameters

    • y: number

    Returns void

  • get z(): number
  • Returns number

  • set z(z: number): void
  • Parameters

    • z: number

    Returns void

Methods

  • We got a Point array with relative coordinates: resolve into real numbers based on previous Point

    2 Types: - cartesian ['+10','-10'] - polar coordinates ['100<30'] or ['100<<20'] (relative angle)

    Parameters

    • pointArr: (string | number)[]
    • cursor: Cursor = null

    Returns number[]

  • Copy OC Vector from given Vector

    Parameters

    Returns void

  • Create Vector from OC Direction instance

    Parameters

    • ocDir: any

    Returns Vector

  • Set properties x,y,z from given or already wrapped OC gp_Vec instance

    Parameters

    • ocVec: any = null

    Returns Vector

  • Return the smallest angle between this and another Vector in degrees

    Parameters

    Returns number

  • Angle [0-360] on XY plane

    Returns number

  • Return the angles around the different axis !!!! Some of these values can be null - for example for [100,0,0] => rotation around X axis = null !!!!

    Returns number[]

  • Calculate Dot / Inner product with this and other Vector

    Parameters

    Returns number

  • Try to convert anything to a Vector mostly here for backwards compatibiliy TODO: slowly move this out since the constructor does the same

    Parameters

    • v: any
    • Rest ...args: any[]

    Returns Vector

  • Check if this Vector is normal to the another: abs(.Angle(Other) - PI/2.) <= AngularToleranc

    Parameters

    Returns boolean

  • Check if this Vector is the opposite of another Vector

    Parameters

    Returns boolean

  • Check if this Vector is parallel to another Vector

    Parameters

    Returns boolean

  • Get the axis that this Vector could represent, if not null

    Returns string

  • Return the magnitude/length of this Vector

    Returns any

  • Return the magnitude/length of this Vector

    Returns any

  • Multiple Vector with scalar (1D,2D,3D) and return current Vector We can multiple with one scalar or by axis with Array [x,y,z]

    Parameters

    Returns Vector

  • Calculate orthogonal projections from this Point to Edges/Wires of a given Shape A projected Point from an original Point to a Curve is the point on a other Shape where the line between the two points is perpendicular to the Curve at the projected Point

    Parameters

    Returns Point[]

  • Random Vector in a circle of given radius

    Parameters

    • radius: number = 1

    Returns Vector

  • Returns the X/Y/Z Plane that Vectors share

    Parameters

    Returns string[]

  • Return the squared magnitude/length of this Vector

    Returns any

  • Export entity and minimal data as string (used for outputting on console and hashing )

    Returns string

  • Parameters

    • obj: any

    Returns boolean

  • Parameters

    • obj: any

    Returns boolean

Generated using TypeDoc