Reference · Facts, line drawings and positions
portraitfunction
A pose from a tilt, a pitch, a phase and a spin: the body as a portrait, with the Sun a little above the left. The same arguments always give the same pose.
Import it
import { portrait } from "@johnmorrisdotca/wakusei-planets";
Definition
function portrait(id: BodyId, options?: PortraitOptions): Pose
Parameters
| Name | Type | Description |
|---|---|---|
id | BodyId | The body's name. |
options (optional) | PortraitOptions | The pose's tilt, pitch, phase and spin. |
Returns
Pose
The pose, as unit vectors in the viewer's frame.
Examples
import { portrait } from "@johnmorrisdotca/wakusei-planets";
const pose = portrait("mars", { phase: 90 });
console.log(pose.light[0] < -0.9);trueWhat it prints (run when this page was built)