|
@@ -196,6 +196,10 @@ export interface SDK {
|
|
|
|
|
|
export let sdk: SDK;
|
|
export let sdk: SDK;
|
|
export type InialSDKProps = {
|
|
export type InialSDKProps = {
|
|
|
|
+ laserRoot?: string
|
|
|
|
+ ossRoot?: string
|
|
|
|
+ laserOSSRoot?: string
|
|
|
|
+ panoOSSRoot?: string
|
|
layout: HTMLDivElement;
|
|
layout: HTMLDivElement;
|
|
scenes: Scene[];
|
|
scenes: Scene[];
|
|
lonlat?: number[];
|
|
lonlat?: number[];
|
|
@@ -220,14 +224,15 @@ export const initialSDK = async (props: InialSDKProps) => {
|
|
await Promise.all(libs.map(loadLib));
|
|
await Promise.all(libs.map(loadLib));
|
|
await loadLib(`./lib/potree/potree.js`);
|
|
await loadLib(`./lib/potree/potree.js`);
|
|
|
|
|
|
- console.log(props);
|
|
|
|
|
|
+ console.log('initSDK_last',props);
|
|
const localSdk = cover({
|
|
const localSdk = cover({
|
|
|
|
+ ...props,
|
|
dom: props.layout,
|
|
dom: props.layout,
|
|
isLocal: false,
|
|
isLocal: false,
|
|
scenes: props.scenes,
|
|
scenes: props.scenes,
|
|
lonlat: props.lonlat,
|
|
lonlat: props.lonlat,
|
|
mapDom: null,
|
|
mapDom: null,
|
|
- }) as unknown as SDK;
|
|
|
|
|
|
+ } as any) as unknown as SDK;
|
|
|
|
|
|
console.log(scenes.value);
|
|
console.log(scenes.value);
|
|
(window as any).sdk = sdk = localSdk;
|
|
(window as any).sdk = sdk = localSdk;
|