Raycaster constructor
Implementation
Raycaster([Vector3? origin, Vector3? direction, num? near, num? far]) {
ray = Ray(origin, direction);
// direction is assumed to be normalized (for accurate distance calculations)
this.near = near ?? 0;
this.far = far ?? double.infinity;
layers = Layers();
params = {
"Mesh": {},
"Line": {"threshold": 1},
"LOD": {},
"Points": {"threshold": 1},
"Sprite": {}
};
}