Skip to content

format

typescript
Ray.Clone(val)

class: Ray

description

This is a static function that copies the given Ray object and returns a new Ray object.

parameter

param_nametypedescription
valRayThe Ray object to be copied.

return

typedescription
RayA new Ray object.

code example

typescript
 const ray = new Ray(new Vector3(0, 0, 0), new      
  Vector3(0, 0, 1));
 const ray2 = Ray.clone(ray);