Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/remapper/src/deps.ts>three.Raycaster#setFromCamera

A framework for Beat Saber map scripting.
Go to Latest
method three.Raycaster.prototype.setFromCamera
Re-export
import { three } from "https://deno.land/x/remapper@2.1.0/src/deps.ts";
const { Raycaster } = three;

Updates the ray with a new origin and direction.

Parameters

coords: { x: number; y: number; }

2D coordinates of the mouse, in normalized device coordinates (NDC)---X and Y components should be between -1 and 1.

camera: Camera

camera from which the ray should originate