リファレンス · 暗い星 (UCAC4の約300万個、12等まで。見ている空の部分のタイルだけを読み込みます)
FaintSky型
リファレンスの説明と例は英語です。見出しと目次は日本語です。
The faint stars of a page: loads the tiles a patch of sky needs, and answers from the ones it has.
インポート
import type { FaintSky } from "@johnmorrisdotca/hoshi-stars/faint";
定義
interface FaintSky {
load(field: FaintField, limit?: number): Promise<void>;
stars(field: FaintField, limit?: number, max?: number): {
stars: FaintStar[];
depth: number;
loaded: boolean;
};
readonly size: number;
}
メンバー
| 名前 | 型 | 説明 |
|---|---|---|
load | (field: FaintField, limit?: number): Promise<void> | Fetch the tiles the patch needs for stars to |
stars | (field: FaintField, limit?: number, max?: number): { stars: FaintStar[]; depth: number; loaded: boolean; } | The stars of the patch from the tiles that are here (see |
size | number | How many tiles are here. |
例
import { faintSky } from "@johnmorrisdotca/hoshi-stars/faint";
const sky = faintSky();
const orion = { rightAscension: 83.8, declination: -5.4, radius: 1 };
await sky.load(orion, 11);
console.log(sky.stars(orion, 11, 1000).stars.length);この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。