Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Ray

A 3d ray used, for example, for picking on the 3D model.

Hierarchy

  • Ray

Index

Constructors

constructor

Accessors

direction

direction: Vec3Like

The direction vector of the ray in world coordinates.

origin

origin: Vec3Like

The origin of the ray in world coordinates.

Methods

clone

  • Returns a clone of the ray.

    Returns Ray

pointDistanceSquared

  • pointDistanceSquared(point: Vec3Like): number
  • Returns the squared distance from the point to the ray

    Parameters

    Returns number

transform

  • transform(matrix: Mat4): void
  • Transforms the ray with the given matrix.

    The origin will be transformed as a point, and the direction as a vector.

    Parameters

    Returns void

Generated using TypeDoc