spacemap 0.1.13 → 0.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/dist/spacemap.iife.js +607 -232
- package/dist/spacemap.js +607 -232
- package/index.d.ts +42 -13
- package/index.js +2135 -568
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -479,6 +479,8 @@ export declare class FlatMap {
|
|
|
479
479
|
private projectionOptions;
|
|
480
480
|
private view;
|
|
481
481
|
private limits;
|
|
482
|
+
/** True when the host gave no `maxZoom`. The map then sets its own limit. */
|
|
483
|
+
private ownMaxZoom;
|
|
482
484
|
/** The reader has moved the view since the last programmatic one, so the
|
|
483
485
|
* limits apply to it. A {@link setView} lands where it was told. */
|
|
484
486
|
private limitsArmed;
|
|
@@ -494,6 +496,10 @@ export declare class FlatMap {
|
|
|
494
496
|
/** Pictures the export does not have. Remembered, or every pan would ask
|
|
495
497
|
* for them again and report the same failure. */
|
|
496
498
|
private readonly missing;
|
|
499
|
+
/** The tile windows of each picture layer that has a pyramid. */
|
|
500
|
+
private readonly tiles;
|
|
501
|
+
/** `performance.now()` of the last tile plan. */
|
|
502
|
+
private plannedAt;
|
|
497
503
|
/** Bumped whenever the map moves to another body, so work started for the
|
|
498
504
|
* one being left can tell that it is no longer wanted. */
|
|
499
505
|
private generation;
|
|
@@ -599,13 +605,15 @@ export declare class FlatMap {
|
|
|
599
605
|
setView(view: Partial<FlatViewState>): void;
|
|
600
606
|
/**
|
|
601
607
|
* Replace the reader's limits, whole. What the new set leaves out is
|
|
602
|
-
* unrestricted again, except `maxZoom`, which goes back to
|
|
608
|
+
* unrestricted again, except `maxZoom`, which goes back to the map's own:
|
|
609
|
+
* 16, or more where the surface has tiles.
|
|
603
610
|
*
|
|
604
611
|
* Limits gate reader input only: {@link setView} lands where it was told,
|
|
605
612
|
* and the reader's next gesture brings the view back inside.
|
|
606
613
|
*/
|
|
607
614
|
setLimits(limits: FlatMapLimits): this;
|
|
608
|
-
/** The limits as they stand.
|
|
615
|
+
/** The limits as they stand. Where the host gave no `maxZoom`, it is the
|
|
616
|
+
* map's own for the place in the middle of the frame. */
|
|
609
617
|
getLimits(): FlatMapLimits;
|
|
610
618
|
/** The moment the map is of. Moves the clouds and, on Earth, the season. */
|
|
611
619
|
setTime(jd: number): void;
|
|
@@ -661,6 +669,33 @@ export declare class FlatMap {
|
|
|
661
669
|
private rasterFor;
|
|
662
670
|
/** Release every claim this map holds on the shared pictures. */
|
|
663
671
|
private dropTextures;
|
|
672
|
+
/** The tiles of a layer, where this host draws them and the pyramid holds
|
|
673
|
+
* more than the picture under it. */
|
|
674
|
+
private tilesOf;
|
|
675
|
+
/** The first level that holds more than the picture under the tiles. An
|
|
676
|
+
* equirectangular map draws that picture whole, and the others sample a
|
|
677
|
+
* copy of a limited width. */
|
|
678
|
+
private firstTileLevel;
|
|
679
|
+
/** What the tile plan reads of a frame. `density` is the number of drawn
|
|
680
|
+
* pixels for each pixel of `viewport`. Undefined when the middle of the
|
|
681
|
+
* frame is off the world. */
|
|
682
|
+
private frameSample;
|
|
683
|
+
/** Ask for the tile windows of the frame, layer by layer. */
|
|
684
|
+
private planTiles;
|
|
685
|
+
/** Whether the reader can move the map. */
|
|
686
|
+
private moves;
|
|
687
|
+
private dropTiles;
|
|
688
|
+
/**
|
|
689
|
+
* How far in the reader can go when the host gives no limit. Where tiles
|
|
690
|
+
* serve, it is the zoom that draws the finest tiles under the middle of the
|
|
691
|
+
* frame at `MAX_TILE_STRETCH`.
|
|
692
|
+
*/
|
|
693
|
+
private pictureMaxZoom;
|
|
694
|
+
/** The limits that hold the view. Where tiles serve, the map's own zoom
|
|
695
|
+
* limit changes from place to place. It then only stops the way in, and
|
|
696
|
+
* does not pull back a view that is past it. */
|
|
697
|
+
private heldLimits;
|
|
698
|
+
/* Excluded from this release type: tileStepDeg */
|
|
664
699
|
private viewport;
|
|
665
700
|
/** Draw on the next frame. Repeated calls in one frame draw once. */
|
|
666
701
|
render(): void;
|
|
@@ -736,6 +771,7 @@ export declare type FlatMapGesture = 'dragPan' | 'scrollZoom';
|
|
|
736
771
|
export declare interface FlatMapLimits {
|
|
737
772
|
/** 1 is the whole world; the reader may not go under it either way. */
|
|
738
773
|
minZoom?: number;
|
|
774
|
+
/** Left out, the map sets its own: 16, or more where the surface has tiles. */
|
|
739
775
|
maxZoom?: number;
|
|
740
776
|
/** The band of the surface the middle of the frame may sit in. A longitude
|
|
741
777
|
* band may run through the antimeridian: 170 to −170 is the twenty degrees
|
|
@@ -974,8 +1010,8 @@ export declare type Interpolation =
|
|
|
974
1010
|
* track means by a straight line. */
|
|
975
1011
|
| 'geodesic';
|
|
976
1012
|
|
|
977
|
-
/**
|
|
978
|
-
*
|
|
1013
|
+
/** True when the terms of this host allow the sphere of the stop, so the view
|
|
1014
|
+
* can open it. */
|
|
979
1015
|
export declare function isViewable(entry: PanoramaEntry): boolean;
|
|
980
1016
|
|
|
981
1017
|
/** Convert a Julian Date to a JS Date. */
|
|
@@ -1319,9 +1355,8 @@ export declare interface PanoramaEntry {
|
|
|
1319
1355
|
altitude_m?: number;
|
|
1320
1356
|
title?: string;
|
|
1321
1357
|
/** Image azimuth of true north, degrees clockwise from the left edge.
|
|
1322
|
-
* Zero, and meaningless, where `orientation` is `unknown
|
|
1323
|
-
|
|
1324
|
-
north_offset_deg?: number;
|
|
1358
|
+
* Zero, and meaningless, where `orientation` is `unknown`. */
|
|
1359
|
+
north_offset_deg: number;
|
|
1325
1360
|
/** How north was established, absent where the archive itself states it.
|
|
1326
1361
|
* `unknown` means the sphere sits at an arbitrary azimuth, so nothing
|
|
1327
1362
|
* may be drawn or written as a heading. The full set `export/panoramas.py`
|
|
@@ -1344,9 +1379,6 @@ export declare interface PanoramaEntry {
|
|
|
1344
1379
|
credit?: string;
|
|
1345
1380
|
credit_url?: string;
|
|
1346
1381
|
source_url?: string;
|
|
1347
|
-
/** `withheld` where the release's reuse terms are unsettled: the stop is
|
|
1348
|
-
* published as a place and a date, and no texture exists to fetch. */
|
|
1349
|
-
imagery?: 'withheld';
|
|
1350
1382
|
/** How far down the host's texture ladder this sphere may be drawn; absent
|
|
1351
1383
|
* where its terms allow any use. */
|
|
1352
1384
|
distribution?: TextureDistribution;
|
|
@@ -1361,9 +1393,6 @@ export declare interface PanoramaMissionSummary {
|
|
|
1361
1393
|
count: number;
|
|
1362
1394
|
first_time: string;
|
|
1363
1395
|
last_time: string;
|
|
1364
|
-
/** False where no stop on the traverse publishes a sphere: the places are
|
|
1365
|
-
* on the map, and there is nothing to open. */
|
|
1366
|
-
imagery?: boolean;
|
|
1367
1396
|
}
|
|
1368
1397
|
|
|
1369
1398
|
export declare class PanoramaView {
|