# Class: oPoint

## $. oPoint

$.oPoint Base Class

#### new $.oPoint(x, y, z)

openHarmony/openHarmony_math.js, line 68
  The $.oPoint helper class - representing a 3D point.

  Name | Type | Description
  --- | --- | ---
  `x` | float | Horizontal coordinate
  `y` | float | Vertical coordinate
  `z` | float | optional Depth Coordinate

  ##### Properties:

  Name | Type | Description
  --- | --- | ---
  `x` | float | Horizontal coordinate
  `y` | float | Vertical coordinate
  `z` | float | Depth Coordinate

### Methods

#### static$.oPoint.convertToOpenGL()

openHarmony/openHarmony_math.js, line 217
  Uses the scene settings to convert this as a worldspace point into an OpenGL point, used in underlying transformation operations in Harmony.

#### static$.oPoint.convertToWorldspace()

openHarmony/openHarmony_math.js, line 231
  Uses the scene settings to convert this as an OpenGL point into a Harmony worldspace point, used in all displayed modules and Harmony coordinates.

#### convertToDrawingSpace(){$.oPoint}

openHarmony/openHarmony_math.js, line 208
  Converts a scene coordinate point into a Drawing space coordinate, as used by Drawing tools and $.oShape

  ##### Returns:

  Type | Description
  --- | ---
  $.oPoint |

#### convertToSceneCoordinates(){$.oPoint}

openHarmony/openHarmony_math.js, line 198
  Converts a Drawing point coordinate into a scene coordinate, as used by pegs

  ##### Returns:

  Type | Description
  --- | ---
  $.oPoint |

#### divide(float_val)

openHarmony/openHarmony_math.js, line 169
  Divides all coordinates by this value.

  Name | Type | Description
  --- | --- | ---
  `float_val` | float | Divide all coordinates by this value.

#### lerp(point, perc)

openHarmony/openHarmony_math.js, line 249
  Linearily Interpolate between this (0.0) and the provided point (1.0)

  Name | Type | Description
  --- | --- | ---
  `point` | $.oPoint | The target point at 100%
  `perc` | double | 0-1.0 value to linearily interp

#### multiply(float_val)

openHarmony/openHarmony_math.js, line 155
  Multiply all coordinates by this value.

  Name | Type | Description
  --- | --- | ---
  `float_val` | float | Multiply all coordinates by this value.

#### pointAdd(add_pt)

openHarmony/openHarmony_math.js, line 127
  Adds the input box to the bounds of the current $.oBox.

  Name | Type | Description
  --- | --- | ---
  `add_pt` | $.oPoint | The point to add to this point.

#### pointAverage(point_array)

openHarmony/openHarmony_math.js, line 183
  Find average of provided points.

  Name | Type | Description
  --- | --- | ---
  `point_array` | Array.<$.oPoint> | The array of points to get the average.

#### pointSubtract(sub_pt)

openHarmony/openHarmony_math.js, line 141
  Subtracts the input box to the bounds of the current $.oBox.

  Name | Type | Description
  --- | --- | ---
  `sub_pt` | $.oPoint | The point to subtract to this point.

#### translate(x, y, z)

openHarmony/openHarmony_math.js, line 108
  Translate the point by the provided values.

  Name | Type | Description
  --- | --- | ---
  `x` | int | the x value to move the point by.
  `y` | int | the y value to move the point by.
  `z` | int | the z value to move the point by.