リファレンス
データの入口(自分で用意した星やディープスカイ天体を、ライセンスと出典つきのソースとして渡し、いま画面にあるのは誰のデータかを示します)
import { … } from "@johnmorrisdotca/hoshi-stars/door";
最小化と gzip 圧縮をしたサイズは 7.0 kB(読み込むものをすべて含み、esbuild で計測)
リファレンスの説明と例は英語です。見出しと目次は日本語です。
エクスポート
| 名前 | 種類 | 概要 |
|---|---|---|
BitmapLike | 型 | What a picture needs of its bitmap: an ImageBitmap fits. |
createTileStore | 関数 | A tile store for a view: loads the tiles of every source by key and keeps them under one budget of bytes (default 48 MB, all sources together). |
Credit | 型 | One source's part in the last drawn frame. |
creditLine | 関数 | The credit line for what a view drew: each source's credit with its licence name, and "non-commercial" or "share-alike" whenever the source says so, so a page cannot hide the terms of the data it uses. |
DataSource | 型 | Either kind of source. |
ImageTile | 型 | A map tile: its size in pixels and its picture. |
Licence | 型 | A licence: its name and a link are always shown beside the credit. |
loadRecords | 関数 | Reads a record source once, when it is added: the list is frozen, a record with a non-finite number (a NaN or an infinity in any number finite names) is skipped and counted, and a list over MAX_RECORDS is refused whole (bigger data must be tiles). |
MapPlace | 型 | A piece of a map, in degrees: longitude and latitude (right ascension and declination for the sky). |
MAX_IN_FLIGHT | 定数 | The most loads in flight at once for one source. |
MAX_RECORDS | 定数 | The most records a record source may hold. |
ObjectSource | 型 | A source of deep-sky objects: a list that fits in memory (at most 200,000 records), read once. |
ObjectsRead | 型 | What withObjects found. |
OWN_SOURCES | 定数 | The package's own data, as sources, written from the rows of NOTICE.md: the Yale Bright Star Catalogue, UCAC4 and the deep-sky list from Wikidata. |
ownCredit | 関数 | The credit of one of the package's own sources, for the part of a page the door does not draw: the bright stars of the Yale catalogue are drawn from the main entry, so a page puts ownCredit("yale-bsc", count) first in its credit line. |
RecordSource | 型 | A list that fits in memory (at most MAX_RECORDS records; bigger data must be tiles). |
RecordsRead | 型 | What loadRecords found. |
SkyPictureSource | 型 | A source of a picture of the sky in tiles (a survey, an all-sky photograph): a map source, which uses the family's one map shape. |
SourceInfo | 型 | What a source says about itself. |
starSky | 関数 | The faint stars of a page, from any number of tile sources: the door's view of the sky. |
StarSky | 型 | The faint stars of a page from any number of sources: loads the tiles a patch needs from each and answers from the ones it has. |
StarSkyOptions | 型 | What starSky takes. |
StarSource | 型 | A source of stars in tiles: the place is a round patch of sky (FaintField), the detail is the faintest magnitude wanted, and a tile is the decoded FaintTile (parallel arrays of right ascension, declination, magnitude and B-V). |
TILE_BUDGET_BYTES | 定数 | The default budget for decoded tiles in a view, all sources together: 48 MB (a picture counts with its mipmaps, 4/3 of its bytes). |
TileFetch | 型 | A fetch as the loaders use it: the address and, for a stop, a signal. |
TileLoader | 型 | The part of a tile source the store uses. |
TileSource | 型 | Data cut by place and by detail. |
TileStats | 型 | What a tile store has done. |
TileStore | 型 | A tile store: tiles by source and key, under one byte budget. |
TileStoreOptions | 型 | Options for createTileStore. |
Ucac4Options | 型 | What ucac4Source takes. |
ucac4Source | 関数 | The package's own faint stars, UCAC4 to magnitude 12 in sky tiles, as a source: what faintSky has always loaded, through the door. |
validateSource | 関数 | Refuses a source that cannot be shown honestly: it throws a TypeError at once, when a source is added, not at the first draw. |
withObjects | 関数 | Adds the deep-sky objects of outside sources to the page's own. |
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。