isard 0.5.1 → 0.6.0
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/CHANGELOG.md +31 -0
- package/README.md +10 -2
- package/dist/basemap.worker.js +2 -2
- package/dist/basemap.worker.js.map +5 -4
- package/dist/decoder.worker.js +3 -3
- package/dist/decoder.worker.js.map +3 -3
- package/dist/index.d.ts +4 -3
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/isard_bg.wasm +0 -0
- package/dist/isard_core_bg.wasm +0 -0
- package/dist/map.d.ts +13 -2
- package/dist/map.js +26 -2
- package/dist/map.js.map +1 -1
- package/dist/pmtiles.d.ts +68 -0
- package/dist/pmtiles.js +297 -0
- package/dist/pmtiles.js.map +1 -0
- package/dist/types.d.ts +23 -0
- package/dist/types.js.map +1 -1
- package/dist/vectortiles.d.ts +30 -1
- package/dist/vectortiles.js +109 -3
- package/dist/vectortiles.js.map +1 -1
- package/dist/wasm/isard.d.ts +12 -0
- package/dist/wasm/isard.js +32 -1
- package/dist/wasm/isard_core.d.ts +12 -0
- package/dist/wasm/isard_core.js +32 -1
- package/package.json +1 -1
package/dist/wasm/isard_core.js
CHANGED
|
@@ -209,6 +209,12 @@ export class Engine {
|
|
|
209
209
|
clearPreload() {
|
|
210
210
|
wasm.engine_clearPreload(this.__wbg_ptr);
|
|
211
211
|
}
|
|
212
|
+
/**
|
|
213
|
+
* Removes the viewshed
|
|
214
|
+
*/
|
|
215
|
+
clearViewshed() {
|
|
216
|
+
wasm.engine_clearViewshed(this.__wbg_ptr);
|
|
217
|
+
}
|
|
212
218
|
/**
|
|
213
219
|
* Model-view-projection matrix (16 numbers, column-major, for `uniformMatrix4fv`) of the local frame at a
|
|
214
220
|
* longitude, latitude (degrees) and altitude (metres): x east, y north, z up, in metres. Undefined outside the
|
|
@@ -866,6 +872,31 @@ export class Engine {
|
|
|
866
872
|
throw takeFromExternrefTable0(ret[0]);
|
|
867
873
|
}
|
|
868
874
|
}
|
|
875
|
+
/**
|
|
876
|
+
* Shows what can be seen from a point within `range` metres around it: `lon`, `lat` (degrees), `height` metres
|
|
877
|
+
* above the ground; seen and hidden surfaces tinted with `visible` and `hidden` (RGB 0-1) at `opacity`. `cone`:
|
|
878
|
+
* heading, tilt, angles of view across and up (degrees) to look one way only, empty to look all around
|
|
879
|
+
* @param {number} lon
|
|
880
|
+
* @param {number} lat
|
|
881
|
+
* @param {number} height
|
|
882
|
+
* @param {number} range
|
|
883
|
+
* @param {Float32Array} visible
|
|
884
|
+
* @param {Float32Array} hidden
|
|
885
|
+
* @param {number} opacity
|
|
886
|
+
* @param {Float64Array} cone
|
|
887
|
+
*/
|
|
888
|
+
setViewshed(lon, lat, height, range, visible, hidden, opacity, cone) {
|
|
889
|
+
const ptr0 = passArrayF32ToWasm0(visible, wasm.__wbindgen_malloc);
|
|
890
|
+
const len0 = WASM_VECTOR_LEN;
|
|
891
|
+
const ptr1 = passArrayF32ToWasm0(hidden, wasm.__wbindgen_malloc);
|
|
892
|
+
const len1 = WASM_VECTOR_LEN;
|
|
893
|
+
const ptr2 = passArrayF64ToWasm0(cone, wasm.__wbindgen_malloc);
|
|
894
|
+
const len2 = WASM_VECTOR_LEN;
|
|
895
|
+
const ret = wasm.engine_setViewshed(this.__wbg_ptr, lon, lat, height, range, ptr0, len0, ptr1, len1, opacity, ptr2, len2);
|
|
896
|
+
if (ret[1]) {
|
|
897
|
+
throw takeFromExternrefTable0(ret[0]);
|
|
898
|
+
}
|
|
899
|
+
}
|
|
869
900
|
/**
|
|
870
901
|
* @param {number} min
|
|
871
902
|
* @param {number} max
|
|
@@ -1934,7 +1965,7 @@ function __wbg_get_imports() {
|
|
|
1934
1965
|
return ret;
|
|
1935
1966
|
},
|
|
1936
1967
|
__wbindgen_generic_0000000000000001: function(arg0, arg1) {
|
|
1937
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx:
|
|
1968
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 92, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
1938
1969
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen_2e566c63402fe7fa___convert__closures_____invoke___wasm_bindgen_2e566c63402fe7fa___JsValue__core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_2e566c63402fe7fa___JsError___true_);
|
|
1939
1970
|
return ret;
|
|
1940
1971
|
},
|
package/package.json
CHANGED