Raycaster

THREE.Raycaster
class Raycaster(var origin: UndefOr[Vector3], var direction: UndefOr[Vector3], var near: UndefOr[Double], var far: UndefOr[Double]) extends Object

This class is designed to assist with raycasting. Raycasting is used for mouse picking and more.

Attributes

Graph
Supertypes
class Object
trait Any
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def intersectObject(obj: Object3D, recursive: UndefOr[Boolean], optionalTarget: UndefOr[Array[RaycasterIntersection]]): Array[RaycasterIntersection]

Checks all intersection between the ray and the objects with or without the descendants. Intersections are returned sorted by distance, closest first.

Checks all intersection between the ray and the objects with or without the descendants. Intersections are returned sorted by distance, closest first.

Attributes

def intersectObjects(objects: Array[Object3D], recursive: UndefOr[Boolean], optionalTarget: UndefOr[Array[RaycasterIntersection]]): Array[RaycasterIntersection]

Checks all intersection between the ray and the array of objects. Intersections are returned sorted by distance, closest first.

Checks all intersection between the ray and the array of objects. Intersections are returned sorted by distance, closest first.

Attributes

def set(origin: Vector3, direction: Vector3): Unit

Updates the ray with a new origin and direction.

Updates the ray with a new origin and direction.

Attributes

def setFromCamera(coords: Vector2, camera: Camera): Unit

Updates the ray with new origin and direction.

Updates the ray with new origin and direction.

Attributes

Inherited methods

def hasOwnProperty(v: String): Boolean

Attributes

Inherited from:
Object
def isPrototypeOf(v: Object): Boolean

Attributes

Inherited from:
Object
def propertyIsEnumerable(v: String): Boolean

Attributes

Inherited from:
Object
def toLocaleString(): String

Attributes

Inherited from:
Object
def valueOf(): Any

Attributes

Inherited from:
Object

Concrete fields

var direction: UndefOr[Vector3]
var far: UndefOr[Double]
var near: UndefOr[Double]
var origin: UndefOr[Vector3]
var params: Dynamic

This value can be used to filter away intersections that are closer than the value.

This value can be used to filter away intersections that are closer than the value.

Attributes

val ray: Ray

The Ray used for the raycasting.

The Ray used for the raycasting.

Attributes