@giro3d/piero 1.0.0-beta.2 → 1.0.0-beta.4
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/dist/Components.cjs.js +3 -2
- package/dist/Components.cjs.js.map +1 -1
- package/dist/Components.es.js +3193 -1778
- package/dist/Components.es.js.map +1 -1
- package/dist/assets/piero.css +2 -2
- package/dist/index.cjs.js +7 -7
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +3192 -4319
- package/dist/index.es.js.map +1 -1
- package/dist/modules.cjs.js +1 -2
- package/dist/modules.cjs.js.map +1 -1
- package/dist/modules.es.js +981 -965
- package/dist/modules.es.js.map +1 -1
- package/dist/src/api/SearchApi.d.ts +34 -0
- package/dist/src/api/ViewApi.d.ts +2 -0
- package/dist/src/api/WidgetApi.d.ts +17 -0
- package/dist/src/api/index.d.ts +2 -1
- package/dist/src/components/CoordinateInput.vue.d.ts +31 -0
- package/dist/src/components/SearchOverlay.vue.d.ts +4 -5
- package/dist/src/context.d.ts +10 -0
- package/dist/src/events.d.ts +7 -1
- package/dist/src/modules/OpenLayersMinimap.d.ts +7 -0
- package/dist/src/modules/PostProcessEntities.d.ts +16 -0
- package/dist/src/modules/crossSectionAnalysis/CrossSection.vue.d.ts +1 -1
- package/dist/src/modules/crossSectionAnalysis/CrossSectionHelper.d.ts +4 -0
- package/dist/src/modules/crossSectionAnalysis/CrossSectionManager.d.ts +7 -0
- package/dist/src/modules/crossSectionAnalysis/store.d.ts +22 -2
- package/dist/src/modules/geocoding/CoordinatesSearch.d.ts +7 -0
- package/dist/src/modules/geocoding/FrenchBanGeocoder.d.ts +10 -0
- package/dist/src/modules/index.d.ts +5 -1
- package/dist/src/modules/minimap/OpenLayersMinimapComponent.vue.d.ts +8 -0
- package/dist/src/services/CameraController.d.ts +3 -3
- package/dist/src/services/Giro3DManager.d.ts +2 -0
- package/dist/src/services/SceneCursorManager.d.ts +19 -0
- package/dist/src/stores/giro3d.d.ts +1 -7
- package/dist/src/stores/search.d.ts +12 -0
- package/dist/src/stores/widgets.d.ts +12 -0
- package/dist/src/utils/Types.d.ts +1 -0
- package/package.json +2 -2
- package/dist/src/components/MinimapView.vue.d.ts +0 -4
- package/dist/src/providers/BanProvider.d.ts +0 -11
- package/dist/src/providers/Geocoding.d.ts +0 -7
- package/dist/src/services/MinimapController.d.ts +0 -19
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { default as Coordinates } from '@giro3d/giro3d/core/geographic/Coordinates';
|
|
2
|
+
import { SearchStore } from '../stores/search';
|
|
3
|
+
export interface LocationSearchResult extends SearchResult {
|
|
4
|
+
coordinates: Coordinates;
|
|
5
|
+
}
|
|
6
|
+
export interface SearchApi {
|
|
7
|
+
registerProvider(provider: SearchProvider): void;
|
|
8
|
+
}
|
|
9
|
+
export interface SearchProvider<T extends SearchResult = SearchResult> {
|
|
10
|
+
/**
|
|
11
|
+
* The name of the provider, as displayed in the search results.
|
|
12
|
+
*/
|
|
13
|
+
name: string;
|
|
14
|
+
/**
|
|
15
|
+
* Executes a search for the specified query string.
|
|
16
|
+
*/
|
|
17
|
+
search(query: string): Promise<T[]>;
|
|
18
|
+
}
|
|
19
|
+
export interface SearchResult {
|
|
20
|
+
/**
|
|
21
|
+
* The label to display in the search results.
|
|
22
|
+
*/
|
|
23
|
+
label: string;
|
|
24
|
+
/**
|
|
25
|
+
* The search provider used to perform the search.
|
|
26
|
+
*/
|
|
27
|
+
provider: SearchProvider;
|
|
28
|
+
}
|
|
29
|
+
export declare class SearchApiImpl implements SearchApi {
|
|
30
|
+
private readonly searchStore;
|
|
31
|
+
constructor(searchStore: SearchStore);
|
|
32
|
+
registerProvider(provider: SearchProvider): void;
|
|
33
|
+
}
|
|
34
|
+
export declare function isLocationSearchResult(result: SearchResult): result is LocationSearchResult;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { default as Instance } from '@giro3d/giro3d/core/Instance';
|
|
2
2
|
import { Box3 } from '../../../../node_modules/three';
|
|
3
3
|
import { default as CameraController } from '../services/CameraController';
|
|
4
|
+
import { default as SceneCursorManager } from '../services/SceneCursorManager';
|
|
4
5
|
export default interface ViewApi {
|
|
5
6
|
getBoundingBox(): Box3;
|
|
6
7
|
getCameraController(): CameraController;
|
|
7
8
|
getInstance(): Instance;
|
|
9
|
+
getSceneCursorManager(): SceneCursorManager;
|
|
8
10
|
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Component } from 'vue';
|
|
2
|
+
import { PieroContext } from '../context';
|
|
3
|
+
import { WidgetStore } from '../stores/widgets';
|
|
4
|
+
export interface Widget {
|
|
5
|
+
component: Component<{
|
|
6
|
+
context: PieroContext;
|
|
7
|
+
}>;
|
|
8
|
+
id: string;
|
|
9
|
+
}
|
|
10
|
+
export declare class WidgetApiImpl implements WidgetApi {
|
|
11
|
+
private readonly store;
|
|
12
|
+
constructor(store: WidgetStore);
|
|
13
|
+
addWidget(widget: Widget): void;
|
|
14
|
+
}
|
|
15
|
+
export default interface WidgetApi {
|
|
16
|
+
addWidget(widget: Widget): void;
|
|
17
|
+
}
|
package/dist/src/api/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { default as BookmarkApi } from './BookmarkApi';
|
|
2
2
|
import { default as DatasetApi, DatasetActionRegistrationParams, DatasetRegistrationParams } from './DatasetApi';
|
|
3
|
+
import { SearchApi, SearchProvider, SearchResult } from './SearchApi';
|
|
3
4
|
import { default as ViewApi } from './ViewApi';
|
|
4
|
-
export { BookmarkApi, DatasetActionRegistrationParams, DatasetApi, DatasetRegistrationParams, ViewApi, };
|
|
5
|
+
export { BookmarkApi, DatasetActionRegistrationParams, DatasetApi, DatasetRegistrationParams, SearchApi, SearchProvider, SearchResult, ViewApi, };
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { default as Instance } from '@giro3d/giro3d/core/Instance';
|
|
2
|
+
import { Vector3 } from '../../../../node_modules/three';
|
|
3
|
+
import { default as Coordinates } from '@giro3d/giro3d/core/geographic/Coordinates';
|
|
4
|
+
import { default as SceneCursorManager } from '../services/SceneCursorManager';
|
|
5
|
+
type __VLS_Props = {
|
|
6
|
+
cursorManager?: SceneCursorManager;
|
|
7
|
+
/**
|
|
8
|
+
* The initial value of the coordinates.
|
|
9
|
+
* @defaultValue `(0, 0, 0)`
|
|
10
|
+
*/
|
|
11
|
+
initialValue?: Vector3;
|
|
12
|
+
/**
|
|
13
|
+
* The Giro3D instance to perform picking. If undefined, the picking button is hidden.
|
|
14
|
+
*/
|
|
15
|
+
instance?: Instance;
|
|
16
|
+
/**
|
|
17
|
+
* The label to display.
|
|
18
|
+
*/
|
|
19
|
+
label: string;
|
|
20
|
+
/**
|
|
21
|
+
* Display the Z component ?
|
|
22
|
+
* @defaultValue false
|
|
23
|
+
*/
|
|
24
|
+
showZ?: boolean;
|
|
25
|
+
};
|
|
26
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
27
|
+
"update:coordinates": (value: Coordinates) => any;
|
|
28
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
29
|
+
"onUpdate:coordinates"?: ((value: Coordinates) => any) | undefined;
|
|
30
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
31
|
+
export default _default;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
+
import { SearchResult } from '../api';
|
|
1
2
|
declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
2
|
-
|
|
3
|
+
resultSelected: (value: SearchResult) => any;
|
|
3
4
|
}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{
|
|
4
|
-
|
|
5
|
-
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
|
|
6
|
-
inputField: HTMLInputElement;
|
|
7
|
-
}, HTMLDivElement>;
|
|
5
|
+
onResultSelected?: ((value: SearchResult) => any) | undefined;
|
|
6
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
8
7
|
export default _default;
|
package/dist/src/context.d.ts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { EventDispatcher } from '../../../node_modules/three';
|
|
2
|
+
import { SearchApi } from './api';
|
|
2
3
|
import { default as AnalysisApi } from './api/AnalysisApi';
|
|
3
4
|
import { default as BookmarkApi } from './api/BookmarkApi';
|
|
4
5
|
import { default as DatasetApi } from './api/DatasetApi';
|
|
5
6
|
import { default as NotificationApi } from './api/NotificationApi';
|
|
6
7
|
import { default as ViewApi } from './api/ViewApi';
|
|
8
|
+
import { default as WidgetApi } from './api/WidgetApi';
|
|
7
9
|
import { PieroEvents } from './events';
|
|
8
10
|
import { Configuration } from './types/Configuration';
|
|
9
11
|
/**
|
|
@@ -35,8 +37,16 @@ export interface PieroContext {
|
|
|
35
37
|
* Notification related functions.
|
|
36
38
|
*/
|
|
37
39
|
notifications: NotificationApi;
|
|
40
|
+
/**
|
|
41
|
+
* Search related functions.
|
|
42
|
+
*/
|
|
43
|
+
search: SearchApi;
|
|
38
44
|
/**
|
|
39
45
|
* 3D View related functions.
|
|
40
46
|
*/
|
|
41
47
|
view: ViewApi;
|
|
48
|
+
/**
|
|
49
|
+
* Widget API.
|
|
50
|
+
*/
|
|
51
|
+
widgets: WidgetApi;
|
|
42
52
|
}
|
package/dist/src/events.d.ts
CHANGED
|
@@ -20,11 +20,17 @@ export type PayloadEvent<T> = {
|
|
|
20
20
|
* An event with no argument.
|
|
21
21
|
*/
|
|
22
22
|
export type PieroEmptyEvent = unknown;
|
|
23
|
-
export type PieroEvents = BookmarkEvents & DatasetEvents & PieroGlobalEvents;
|
|
23
|
+
export type PieroEvents = BookmarkEvents & DatasetEvents & PieroGlobalEvents & ViewEvents;
|
|
24
24
|
export interface PieroGlobalEvents {
|
|
25
25
|
/**
|
|
26
26
|
* Raised when the application has finished loading.
|
|
27
27
|
*/
|
|
28
28
|
ready: PieroEmptyEvent;
|
|
29
29
|
}
|
|
30
|
+
export interface ViewEvents {
|
|
31
|
+
/**
|
|
32
|
+
* Raised when the main view has been updated.
|
|
33
|
+
*/
|
|
34
|
+
updated: PieroEmptyEvent;
|
|
35
|
+
}
|
|
30
36
|
export declare const GLOBAL_EVENT_DISPATCHER: EventDispatcher<PieroEvents>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { default as Instance } from '@giro3d/giro3d/core/Instance';
|
|
2
|
+
import { default as Entity3D } from '@giro3d/giro3d/entities/Entity3D';
|
|
3
|
+
import { PieroContext } from '../context';
|
|
4
|
+
import { Module } from '../module';
|
|
5
|
+
export type PostProcessing = (entity: Entity3D, context: {
|
|
6
|
+
instance: Instance;
|
|
7
|
+
}) => void;
|
|
8
|
+
export default class PostProcessEntities implements Module {
|
|
9
|
+
readonly id = "builtin-post-process-entities";
|
|
10
|
+
readonly name = "Post-process 3D Tiles";
|
|
11
|
+
private readonly _alreadyProcessedEntities;
|
|
12
|
+
private readonly _processings;
|
|
13
|
+
initialize(context: PieroContext): Promise<void> | void;
|
|
14
|
+
private processEntities;
|
|
15
|
+
private processEntity;
|
|
16
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {},
|
|
1
|
+
declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
2
2
|
export default _default;
|
|
@@ -1,8 +1,15 @@
|
|
|
1
1
|
import { PieroContext } from '../../context';
|
|
2
2
|
export default class CrossSectionManager {
|
|
3
3
|
private readonly context;
|
|
4
|
+
private _clippingPlanes;
|
|
5
|
+
private _helper?;
|
|
6
|
+
private _instance?;
|
|
4
7
|
private readonly _store;
|
|
5
8
|
constructor(context: PieroContext);
|
|
6
9
|
dispose(): void;
|
|
10
|
+
private createHelperIfNecessary;
|
|
11
|
+
private showHelper;
|
|
7
12
|
private updateCrossSection;
|
|
13
|
+
private updateEntities;
|
|
14
|
+
private updateHelper;
|
|
8
15
|
}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
import { default as Instance } from '@giro3d/giro3d/core/Instance';
|
|
1
2
|
import { Vector3 } from '../../../../../node_modules/three';
|
|
3
|
+
import { default as SceneCursorManager } from '../../services/SceneCursorManager';
|
|
2
4
|
export declare const useCrossSectionStore: import('pinia').StoreDefinition<"crossSection", Pick<{
|
|
3
5
|
center: import('vue').Ref<{
|
|
4
6
|
x: number;
|
|
@@ -167,12 +169,18 @@ export declare const useCrossSectionStore: import('pinia').StoreDefinition<"cros
|
|
|
167
169
|
randomDirection: () => Vector3;
|
|
168
170
|
[Symbol.iterator]: () => Iterator<number>;
|
|
169
171
|
}>;
|
|
172
|
+
cursorManager: import('vue').ShallowRef<SceneCursorManager | undefined, SceneCursorManager | undefined>;
|
|
170
173
|
enable: import('vue').Ref<boolean, boolean>;
|
|
174
|
+
instance: import('vue').ShallowRef<Instance | undefined, Instance | undefined>;
|
|
171
175
|
orientation: import('vue').Ref<number, number>;
|
|
172
176
|
setCenter: (v: Vector3) => void;
|
|
177
|
+
setCursorManager: (v: SceneCursorManager) => void;
|
|
173
178
|
setEnabled: (v: boolean) => void;
|
|
179
|
+
setInstance: (v: Instance) => void;
|
|
174
180
|
setOrientation: (v: number) => void;
|
|
175
|
-
|
|
181
|
+
setShowHelper: (v: boolean) => void;
|
|
182
|
+
showHelper: import('vue').Ref<boolean, boolean>;
|
|
183
|
+
}, "instance" | "center" | "enable" | "orientation" | "cursorManager" | "showHelper">, Pick<{
|
|
176
184
|
center: import('vue').Ref<{
|
|
177
185
|
x: number;
|
|
178
186
|
y: number;
|
|
@@ -340,11 +348,17 @@ export declare const useCrossSectionStore: import('pinia').StoreDefinition<"cros
|
|
|
340
348
|
randomDirection: () => Vector3;
|
|
341
349
|
[Symbol.iterator]: () => Iterator<number>;
|
|
342
350
|
}>;
|
|
351
|
+
cursorManager: import('vue').ShallowRef<SceneCursorManager | undefined, SceneCursorManager | undefined>;
|
|
343
352
|
enable: import('vue').Ref<boolean, boolean>;
|
|
353
|
+
instance: import('vue').ShallowRef<Instance | undefined, Instance | undefined>;
|
|
344
354
|
orientation: import('vue').Ref<number, number>;
|
|
345
355
|
setCenter: (v: Vector3) => void;
|
|
356
|
+
setCursorManager: (v: SceneCursorManager) => void;
|
|
346
357
|
setEnabled: (v: boolean) => void;
|
|
358
|
+
setInstance: (v: Instance) => void;
|
|
347
359
|
setOrientation: (v: number) => void;
|
|
360
|
+
setShowHelper: (v: boolean) => void;
|
|
361
|
+
showHelper: import('vue').Ref<boolean, boolean>;
|
|
348
362
|
}, never>, Pick<{
|
|
349
363
|
center: import('vue').Ref<{
|
|
350
364
|
x: number;
|
|
@@ -513,10 +527,16 @@ export declare const useCrossSectionStore: import('pinia').StoreDefinition<"cros
|
|
|
513
527
|
randomDirection: () => Vector3;
|
|
514
528
|
[Symbol.iterator]: () => Iterator<number>;
|
|
515
529
|
}>;
|
|
530
|
+
cursorManager: import('vue').ShallowRef<SceneCursorManager | undefined, SceneCursorManager | undefined>;
|
|
516
531
|
enable: import('vue').Ref<boolean, boolean>;
|
|
532
|
+
instance: import('vue').ShallowRef<Instance | undefined, Instance | undefined>;
|
|
517
533
|
orientation: import('vue').Ref<number, number>;
|
|
518
534
|
setCenter: (v: Vector3) => void;
|
|
535
|
+
setCursorManager: (v: SceneCursorManager) => void;
|
|
519
536
|
setEnabled: (v: boolean) => void;
|
|
537
|
+
setInstance: (v: Instance) => void;
|
|
520
538
|
setOrientation: (v: number) => void;
|
|
521
|
-
|
|
539
|
+
setShowHelper: (v: boolean) => void;
|
|
540
|
+
showHelper: import('vue').Ref<boolean, boolean>;
|
|
541
|
+
}, "setCenter" | "setEnabled" | "setOrientation" | "setCursorManager" | "setInstance" | "setShowHelper">>;
|
|
522
542
|
export type CrossSectionStore = ReturnType<typeof useCrossSectionStore>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { PieroContext } from '../../context';
|
|
2
|
+
import { Module } from '../../module';
|
|
3
|
+
export default class CoordinatesSearch implements Module {
|
|
4
|
+
readonly id = "builtin-coordinates-search";
|
|
5
|
+
readonly name = "Coordinates search";
|
|
6
|
+
initialize(context: PieroContext): Promise<void> | void;
|
|
7
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { PieroContext } from '../../context';
|
|
2
|
+
import { Module } from '../../module';
|
|
3
|
+
/**
|
|
4
|
+
* Provides geocoding capabilities from the french address database.
|
|
5
|
+
*/
|
|
6
|
+
export default class FrenchBanGeocoder implements Module {
|
|
7
|
+
readonly id = "builtin-geocoding-ban";
|
|
8
|
+
readonly name = "Base adresse nationale";
|
|
9
|
+
initialize(context: PieroContext): Promise<void> | void;
|
|
10
|
+
}
|
|
@@ -2,8 +2,12 @@ import { default as ClippingBoxAnalysis } from './ClippingBoxAnalysis';
|
|
|
2
2
|
import { default as CrossSectionAnalysis } from './CrossSectionAnalysis';
|
|
3
3
|
import { default as DownloadDataset } from './DownloadDataset';
|
|
4
4
|
import { default as FloodingPlaneAnalysis } from './FloodingPlaneAnalysis';
|
|
5
|
+
import { default as CoordinatesSearch } from './geocoding/CoordinatesSearch';
|
|
6
|
+
import { default as FrenchBanGeocoder } from './geocoding/FrenchBanGeocoder';
|
|
5
7
|
import { default as IFCLoader } from './IFCLoader';
|
|
8
|
+
import { default as OpenLayersMinimap } from './OpenLayersMinimap';
|
|
6
9
|
import { default as PLYLoader } from './PLYLoader';
|
|
10
|
+
import { default as PostProcessEntities } from './PostProcessEntities';
|
|
7
11
|
import { default as PotreeLoader } from './PotreeLoader';
|
|
8
12
|
import { default as Tour } from './Tour';
|
|
9
|
-
export { ClippingBoxAnalysis, CrossSectionAnalysis, DownloadDataset, FloodingPlaneAnalysis, IFCLoader, PLYLoader, PotreeLoader, Tour, };
|
|
13
|
+
export { ClippingBoxAnalysis, CoordinatesSearch, CrossSectionAnalysis, DownloadDataset, FloodingPlaneAnalysis, FrenchBanGeocoder, IFCLoader, OpenLayersMinimap, PLYLoader, PostProcessEntities, PotreeLoader, Tour, };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { PieroContext } from '../../context';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
context: PieroContext;
|
|
4
|
+
};
|
|
5
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
6
|
+
target: HTMLDivElement;
|
|
7
|
+
}, HTMLDivElement>;
|
|
8
|
+
export default _default;
|
|
@@ -4,6 +4,7 @@ import { default as Entity3D } from '@giro3d/giro3d/entities/Entity3D';
|
|
|
4
4
|
import { Object3D, Box3, EventDispatcher, Vector3 } from '../../../../node_modules/three';
|
|
5
5
|
import { default as CameraPosition } from '../types/CameraPosition';
|
|
6
6
|
import { default as Picker } from './Picker';
|
|
7
|
+
import { default as SceneCursorManager } from './SceneCursorManager';
|
|
7
8
|
type CameraControllerEventMap = {
|
|
8
9
|
'interaction-end': {};
|
|
9
10
|
'interaction-start': {};
|
|
@@ -25,13 +26,12 @@ declare class CameraController extends EventDispatcher<CameraControllerEventMap>
|
|
|
25
26
|
private _boundPositionOnMapOnMouseMove;
|
|
26
27
|
private _cameraControlsInspector;
|
|
27
28
|
private readonly _clock;
|
|
29
|
+
private readonly _cursorManager;
|
|
28
30
|
private readonly _giro3dStore;
|
|
29
31
|
private readonly _instance;
|
|
30
32
|
private readonly _orbitControls;
|
|
31
|
-
private readonly _orbitHelper;
|
|
32
33
|
private readonly _picker;
|
|
33
34
|
private readonly _pickObjectsAt;
|
|
34
|
-
private readonly _positionOnMapHelper;
|
|
35
35
|
private readonly _store;
|
|
36
36
|
/**
|
|
37
37
|
* Creates new Camera-controls and bind them to Giro3D.
|
|
@@ -39,7 +39,7 @@ declare class CameraController extends EventDispatcher<CameraControllerEventMap>
|
|
|
39
39
|
* @param instance - Giro3D instance
|
|
40
40
|
* @param picker - Picker
|
|
41
41
|
*/
|
|
42
|
-
constructor(instance: Instance, picker: Picker);
|
|
42
|
+
constructor(instance: Instance, picker: Picker, cursorManager: SceneCursorManager);
|
|
43
43
|
dispose(): void;
|
|
44
44
|
/**
|
|
45
45
|
* Executes an interaction with animation.
|
|
@@ -7,6 +7,7 @@ import { default as Highlighter } from './Highlighter';
|
|
|
7
7
|
import { default as LayerManager } from './LayerManager';
|
|
8
8
|
import { default as MeasurementManager } from './MeasurementManager';
|
|
9
9
|
import { default as Picker } from './Picker';
|
|
10
|
+
import { default as SceneCursorManager } from './SceneCursorManager';
|
|
10
11
|
type Giro3DManagerEventMap = {
|
|
11
12
|
update: {};
|
|
12
13
|
};
|
|
@@ -21,6 +22,7 @@ export default class Giro3DManager extends EventDispatcher<Giro3DManagerEventMap
|
|
|
21
22
|
readonly mainInstance: Instance;
|
|
22
23
|
readonly measurementManager: MeasurementManager;
|
|
23
24
|
readonly picker: Picker;
|
|
25
|
+
readonly sceneCursorManager: SceneCursorManager;
|
|
24
26
|
private readonly _boundOnFrameEnd;
|
|
25
27
|
private readonly _store;
|
|
26
28
|
constructor(instance: Instance);
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { default as Instance } from '@giro3d/giro3d/core/Instance';
|
|
2
|
+
import { Vector3 } from '../../../../node_modules/three';
|
|
3
|
+
export type SceneCursorType = 'location' | 'orbit' | 'street';
|
|
4
|
+
/**
|
|
5
|
+
* Handles the display of the cursor in 3D space.
|
|
6
|
+
*/
|
|
7
|
+
export default class SceneCursorManager {
|
|
8
|
+
private _currentCursor;
|
|
9
|
+
private readonly _instance;
|
|
10
|
+
private readonly _pickingCursors;
|
|
11
|
+
constructor(instance: Instance);
|
|
12
|
+
/**
|
|
13
|
+
* Sets the cursor.
|
|
14
|
+
* @param cursor - The cursor to use. If `null`, the scene cursor is removed and replaced by a regular cursor.
|
|
15
|
+
*/
|
|
16
|
+
setCursor(cursor: SceneCursorType | null): void;
|
|
17
|
+
setCursorLocation(worldPosition: Vector3): void;
|
|
18
|
+
private detachCurrentCursor;
|
|
19
|
+
}
|
|
@@ -11,11 +11,9 @@ export declare const useGiro3dStore: import('pinia').StoreDefinition<"giro3d", P
|
|
|
11
11
|
getDefaultCameraPosition: () => Coordinates;
|
|
12
12
|
getInspector: () => Inspector | null;
|
|
13
13
|
getMainView: () => Instance | null;
|
|
14
|
-
getMinimapView: () => Instance | null;
|
|
15
14
|
notifyChange: () => void;
|
|
16
15
|
setInspector: (i: Inspector | null) => void;
|
|
17
16
|
setMainView: (instance: Instance | null) => void;
|
|
18
|
-
setMinimapView: (instance: Instance | null) => void;
|
|
19
17
|
}, never>, Pick<{
|
|
20
18
|
getCRS: () => string;
|
|
21
19
|
getDefaultBasemapExtent: () => Extent;
|
|
@@ -24,11 +22,9 @@ export declare const useGiro3dStore: import('pinia').StoreDefinition<"giro3d", P
|
|
|
24
22
|
getDefaultCameraPosition: () => Coordinates;
|
|
25
23
|
getInspector: () => Inspector | null;
|
|
26
24
|
getMainView: () => Instance | null;
|
|
27
|
-
getMinimapView: () => Instance | null;
|
|
28
25
|
notifyChange: () => void;
|
|
29
26
|
setInspector: (i: Inspector | null) => void;
|
|
30
27
|
setMainView: (instance: Instance | null) => void;
|
|
31
|
-
setMinimapView: (instance: Instance | null) => void;
|
|
32
28
|
}, never>, Pick<{
|
|
33
29
|
getCRS: () => string;
|
|
34
30
|
getDefaultBasemapExtent: () => Extent;
|
|
@@ -37,9 +33,7 @@ export declare const useGiro3dStore: import('pinia').StoreDefinition<"giro3d", P
|
|
|
37
33
|
getDefaultCameraPosition: () => Coordinates;
|
|
38
34
|
getInspector: () => Inspector | null;
|
|
39
35
|
getMainView: () => Instance | null;
|
|
40
|
-
getMinimapView: () => Instance | null;
|
|
41
36
|
notifyChange: () => void;
|
|
42
37
|
setInspector: (i: Inspector | null) => void;
|
|
43
38
|
setMainView: (instance: Instance | null) => void;
|
|
44
|
-
|
|
45
|
-
}, "getCRS" | "getDefaultBasemapExtent" | "getDefaultBasemapOptions" | "getDefaultCameraLookAt" | "getDefaultCameraPosition" | "getInspector" | "getMainView" | "getMinimapView" | "notifyChange" | "setInspector" | "setMainView" | "setMinimapView">>;
|
|
39
|
+
}, "getCRS" | "getDefaultBasemapExtent" | "getDefaultBasemapOptions" | "getDefaultCameraLookAt" | "getDefaultCameraPosition" | "getInspector" | "getMainView" | "notifyChange" | "setInspector" | "setMainView">>;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { SearchProvider } from '../api/SearchApi';
|
|
2
|
+
export declare const useSearchStore: import('pinia').StoreDefinition<"search", Pick<{
|
|
3
|
+
getProviders: () => SearchProvider[];
|
|
4
|
+
registerProvider: (provider: SearchProvider) => void;
|
|
5
|
+
}, never>, Pick<{
|
|
6
|
+
getProviders: () => SearchProvider[];
|
|
7
|
+
registerProvider: (provider: SearchProvider) => void;
|
|
8
|
+
}, never>, Pick<{
|
|
9
|
+
getProviders: () => SearchProvider[];
|
|
10
|
+
registerProvider: (provider: SearchProvider) => void;
|
|
11
|
+
}, "getProviders" | "registerProvider">>;
|
|
12
|
+
export type SearchStore = ReturnType<typeof useSearchStore>;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Widget } from '../api/WidgetApi';
|
|
2
|
+
export declare const useWidgetStore: import('pinia').StoreDefinition<"widgets", Pick<{
|
|
3
|
+
addWidget: (widget: Widget) => void;
|
|
4
|
+
getWidgets: () => Widget[];
|
|
5
|
+
}, never>, Pick<{
|
|
6
|
+
addWidget: (widget: Widget) => void;
|
|
7
|
+
getWidgets: () => Widget[];
|
|
8
|
+
}, never>, Pick<{
|
|
9
|
+
addWidget: (widget: Widget) => void;
|
|
10
|
+
getWidgets: () => Widget[];
|
|
11
|
+
}, "addWidget" | "getWidgets">>;
|
|
12
|
+
export type WidgetStore = ReturnType<typeof useWidgetStore>;
|
|
@@ -4,6 +4,7 @@ type Link = {
|
|
|
4
4
|
title: string;
|
|
5
5
|
type?: string;
|
|
6
6
|
};
|
|
7
|
+
export declare function nonNull<T>(obj: T | null | undefined): T;
|
|
7
8
|
export declare const isObject: (obj: unknown) => obj is object;
|
|
8
9
|
export declare const isLink: (obj: unknown) => obj is Link;
|
|
9
10
|
export declare const isColor: (obj: unknown) => obj is Color;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@giro3d/piero",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.0.0-beta.
|
|
4
|
+
"version": "1.0.0-beta.4",
|
|
5
5
|
"description": "A web application for 3D geospatial data visualization, powered by Giro3D",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"front-end",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"@loaders.gl/las": "^4.1.1",
|
|
82
82
|
"@loaders.gl/shapefile": "^4.1.1",
|
|
83
83
|
"@popperjs/core": "^2.11.8",
|
|
84
|
-
"@
|
|
84
|
+
"@trevoreyre/autocomplete-vue": "^3.0.3",
|
|
85
85
|
"bootstrap": "^5.3.3",
|
|
86
86
|
"bootstrap-icons": "^1.11.3",
|
|
87
87
|
"camera-controls": "^2.10.1",
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
|
|
2
|
-
target: HTMLDivElement;
|
|
3
|
-
}, HTMLDivElement>;
|
|
4
|
-
export default _default;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { GeocodingResult } from './Geocoding';
|
|
2
|
-
declare const _default: {
|
|
3
|
-
/**
|
|
4
|
-
* Searches for an address in the French BAN
|
|
5
|
-
*
|
|
6
|
-
* @param query - Search query
|
|
7
|
-
* @returns Results
|
|
8
|
-
*/
|
|
9
|
-
geocode(query: string): Promise<GeocodingResult[]>;
|
|
10
|
-
};
|
|
11
|
-
export default _default;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { default as Instance } from '@giro3d/giro3d/core/Instance';
|
|
2
|
-
import { Vector3 } from '../../../../node_modules/three';
|
|
3
|
-
export default class MinimapController {
|
|
4
|
-
private readonly _basemap;
|
|
5
|
-
private _boundUpdateViewbox;
|
|
6
|
-
private _mainInstance;
|
|
7
|
-
private readonly _minimapInstance;
|
|
8
|
-
private readonly _viewbox;
|
|
9
|
-
constructor(instance: Instance);
|
|
10
|
-
dispose(): void;
|
|
11
|
-
getCorners(): {
|
|
12
|
-
ll: Vector3;
|
|
13
|
-
lr: Vector3;
|
|
14
|
-
ul: Vector3;
|
|
15
|
-
ur: Vector3;
|
|
16
|
-
} | undefined;
|
|
17
|
-
setMainInstance(instance: Instance | null): void;
|
|
18
|
-
updateViewbox(): void;
|
|
19
|
-
}
|