Reference · The Sun, Moon and planets: pure parts
RidePosetype
The camera ridePose works out: where it is, which way it looks, which way is up in the picture, its field of view in degrees, and how big the Earth looks from there (its angular radius in degrees).
Import it
import type { RidePose } from "@johnmorrisdotca/chikyu-earth/space";
Definition
interface RidePose {
position: Vec3;
forward: Vec3;
up: Vec3;
fov: number;
earthRadiusDegrees: number;
}
Members
| Name | Type | Description |
|---|---|---|
position | Vec3 | |
forward | Vec3 | |
up | Vec3 | |
fov | number | |
earthRadiusDegrees | number |
Examples
import type { RidePose } from "@johnmorrisdotca/chikyu-earth/space";
const describe = (pose: RidePose): string => `looking ${pose.forward.map((n) => n.toFixed(2)).join(",")} with a ${pose.fov} degree view`;
console.log(typeof describe);functionWhat it prints (run when this page was built)