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

x/threejs_4_deno/src/math/Quaternion.d.ts>Quaternion#setFromAxisAngle

A simple transformation of three.js for use within a Deno workflow
Go to Latest
method Quaternion.prototype.setFromAxisAngle
import { Quaternion } from "https://deno.land/x/threejs_4_deno@v121/src/math/Quaternion.d.ts";

Sets this quaternion from rotation specified by axis and angle. Adapted from http://www.euclideanspace.com/maths/geometry/rotations/conversions/angleToQuaternion/index.htm. Axis have to be normalized, angle is in radians.

Parameters

axis: Vector3
angle: number