リファレンス
太陽、月、惑星: 計算部分
import { … } from "@johnmorrisdotca/chikyu-earth/space";
リファレンスの説明と例は英語です。見出しと目次は日本語です。
エクスポート
| 名前 | 種類 | 概要 |
|---|---|---|
AU_IN_EARTH_RADII | 定数 | Earth radii in one astronomical unit. |
blend | 関数 | A frame between two others, t from 0 to 1. |
BodyDrawing | 型 | One body as drawn by a painter: an object of radius 1 at the origin, which the scene places, scales and (for the Sun) turns to face the camera. |
BodyMoon | 型 | One moon of a planet at a moment: its name, where it is from the planet's centre and how big it is, both in radii of the planet, in scene axes. |
BodyPainter | 型 | The seam for drawing the Sun, the planets and their moons. |
compress | 関数 | The same direction at a compressed distance from the Earth: the Moon is 10 Earth radii away, and a body k times further than the Moon is k^0.25 times as far here. |
createTrack | 関数 | Answers for any moment from two real ones: at(ms) asks astronomy-engine only when ms leaves the span the last two answers cover, and then looks stepMs ahead, so playing time at a steady rate costs one pair of lookups every stepMs and every draw in between is arithmetic. |
EARTH_RADIUS_KM | 定数 | The Earth's radius in kilometres, the unit of the scene's distances. |
Frame | 型 | Where everything is at one moment: positions in astronomical units from the Earth's centre, in scene axes (x to the vernal equinox, y north, z toward -y of the equator). |
frameAt | 関数 | The state of the sky at ms: nine vectors and an angle, in a few tenths of a millisecond. |
MOON_COMPRESSED | 定数 | The Moon's distance in a compressed view, in Earth radii (the true one is about 60). |
orbitPath | 関数 | The path a planet takes round the Sun, as count points around the orbit that starts where the planet is at ms, relative to the Sun (scene axes, AU). |
PaintContext | 型 | What the scene tells a painter when it makes a body. |
placeAround | 関数 | A place helio astronomical units from the Sun (a planet, or a point on its orbit), round the Sun at sun. |
placeMoon | 関数 | The Moon, from the Earth's centre. |
placeSun | 関数 | The Sun, from the Earth's centre: in a compressed view always 44 Earth radii away, in its real direction. |
plainPainter | 定数 | The default look: a sphere in the planet's colour, lit by the Sun, and for the Sun a glowing disc. |
PlanetName | 型 | One of the planets drawn (Pluto too), by name. |
PLANETS | 定数 | The planets drawn, nearest the Sun first. |
RADIUS | 定数 | Radii in Earth radii: the real ones, and ones large enough to see in a compressed view. |
RIDE_FOV | 定数 | The field of view, in degrees, of a camera riding along at zoom 1 (the Earth's view from outside is 35). |
RideInput | 型 | What ridePose is asked: the camera's place and its way of travel (any length), where it looks, and the shared controls' yaw, tilt and zoom. |
RideLook | 型 | Where a riding camera looks: down straight at the Earth's centre (the ground goes by under the camera), or horizon tipped forward along the way it is going until the horizon is a little above the middle of the view. |
ridePose | 関数 | The camera of a body-borne view: at position, looking at the Earth, with the way the body is going at the top of the picture. |
RidePose | 型 | 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). |
ScaleMode | 型 | The scale the space view is drawn in: compressed squeezes the distances so the Moon, the Sun and Neptune fit one view, and true keeps the real ones. |
SUN_COMPRESSED | 定数 | The Sun's distance from the Earth in a compressed view, in Earth radii (the true one is about 23,500). |
truePosition | 関数 | A place in astronomical units from the Earth's centre, at true distance, in Earth radii. |
Vec3 | 型 | A position or direction as [x, y, z], in the scene's axes (x toward the vernal equinox, y north). |
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。