@deck.gl/extensions 8.8.0-alpha.6 → 8.8.0-beta.3
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/dist.dev.js +311 -1166
- package/dist/es5/brushing/brushing.js +19 -15
- package/dist/es5/brushing/brushing.js.map +1 -1
- package/dist/es5/brushing/shader-module.js +1 -1
- package/dist/es5/brushing/shader-module.js.map +1 -1
- package/dist/es5/clip/clip.js +4 -2
- package/dist/es5/clip/clip.js.map +1 -1
- package/dist/es5/data-filter/aggregator.js +1 -1
- package/dist/es5/data-filter/aggregator.js.map +1 -1
- package/dist/es5/data-filter/data-filter.js +9 -9
- package/dist/es5/data-filter/data-filter.js.map +1 -1
- package/dist/es5/data-filter/shader-module.js +22 -13
- package/dist/es5/data-filter/shader-module.js.map +1 -1
- package/dist/es5/fill-style/fill-style.js +13 -11
- package/dist/es5/fill-style/fill-style.js.map +1 -1
- package/dist/es5/fill-style/shaders.glsl.js +8 -6
- package/dist/es5/fill-style/shaders.glsl.js.map +1 -1
- package/dist/es5/fp64/fp64.js +4 -2
- package/dist/es5/fp64/fp64.js.map +1 -1
- package/dist/es5/fp64/project64.glsl.js +1 -1
- package/dist/es5/fp64/project64.js +2 -5
- package/dist/es5/fp64/project64.js.map +1 -1
- package/dist/es5/index.js.map +1 -1
- package/dist/es5/mask/mask.js +7 -4
- package/dist/es5/mask/mask.js.map +1 -1
- package/dist/es5/mask/shader-module.js +6 -7
- package/dist/es5/mask/shader-module.js.map +1 -1
- package/dist/es5/path-style/path-style.js +5 -5
- package/dist/es5/path-style/path-style.js.map +1 -1
- package/dist/es5/path-style/shaders.glsl.js +1 -1
- package/dist/es5/path-style/shaders.glsl.js.map +1 -1
- package/dist/esm/brushing/brushing.js +20 -15
- package/dist/esm/brushing/brushing.js.map +1 -1
- package/dist/esm/brushing/shader-module.js +1 -1
- package/dist/esm/brushing/shader-module.js.map +1 -1
- package/dist/esm/clip/clip.js +5 -2
- package/dist/esm/clip/clip.js.map +1 -1
- package/dist/esm/data-filter/aggregator.js +1 -1
- package/dist/esm/data-filter/aggregator.js.map +1 -1
- package/dist/esm/data-filter/data-filter.js +6 -3
- package/dist/esm/data-filter/data-filter.js.map +1 -1
- package/dist/esm/data-filter/shader-module.js +21 -21
- package/dist/esm/data-filter/shader-module.js.map +1 -1
- package/dist/esm/fill-style/fill-style.js +18 -13
- package/dist/esm/fill-style/fill-style.js.map +1 -1
- package/dist/esm/fill-style/shaders.glsl.js +6 -2
- package/dist/esm/fill-style/shaders.glsl.js.map +1 -1
- package/dist/esm/fp64/fp64.js +4 -2
- package/dist/esm/fp64/fp64.js.map +1 -1
- package/dist/esm/fp64/project64.glsl.js +1 -1
- package/dist/esm/fp64/project64.glsl.js.map +1 -1
- package/dist/esm/fp64/project64.js +2 -3
- package/dist/esm/fp64/project64.js.map +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/mask/mask.js +7 -4
- package/dist/esm/mask/mask.js.map +1 -1
- package/dist/esm/mask/shader-module.js +6 -6
- package/dist/esm/mask/shader-module.js.map +1 -1
- package/dist/esm/path-style/path-style.js +6 -5
- package/dist/esm/path-style/path-style.js.map +1 -1
- package/dist/esm/path-style/shaders.glsl.js +1 -1
- package/dist/esm/path-style/shaders.glsl.js.map +1 -1
- package/dist.min.js +1 -1
- package/package.json +5 -3
- package/src/brushing/{brushing.js → brushing.ts} +45 -17
- package/src/brushing/{shader-module.js → shader-module.ts} +13 -3
- package/src/clip/{clip.js → clip.ts} +26 -9
- package/src/data-filter/{aggregator.js → aggregator.ts} +12 -8
- package/src/data-filter/{data-filter.js → data-filter.ts} +90 -13
- package/src/data-filter/{shader-module.js → shader-module.ts} +36 -27
- package/src/fill-style/{fill-style.js → fill-style.ts} +83 -19
- package/src/fill-style/{shaders.glsl.js → shaders.glsl.ts} +24 -4
- package/src/fp64/{fp64.js → fp64.ts} +6 -3
- package/src/fp64/{project64.glsl.js → project64.glsl.ts} +0 -0
- package/src/fp64/{project64.js → project64.ts} +16 -5
- package/src/index.ts +8 -0
- package/src/mask/{mask.js → mask.ts} +25 -8
- package/src/mask/{shader-module.js → shader-module.ts} +14 -6
- package/src/path-style/{path-style.js → path-style.ts} +65 -14
- package/src/path-style/{shaders.glsl.js → shaders.glsl.ts} +0 -0
- package/typed/brushing/brushing.d.ts +37 -16
- package/typed/brushing/brushing.d.ts.map +1 -1
- package/typed/brushing/shader-module.d.ts +9 -24
- package/typed/brushing/shader-module.d.ts.map +1 -1
- package/typed/clip/clip.d.ts +27 -10
- package/typed/clip/clip.d.ts.map +1 -1
- package/typed/data-filter/aggregator.d.ts +10 -9
- package/typed/data-filter/aggregator.d.ts.map +1 -1
- package/typed/data-filter/data-filter.d.ts +87 -29
- package/typed/data-filter/data-filter.d.ts.map +1 -1
- package/typed/data-filter/shader-module.d.ts +7 -24
- package/typed/data-filter/shader-module.d.ts.map +1 -1
- package/typed/fill-style/fill-style.d.ts +74 -41
- package/typed/fill-style/fill-style.d.ts.map +1 -1
- package/typed/fill-style/shaders.glsl.d.ts +8 -33
- package/typed/fill-style/shaders.glsl.d.ts.map +1 -1
- package/typed/fp64/fp64.d.ts +6 -6
- package/typed/fp64/fp64.d.ts.map +1 -1
- package/typed/fp64/project64.d.ts +5 -9
- package/typed/fp64/project64.d.ts.map +1 -1
- package/typed/fp64/project64.glsl.d.ts +1 -1
- package/typed/fp64/project64.glsl.d.ts.map +1 -1
- package/typed/index.d.ts +6 -0
- package/typed/index.d.ts.map +1 -1
- package/typed/mask/mask.d.ts +21 -9
- package/typed/mask/mask.d.ts.map +1 -1
- package/typed/mask/shader-module.d.ts +6 -20
- package/typed/mask/shader-module.d.ts.map +1 -1
- package/typed/path-style/path-style.d.ts +63 -27
- package/typed/path-style/path-style.d.ts.map +1 -1
- package/typed/path-style/shaders.glsl.d.ts +6 -7
- package/typed/path-style/shaders.glsl.d.ts.map +1 -1
package/dist/dist.dev.js
CHANGED
|
@@ -7298,9 +7298,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
7298
7298
|
/* harmony import */ var _base_matrix__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./base/matrix */ "../../node_modules/@math.gl/core/dist/esm/classes/base/matrix.js");
|
|
7299
7299
|
/* harmony import */ var _lib_validators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../lib/validators */ "../../node_modules/@math.gl/core/dist/esm/lib/validators.js");
|
|
7300
7300
|
/* harmony import */ var _lib_gl_matrix_extras__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../lib/gl-matrix-extras */ "../../node_modules/@math.gl/core/dist/esm/lib/gl-matrix-extras.js");
|
|
7301
|
-
/* harmony import */ var gl_matrix_mat3__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/mat3 */ "../../node_modules
|
|
7302
|
-
/* harmony import */ var gl_matrix_vec2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! gl-matrix/vec2 */ "../../node_modules
|
|
7303
|
-
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules
|
|
7301
|
+
/* harmony import */ var gl_matrix_mat3__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/mat3 */ "../../node_modules/gl-matrix/esm/mat3.js");
|
|
7302
|
+
/* harmony import */ var gl_matrix_vec2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! gl-matrix/vec2 */ "../../node_modules/gl-matrix/esm/vec2.js");
|
|
7303
|
+
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules/gl-matrix/esm/vec3.js");
|
|
7304
7304
|
|
|
7305
7305
|
|
|
7306
7306
|
|
|
@@ -7525,10 +7525,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
7525
7525
|
/* harmony import */ var _base_matrix__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./base/matrix */ "../../node_modules/@math.gl/core/dist/esm/classes/base/matrix.js");
|
|
7526
7526
|
/* harmony import */ var _lib_validators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../lib/validators */ "../../node_modules/@math.gl/core/dist/esm/lib/validators.js");
|
|
7527
7527
|
/* harmony import */ var _lib_gl_matrix_extras__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../lib/gl-matrix-extras */ "../../node_modules/@math.gl/core/dist/esm/lib/gl-matrix-extras.js");
|
|
7528
|
-
/* harmony import */ var gl_matrix_mat4__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/mat4 */ "../../node_modules
|
|
7529
|
-
/* harmony import */ var gl_matrix_vec2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! gl-matrix/vec2 */ "../../node_modules
|
|
7530
|
-
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules
|
|
7531
|
-
/* harmony import */ var gl_matrix_vec4__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! gl-matrix/vec4 */ "../../node_modules
|
|
7528
|
+
/* harmony import */ var gl_matrix_mat4__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/mat4 */ "../../node_modules/gl-matrix/esm/mat4.js");
|
|
7529
|
+
/* harmony import */ var gl_matrix_vec2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! gl-matrix/vec2 */ "../../node_modules/gl-matrix/esm/vec2.js");
|
|
7530
|
+
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules/gl-matrix/esm/vec3.js");
|
|
7531
|
+
/* harmony import */ var gl_matrix_vec4__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! gl-matrix/vec4 */ "../../node_modules/gl-matrix/esm/vec4.js");
|
|
7532
7532
|
|
|
7533
7533
|
|
|
7534
7534
|
|
|
@@ -8164,8 +8164,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8164
8164
|
/* harmony import */ var _base_math_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./base/math-array */ "../../node_modules/@math.gl/core/dist/esm/classes/base/math-array.js");
|
|
8165
8165
|
/* harmony import */ var _lib_validators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../lib/validators */ "../../node_modules/@math.gl/core/dist/esm/lib/validators.js");
|
|
8166
8166
|
/* harmony import */ var _vector4__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./vector4 */ "../../node_modules/@math.gl/core/dist/esm/classes/vector4.js");
|
|
8167
|
-
/* harmony import */ var gl_matrix_quat__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/quat */ "../../node_modules
|
|
8168
|
-
/* harmony import */ var gl_matrix_vec4__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! gl-matrix/vec4 */ "../../node_modules
|
|
8167
|
+
/* harmony import */ var gl_matrix_quat__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/quat */ "../../node_modules/gl-matrix/esm/quat.js");
|
|
8168
|
+
/* harmony import */ var gl_matrix_vec4__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! gl-matrix/vec4 */ "../../node_modules/gl-matrix/esm/vec4.js");
|
|
8169
8169
|
|
|
8170
8170
|
|
|
8171
8171
|
|
|
@@ -8422,7 +8422,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8422
8422
|
/* harmony import */ var _babel_runtime_helpers_esm_defineProperty__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @babel/runtime/helpers/esm/defineProperty */ "../../node_modules/@math.gl/core/node_modules/@babel/runtime/helpers/esm/defineProperty.js");
|
|
8423
8423
|
/* harmony import */ var _vector3__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./vector3 */ "../../node_modules/@math.gl/core/dist/esm/classes/vector3.js");
|
|
8424
8424
|
/* harmony import */ var _lib_common__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../lib/common */ "../../node_modules/@math.gl/core/dist/esm/lib/common.js");
|
|
8425
|
-
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules
|
|
8425
|
+
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules/gl-matrix/esm/vec3.js");
|
|
8426
8426
|
|
|
8427
8427
|
|
|
8428
8428
|
|
|
@@ -8594,7 +8594,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8594
8594
|
/* harmony import */ var _base_vector__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./base/vector */ "../../node_modules/@math.gl/core/dist/esm/classes/base/vector.js");
|
|
8595
8595
|
/* harmony import */ var _lib_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../lib/common */ "../../node_modules/@math.gl/core/dist/esm/lib/common.js");
|
|
8596
8596
|
/* harmony import */ var _lib_validators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../lib/validators */ "../../node_modules/@math.gl/core/dist/esm/lib/validators.js");
|
|
8597
|
-
/* harmony import */ var gl_matrix_vec2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/vec2 */ "../../node_modules
|
|
8597
|
+
/* harmony import */ var gl_matrix_vec2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/vec2 */ "../../node_modules/gl-matrix/esm/vec2.js");
|
|
8598
8598
|
/* harmony import */ var _lib_gl_matrix_extras__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../lib/gl-matrix-extras */ "../../node_modules/@math.gl/core/dist/esm/lib/gl-matrix-extras.js");
|
|
8599
8599
|
|
|
8600
8600
|
|
|
@@ -8706,7 +8706,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8706
8706
|
/* harmony import */ var _base_vector__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./base/vector */ "../../node_modules/@math.gl/core/dist/esm/classes/base/vector.js");
|
|
8707
8707
|
/* harmony import */ var _lib_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../lib/common */ "../../node_modules/@math.gl/core/dist/esm/lib/common.js");
|
|
8708
8708
|
/* harmony import */ var _lib_validators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../lib/validators */ "../../node_modules/@math.gl/core/dist/esm/lib/validators.js");
|
|
8709
|
-
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules
|
|
8709
|
+
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules/gl-matrix/esm/vec3.js");
|
|
8710
8710
|
/* harmony import */ var _lib_gl_matrix_extras__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../lib/gl-matrix-extras */ "../../node_modules/@math.gl/core/dist/esm/lib/gl-matrix-extras.js");
|
|
8711
8711
|
|
|
8712
8712
|
|
|
@@ -8869,7 +8869,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8869
8869
|
/* harmony import */ var _base_vector__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./base/vector */ "../../node_modules/@math.gl/core/dist/esm/classes/base/vector.js");
|
|
8870
8870
|
/* harmony import */ var _lib_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../lib/common */ "../../node_modules/@math.gl/core/dist/esm/lib/common.js");
|
|
8871
8871
|
/* harmony import */ var _lib_validators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../lib/validators */ "../../node_modules/@math.gl/core/dist/esm/lib/validators.js");
|
|
8872
|
-
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules
|
|
8872
|
+
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules/gl-matrix/esm/vec3.js");
|
|
8873
8873
|
/* harmony import */ var _lib_gl_matrix_extras__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../lib/gl-matrix-extras */ "../../node_modules/@math.gl/core/dist/esm/lib/gl-matrix-extras.js");
|
|
8874
8874
|
|
|
8875
8875
|
|
|
@@ -9520,10 +9520,10 @@ function _defineProperty(obj, key, value) {
|
|
|
9520
9520
|
|
|
9521
9521
|
/***/ }),
|
|
9522
9522
|
|
|
9523
|
-
/***/ "../../node_modules
|
|
9524
|
-
|
|
9525
|
-
!*** /Users/alasarr/dev/deck.gl/node_modules
|
|
9526
|
-
|
|
9523
|
+
/***/ "../../node_modules/gl-matrix/esm/common.js":
|
|
9524
|
+
/*!***********************************************************************!*\
|
|
9525
|
+
!*** /Users/alasarr/dev/deck.gl/node_modules/gl-matrix/esm/common.js ***!
|
|
9526
|
+
\***********************************************************************/
|
|
9527
9527
|
/*! exports provided: EPSILON, ARRAY_TYPE, RANDOM, setMatrixArrayType, toRadian, equals */
|
|
9528
9528
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
9529
9529
|
|
|
@@ -9588,10 +9588,10 @@ if (!Math.hypot) Math.hypot = function () {
|
|
|
9588
9588
|
|
|
9589
9589
|
/***/ }),
|
|
9590
9590
|
|
|
9591
|
-
/***/ "../../node_modules
|
|
9592
|
-
|
|
9593
|
-
!*** /Users/alasarr/dev/deck.gl/node_modules
|
|
9594
|
-
|
|
9591
|
+
/***/ "../../node_modules/gl-matrix/esm/mat3.js":
|
|
9592
|
+
/*!*********************************************************************!*\
|
|
9593
|
+
!*** /Users/alasarr/dev/deck.gl/node_modules/gl-matrix/esm/mat3.js ***!
|
|
9594
|
+
\*********************************************************************/
|
|
9595
9595
|
/*! exports provided: create, fromMat4, clone, copy, fromValues, set, identity, transpose, invert, adjoint, determinant, multiply, translate, rotate, scale, fromTranslation, fromRotation, fromScaling, fromMat2d, fromQuat, normalFromMat4, projection, str, frob, add, subtract, multiplyScalar, multiplyScalarAndAdd, exactEquals, equals, mul, sub */
|
|
9596
9596
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
9597
9597
|
|
|
@@ -9629,7 +9629,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
9629
9629
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "equals", function() { return equals; });
|
|
9630
9630
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "mul", function() { return mul; });
|
|
9631
9631
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sub", function() { return sub; });
|
|
9632
|
-
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules
|
|
9632
|
+
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules/gl-matrix/esm/common.js");
|
|
9633
9633
|
|
|
9634
9634
|
/**
|
|
9635
9635
|
* 3x3 Matrix
|
|
@@ -10411,10 +10411,10 @@ var sub = subtract;
|
|
|
10411
10411
|
|
|
10412
10412
|
/***/ }),
|
|
10413
10413
|
|
|
10414
|
-
/***/ "../../node_modules
|
|
10415
|
-
|
|
10416
|
-
!*** /Users/alasarr/dev/deck.gl/node_modules
|
|
10417
|
-
|
|
10414
|
+
/***/ "../../node_modules/gl-matrix/esm/mat4.js":
|
|
10415
|
+
/*!*********************************************************************!*\
|
|
10416
|
+
!*** /Users/alasarr/dev/deck.gl/node_modules/gl-matrix/esm/mat4.js ***!
|
|
10417
|
+
\*********************************************************************/
|
|
10418
10418
|
/*! exports provided: create, clone, copy, fromValues, set, identity, transpose, invert, adjoint, determinant, multiply, translate, scale, rotate, rotateX, rotateY, rotateZ, fromTranslation, fromScaling, fromRotation, fromXRotation, fromYRotation, fromZRotation, fromRotationTranslation, fromQuat2, getTranslation, getScaling, getRotation, fromRotationTranslationScale, fromRotationTranslationScaleOrigin, fromQuat, frustum, perspectiveNO, perspective, perspectiveZO, perspectiveFromFieldOfView, orthoNO, ortho, orthoZO, lookAt, targetTo, str, frob, add, subtract, multiplyScalar, multiplyScalarAndAdd, exactEquals, equals, mul, sub */
|
|
10419
10419
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
10420
10420
|
|
|
@@ -10471,7 +10471,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
10471
10471
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "equals", function() { return equals; });
|
|
10472
10472
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "mul", function() { return mul; });
|
|
10473
10473
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sub", function() { return sub; });
|
|
10474
|
-
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules
|
|
10474
|
+
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules/gl-matrix/esm/common.js");
|
|
10475
10475
|
|
|
10476
10476
|
/**
|
|
10477
10477
|
* 4x4 Matrix<br>Format: column-major, when typed out it looks like row-major<br>The matrices are being post multiplied.
|
|
@@ -12385,10 +12385,10 @@ var sub = subtract;
|
|
|
12385
12385
|
|
|
12386
12386
|
/***/ }),
|
|
12387
12387
|
|
|
12388
|
-
/***/ "../../node_modules
|
|
12389
|
-
|
|
12390
|
-
!*** /Users/alasarr/dev/deck.gl/node_modules
|
|
12391
|
-
|
|
12388
|
+
/***/ "../../node_modules/gl-matrix/esm/quat.js":
|
|
12389
|
+
/*!*********************************************************************!*\
|
|
12390
|
+
!*** /Users/alasarr/dev/deck.gl/node_modules/gl-matrix/esm/quat.js ***!
|
|
12391
|
+
\*********************************************************************/
|
|
12392
12392
|
/*! exports provided: create, identity, setAxisAngle, getAxisAngle, getAngle, multiply, rotateX, rotateY, rotateZ, calculateW, exp, ln, pow, slerp, random, invert, conjugate, fromMat3, fromEuler, str, clone, fromValues, copy, set, add, mul, scale, dot, lerp, length, len, squaredLength, sqrLen, normalize, exactEquals, equals, rotationTo, sqlerp, setAxes */
|
|
12393
12393
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
12394
12394
|
|
|
@@ -12433,10 +12433,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
12433
12433
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rotationTo", function() { return rotationTo; });
|
|
12434
12434
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sqlerp", function() { return sqlerp; });
|
|
12435
12435
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setAxes", function() { return setAxes; });
|
|
12436
|
-
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules
|
|
12437
|
-
/* harmony import */ var _mat3_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./mat3.js */ "../../node_modules
|
|
12438
|
-
/* harmony import */ var _vec3_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./vec3.js */ "../../node_modules
|
|
12439
|
-
/* harmony import */ var _vec4_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./vec4.js */ "../../node_modules
|
|
12436
|
+
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules/gl-matrix/esm/common.js");
|
|
12437
|
+
/* harmony import */ var _mat3_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./mat3.js */ "../../node_modules/gl-matrix/esm/mat3.js");
|
|
12438
|
+
/* harmony import */ var _vec3_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./vec3.js */ "../../node_modules/gl-matrix/esm/vec3.js");
|
|
12439
|
+
/* harmony import */ var _vec4_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./vec4.js */ "../../node_modules/gl-matrix/esm/vec4.js");
|
|
12440
12440
|
|
|
12441
12441
|
|
|
12442
12442
|
|
|
@@ -13150,10 +13150,10 @@ var setAxes = function () {
|
|
|
13150
13150
|
|
|
13151
13151
|
/***/ }),
|
|
13152
13152
|
|
|
13153
|
-
/***/ "../../node_modules
|
|
13154
|
-
|
|
13155
|
-
!*** /Users/alasarr/dev/deck.gl/node_modules
|
|
13156
|
-
|
|
13153
|
+
/***/ "../../node_modules/gl-matrix/esm/vec2.js":
|
|
13154
|
+
/*!*********************************************************************!*\
|
|
13155
|
+
!*** /Users/alasarr/dev/deck.gl/node_modules/gl-matrix/esm/vec2.js ***!
|
|
13156
|
+
\*********************************************************************/
|
|
13157
13157
|
/*! exports provided: create, clone, fromValues, copy, set, add, subtract, multiply, divide, ceil, floor, min, max, round, scale, scaleAndAdd, distance, squaredDistance, length, squaredLength, negate, inverse, normalize, dot, cross, lerp, random, transformMat2, transformMat2d, transformMat3, transformMat4, rotate, angle, zero, str, exactEquals, equals, len, sub, mul, div, dist, sqrDist, sqrLen, forEach */
|
|
13158
13158
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
13159
13159
|
|
|
@@ -13204,7 +13204,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
13204
13204
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sqrDist", function() { return sqrDist; });
|
|
13205
13205
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sqrLen", function() { return sqrLen; });
|
|
13206
13206
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "forEach", function() { return forEach; });
|
|
13207
|
-
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules
|
|
13207
|
+
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules/gl-matrix/esm/common.js");
|
|
13208
13208
|
|
|
13209
13209
|
/**
|
|
13210
13210
|
* 2 Dimensional Vector
|
|
@@ -13832,10 +13832,10 @@ var forEach = function () {
|
|
|
13832
13832
|
|
|
13833
13833
|
/***/ }),
|
|
13834
13834
|
|
|
13835
|
-
/***/ "../../node_modules
|
|
13836
|
-
|
|
13837
|
-
!*** /Users/alasarr/dev/deck.gl/node_modules
|
|
13838
|
-
|
|
13835
|
+
/***/ "../../node_modules/gl-matrix/esm/vec3.js":
|
|
13836
|
+
/*!*********************************************************************!*\
|
|
13837
|
+
!*** /Users/alasarr/dev/deck.gl/node_modules/gl-matrix/esm/vec3.js ***!
|
|
13838
|
+
\*********************************************************************/
|
|
13839
13839
|
/*! exports provided: create, clone, length, fromValues, copy, set, add, subtract, multiply, divide, ceil, floor, min, max, round, scale, scaleAndAdd, distance, squaredDistance, squaredLength, negate, inverse, normalize, dot, cross, lerp, hermite, bezier, random, transformMat4, transformMat3, transformQuat, rotateX, rotateY, rotateZ, angle, zero, str, exactEquals, equals, sub, mul, div, dist, sqrDist, len, sqrLen, forEach */
|
|
13840
13840
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
13841
13841
|
|
|
@@ -13889,7 +13889,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
13889
13889
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "len", function() { return len; });
|
|
13890
13890
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sqrLen", function() { return sqrLen; });
|
|
13891
13891
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "forEach", function() { return forEach; });
|
|
13892
|
-
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules
|
|
13892
|
+
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules/gl-matrix/esm/common.js");
|
|
13893
13893
|
|
|
13894
13894
|
/**
|
|
13895
13895
|
* 3 Dimensional Vector
|
|
@@ -14680,10 +14680,10 @@ var forEach = function () {
|
|
|
14680
14680
|
|
|
14681
14681
|
/***/ }),
|
|
14682
14682
|
|
|
14683
|
-
/***/ "../../node_modules
|
|
14684
|
-
|
|
14685
|
-
!*** /Users/alasarr/dev/deck.gl/node_modules
|
|
14686
|
-
|
|
14683
|
+
/***/ "../../node_modules/gl-matrix/esm/vec4.js":
|
|
14684
|
+
/*!*********************************************************************!*\
|
|
14685
|
+
!*** /Users/alasarr/dev/deck.gl/node_modules/gl-matrix/esm/vec4.js ***!
|
|
14686
|
+
\*********************************************************************/
|
|
14687
14687
|
/*! exports provided: create, clone, fromValues, copy, set, add, subtract, multiply, divide, ceil, floor, min, max, round, scale, scaleAndAdd, distance, squaredDistance, length, squaredLength, negate, inverse, normalize, dot, cross, lerp, random, transformMat4, transformQuat, zero, str, exactEquals, equals, sub, mul, div, dist, sqrDist, len, sqrLen, forEach */
|
|
14688
14688
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
14689
14689
|
|
|
@@ -14730,7 +14730,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
14730
14730
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "len", function() { return len; });
|
|
14731
14731
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sqrLen", function() { return sqrLen; });
|
|
14732
14732
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "forEach", function() { return forEach; });
|
|
14733
|
-
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules
|
|
14733
|
+
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules/gl-matrix/esm/common.js");
|
|
14734
14734
|
|
|
14735
14735
|
/**
|
|
14736
14736
|
* 4 Dimensional Vector
|
|
@@ -15397,1034 +15397,126 @@ var forEach = function () {
|
|
|
15397
15397
|
|
|
15398
15398
|
/***/ }),
|
|
15399
15399
|
|
|
15400
|
-
/***/ "
|
|
15401
|
-
|
|
15402
|
-
!***
|
|
15403
|
-
|
|
15404
|
-
/*!
|
|
15405
|
-
/***/ (function(module,
|
|
15406
|
-
|
|
15407
|
-
"use strict";
|
|
15408
|
-
__webpack_require__.r(__webpack_exports__);
|
|
15409
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "EPSILON", function() { return EPSILON; });
|
|
15410
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ARRAY_TYPE", function() { return ARRAY_TYPE; });
|
|
15411
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "RANDOM", function() { return RANDOM; });
|
|
15412
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setMatrixArrayType", function() { return setMatrixArrayType; });
|
|
15413
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "toRadian", function() { return toRadian; });
|
|
15414
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "equals", function() { return equals; });
|
|
15415
|
-
/**
|
|
15416
|
-
* Common utilities
|
|
15417
|
-
* @module glMatrix
|
|
15418
|
-
*/
|
|
15419
|
-
// Configuration Constants
|
|
15420
|
-
var EPSILON = 0.000001;
|
|
15421
|
-
var ARRAY_TYPE = typeof Float32Array !== 'undefined' ? Float32Array : Array;
|
|
15422
|
-
var RANDOM = Math.random;
|
|
15423
|
-
/**
|
|
15424
|
-
* Sets the type of array used when creating new vectors and matrices
|
|
15425
|
-
*
|
|
15426
|
-
* @param {Float32ArrayConstructor | ArrayConstructor} type Array type, such as Float32Array or Array
|
|
15427
|
-
*/
|
|
15400
|
+
/***/ "./bundle.ts":
|
|
15401
|
+
/*!*******************!*\
|
|
15402
|
+
!*** ./bundle.ts ***!
|
|
15403
|
+
\*******************/
|
|
15404
|
+
/*! no static exports found */
|
|
15405
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
15428
15406
|
|
|
15429
|
-
|
|
15430
|
-
ARRAY_TYPE = type;
|
|
15431
|
-
}
|
|
15432
|
-
var degree = Math.PI / 180;
|
|
15433
|
-
/**
|
|
15434
|
-
* Convert Degree To Radian
|
|
15435
|
-
*
|
|
15436
|
-
* @param {Number} a Angle in Degrees
|
|
15437
|
-
*/
|
|
15407
|
+
const Extensions = __webpack_require__(/*! ./src */ "./src/index.ts");
|
|
15438
15408
|
|
|
15439
|
-
|
|
15440
|
-
return a * degree;
|
|
15441
|
-
}
|
|
15442
|
-
/**
|
|
15443
|
-
* Tests whether or not the arguments have approximately the same value, within an absolute
|
|
15444
|
-
* or relative tolerance of glMatrix.EPSILON (an absolute tolerance is used for values less
|
|
15445
|
-
* than or equal to 1.0, and a relative tolerance is used for larger values)
|
|
15446
|
-
*
|
|
15447
|
-
* @param {Number} a The first number to test.
|
|
15448
|
-
* @param {Number} b The second number to test.
|
|
15449
|
-
* @returns {Boolean} True if the numbers are approximately equal, false otherwise.
|
|
15450
|
-
*/
|
|
15409
|
+
const deck = globalThis.deck || {}; // Check if peer dependencies are included
|
|
15451
15410
|
|
|
15452
|
-
|
|
15453
|
-
|
|
15411
|
+
if (!deck.Layer) {
|
|
15412
|
+
throw new Error('@deck.gl/core is not found');
|
|
15454
15413
|
}
|
|
15455
|
-
if (!Math.hypot) Math.hypot = function () {
|
|
15456
|
-
var y = 0,
|
|
15457
|
-
i = arguments.length;
|
|
15458
|
-
|
|
15459
|
-
while (i--) {
|
|
15460
|
-
y += arguments[i] * arguments[i];
|
|
15461
|
-
}
|
|
15462
15414
|
|
|
15463
|
-
|
|
15464
|
-
};
|
|
15415
|
+
module.exports = Object.assign(deck, Extensions);
|
|
15465
15416
|
|
|
15466
15417
|
/***/ }),
|
|
15467
15418
|
|
|
15468
|
-
/***/ "
|
|
15469
|
-
|
|
15470
|
-
!*** /
|
|
15471
|
-
|
|
15472
|
-
/*! exports provided:
|
|
15419
|
+
/***/ "./src/brushing/brushing.ts":
|
|
15420
|
+
/*!**********************************!*\
|
|
15421
|
+
!*** ./src/brushing/brushing.ts ***!
|
|
15422
|
+
\**********************************/
|
|
15423
|
+
/*! exports provided: default */
|
|
15473
15424
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
15474
15425
|
|
|
15475
15426
|
"use strict";
|
|
15476
15427
|
__webpack_require__.r(__webpack_exports__);
|
|
15477
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "
|
|
15478
|
-
/* harmony
|
|
15479
|
-
/* harmony
|
|
15480
|
-
/* harmony
|
|
15481
|
-
|
|
15482
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "set", function() { return set; });
|
|
15483
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "add", function() { return add; });
|
|
15484
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "subtract", function() { return subtract; });
|
|
15485
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "multiply", function() { return multiply; });
|
|
15486
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "divide", function() { return divide; });
|
|
15487
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ceil", function() { return ceil; });
|
|
15488
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "floor", function() { return floor; });
|
|
15489
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "min", function() { return min; });
|
|
15490
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "max", function() { return max; });
|
|
15491
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "round", function() { return round; });
|
|
15492
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "scale", function() { return scale; });
|
|
15493
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "scaleAndAdd", function() { return scaleAndAdd; });
|
|
15494
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "distance", function() { return distance; });
|
|
15495
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "squaredDistance", function() { return squaredDistance; });
|
|
15496
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "squaredLength", function() { return squaredLength; });
|
|
15497
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "negate", function() { return negate; });
|
|
15498
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "inverse", function() { return inverse; });
|
|
15499
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "normalize", function() { return normalize; });
|
|
15500
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "dot", function() { return dot; });
|
|
15501
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cross", function() { return cross; });
|
|
15502
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "lerp", function() { return lerp; });
|
|
15503
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "hermite", function() { return hermite; });
|
|
15504
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "bezier", function() { return bezier; });
|
|
15505
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "random", function() { return random; });
|
|
15506
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "transformMat4", function() { return transformMat4; });
|
|
15507
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "transformMat3", function() { return transformMat3; });
|
|
15508
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "transformQuat", function() { return transformQuat; });
|
|
15509
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rotateX", function() { return rotateX; });
|
|
15510
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rotateY", function() { return rotateY; });
|
|
15511
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rotateZ", function() { return rotateZ; });
|
|
15512
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "angle", function() { return angle; });
|
|
15513
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "zero", function() { return zero; });
|
|
15514
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "str", function() { return str; });
|
|
15515
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "exactEquals", function() { return exactEquals; });
|
|
15516
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "equals", function() { return equals; });
|
|
15517
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sub", function() { return sub; });
|
|
15518
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "mul", function() { return mul; });
|
|
15519
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "div", function() { return div; });
|
|
15520
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "dist", function() { return dist; });
|
|
15521
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sqrDist", function() { return sqrDist; });
|
|
15522
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "len", function() { return len; });
|
|
15523
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sqrLen", function() { return sqrLen; });
|
|
15524
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "forEach", function() { return forEach; });
|
|
15525
|
-
/* harmony import */ var _common_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./common.js */ "../../node_modules/gl-matrix/esm/common.js");
|
|
15428
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return BrushingExtension; });
|
|
15429
|
+
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
15430
|
+
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_0__);
|
|
15431
|
+
/* harmony import */ var _shader_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shader-module */ "./src/brushing/shader-module.ts");
|
|
15432
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
15526
15433
|
|
|
15527
|
-
|
|
15528
|
-
|
|
15529
|
-
|
|
15530
|
-
|
|
15434
|
+
// Copyright (c) 2015 - 2017 Uber Technologies, Inc.
|
|
15435
|
+
//
|
|
15436
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
15437
|
+
// of this software and associated documentation files (the "Software"), to deal
|
|
15438
|
+
// in the Software without restriction, including without limitation the rights
|
|
15439
|
+
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
15440
|
+
// copies of the Software, and to permit persons to whom the Software is
|
|
15441
|
+
// furnished to do so, subject to the following conditions:
|
|
15442
|
+
//
|
|
15443
|
+
// The above copyright notice and this permission notice shall be included in
|
|
15444
|
+
// all copies or substantial portions of the Software.
|
|
15445
|
+
//
|
|
15446
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15447
|
+
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
15448
|
+
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
15449
|
+
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
15450
|
+
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
15451
|
+
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
15452
|
+
// THE SOFTWARE.
|
|
15531
15453
|
|
|
15532
|
-
/**
|
|
15533
|
-
* Creates a new, empty vec3
|
|
15534
|
-
*
|
|
15535
|
-
* @returns {vec3} a new 3D vector
|
|
15536
|
-
*/
|
|
15537
15454
|
|
|
15538
|
-
|
|
15539
|
-
|
|
15455
|
+
const defaultProps = {
|
|
15456
|
+
getBrushingTarget: {
|
|
15457
|
+
type: 'accessor',
|
|
15458
|
+
value: [0, 0]
|
|
15459
|
+
},
|
|
15460
|
+
brushingTarget: 'source',
|
|
15461
|
+
brushingEnabled: true,
|
|
15462
|
+
brushingRadius: 10000
|
|
15463
|
+
};
|
|
15540
15464
|
|
|
15541
|
-
|
|
15542
|
-
|
|
15543
|
-
|
|
15544
|
-
|
|
15465
|
+
/** Adds GPU-based data brushing functionalities to layers. It allows the layer to show/hide objects based on the current pointer position. */
|
|
15466
|
+
class BrushingExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExtension"] {
|
|
15467
|
+
getShaders() {
|
|
15468
|
+
return {
|
|
15469
|
+
modules: [_shader_module__WEBPACK_IMPORTED_MODULE_1__["default"]]
|
|
15470
|
+
};
|
|
15545
15471
|
}
|
|
15546
15472
|
|
|
15547
|
-
|
|
15548
|
-
|
|
15549
|
-
/**
|
|
15550
|
-
* Creates a new vec3 initialized with values from an existing vector
|
|
15551
|
-
*
|
|
15552
|
-
* @param {ReadonlyVec3} a vector to clone
|
|
15553
|
-
* @returns {vec3} a new 3D vector
|
|
15554
|
-
*/
|
|
15473
|
+
initializeState(context, extension) {
|
|
15474
|
+
const attributeManager = this.getAttributeManager();
|
|
15555
15475
|
|
|
15556
|
-
|
|
15557
|
-
|
|
15558
|
-
|
|
15559
|
-
|
|
15560
|
-
|
|
15561
|
-
|
|
15562
|
-
|
|
15563
|
-
|
|
15564
|
-
|
|
15565
|
-
|
|
15566
|
-
|
|
15567
|
-
|
|
15568
|
-
|
|
15476
|
+
if (attributeManager) {
|
|
15477
|
+
attributeManager.add({
|
|
15478
|
+
brushingTargets: {
|
|
15479
|
+
size: 2,
|
|
15480
|
+
accessor: 'getBrushingTarget',
|
|
15481
|
+
// Hack: extension's defaultProps is not merged with the layer's defaultProps,
|
|
15482
|
+
// So we can't use the standard accessor when the prop is undefined
|
|
15483
|
+
// TODO - move to an option
|
|
15484
|
+
// eslint-disable-next-line @typescript-eslint/unbound-method
|
|
15485
|
+
update: this.props.getBrushingTarget ? undefined : extension.useConstantTargetPositions,
|
|
15486
|
+
shaderAttributes: {
|
|
15487
|
+
brushingTargets: {
|
|
15488
|
+
divisor: 0
|
|
15489
|
+
},
|
|
15490
|
+
instanceBrushingTargets: {
|
|
15491
|
+
divisor: 1
|
|
15492
|
+
}
|
|
15493
|
+
}
|
|
15494
|
+
}
|
|
15495
|
+
});
|
|
15496
|
+
} // Trigger redraw when mouse moves
|
|
15497
|
+
// TODO - expose this in a better way
|
|
15569
15498
|
|
|
15570
|
-
function length(a) {
|
|
15571
|
-
var x = a[0];
|
|
15572
|
-
var y = a[1];
|
|
15573
|
-
var z = a[2];
|
|
15574
|
-
return Math.hypot(x, y, z);
|
|
15575
|
-
}
|
|
15576
|
-
/**
|
|
15577
|
-
* Creates a new vec3 initialized with the given values
|
|
15578
|
-
*
|
|
15579
|
-
* @param {Number} x X component
|
|
15580
|
-
* @param {Number} y Y component
|
|
15581
|
-
* @param {Number} z Z component
|
|
15582
|
-
* @returns {vec3} a new 3D vector
|
|
15583
|
-
*/
|
|
15584
15499
|
|
|
15585
|
-
|
|
15586
|
-
|
|
15587
|
-
|
|
15588
|
-
out[1] = y;
|
|
15589
|
-
out[2] = z;
|
|
15590
|
-
return out;
|
|
15591
|
-
}
|
|
15592
|
-
/**
|
|
15593
|
-
* Copy the values from one vec3 to another
|
|
15594
|
-
*
|
|
15595
|
-
* @param {vec3} out the receiving vector
|
|
15596
|
-
* @param {ReadonlyVec3} a the source vector
|
|
15597
|
-
* @returns {vec3} out
|
|
15598
|
-
*/
|
|
15500
|
+
this.state.onMouseMove = () => {
|
|
15501
|
+
this.getCurrentLayer()?.setNeedsRedraw();
|
|
15502
|
+
};
|
|
15599
15503
|
|
|
15600
|
-
|
|
15601
|
-
|
|
15602
|
-
|
|
15603
|
-
|
|
15604
|
-
|
|
15605
|
-
}
|
|
15606
|
-
|
|
15607
|
-
|
|
15608
|
-
*
|
|
15609
|
-
* @param {vec3} out the receiving vector
|
|
15610
|
-
* @param {Number} x X component
|
|
15611
|
-
* @param {Number} y Y component
|
|
15612
|
-
* @param {Number} z Z component
|
|
15613
|
-
* @returns {vec3} out
|
|
15614
|
-
*/
|
|
15504
|
+
if (context.deck) {
|
|
15505
|
+
// @ts-expect-error (2446) accessing protected property
|
|
15506
|
+
context.deck.eventManager.on({
|
|
15507
|
+
pointermove: this.state.onMouseMove,
|
|
15508
|
+
pointerleave: this.state.onMouseMove
|
|
15509
|
+
});
|
|
15510
|
+
}
|
|
15511
|
+
}
|
|
15615
15512
|
|
|
15616
|
-
|
|
15617
|
-
out[0] = x;
|
|
15618
|
-
out[1] = y;
|
|
15619
|
-
out[2] = z;
|
|
15620
|
-
return out;
|
|
15621
|
-
}
|
|
15622
|
-
/**
|
|
15623
|
-
* Adds two vec3's
|
|
15624
|
-
*
|
|
15625
|
-
* @param {vec3} out the receiving vector
|
|
15626
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15627
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15628
|
-
* @returns {vec3} out
|
|
15629
|
-
*/
|
|
15630
|
-
|
|
15631
|
-
function add(out, a, b) {
|
|
15632
|
-
out[0] = a[0] + b[0];
|
|
15633
|
-
out[1] = a[1] + b[1];
|
|
15634
|
-
out[2] = a[2] + b[2];
|
|
15635
|
-
return out;
|
|
15636
|
-
}
|
|
15637
|
-
/**
|
|
15638
|
-
* Subtracts vector b from vector a
|
|
15639
|
-
*
|
|
15640
|
-
* @param {vec3} out the receiving vector
|
|
15641
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15642
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15643
|
-
* @returns {vec3} out
|
|
15644
|
-
*/
|
|
15645
|
-
|
|
15646
|
-
function subtract(out, a, b) {
|
|
15647
|
-
out[0] = a[0] - b[0];
|
|
15648
|
-
out[1] = a[1] - b[1];
|
|
15649
|
-
out[2] = a[2] - b[2];
|
|
15650
|
-
return out;
|
|
15651
|
-
}
|
|
15652
|
-
/**
|
|
15653
|
-
* Multiplies two vec3's
|
|
15654
|
-
*
|
|
15655
|
-
* @param {vec3} out the receiving vector
|
|
15656
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15657
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15658
|
-
* @returns {vec3} out
|
|
15659
|
-
*/
|
|
15660
|
-
|
|
15661
|
-
function multiply(out, a, b) {
|
|
15662
|
-
out[0] = a[0] * b[0];
|
|
15663
|
-
out[1] = a[1] * b[1];
|
|
15664
|
-
out[2] = a[2] * b[2];
|
|
15665
|
-
return out;
|
|
15666
|
-
}
|
|
15667
|
-
/**
|
|
15668
|
-
* Divides two vec3's
|
|
15669
|
-
*
|
|
15670
|
-
* @param {vec3} out the receiving vector
|
|
15671
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15672
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15673
|
-
* @returns {vec3} out
|
|
15674
|
-
*/
|
|
15675
|
-
|
|
15676
|
-
function divide(out, a, b) {
|
|
15677
|
-
out[0] = a[0] / b[0];
|
|
15678
|
-
out[1] = a[1] / b[1];
|
|
15679
|
-
out[2] = a[2] / b[2];
|
|
15680
|
-
return out;
|
|
15681
|
-
}
|
|
15682
|
-
/**
|
|
15683
|
-
* Math.ceil the components of a vec3
|
|
15684
|
-
*
|
|
15685
|
-
* @param {vec3} out the receiving vector
|
|
15686
|
-
* @param {ReadonlyVec3} a vector to ceil
|
|
15687
|
-
* @returns {vec3} out
|
|
15688
|
-
*/
|
|
15689
|
-
|
|
15690
|
-
function ceil(out, a) {
|
|
15691
|
-
out[0] = Math.ceil(a[0]);
|
|
15692
|
-
out[1] = Math.ceil(a[1]);
|
|
15693
|
-
out[2] = Math.ceil(a[2]);
|
|
15694
|
-
return out;
|
|
15695
|
-
}
|
|
15696
|
-
/**
|
|
15697
|
-
* Math.floor the components of a vec3
|
|
15698
|
-
*
|
|
15699
|
-
* @param {vec3} out the receiving vector
|
|
15700
|
-
* @param {ReadonlyVec3} a vector to floor
|
|
15701
|
-
* @returns {vec3} out
|
|
15702
|
-
*/
|
|
15703
|
-
|
|
15704
|
-
function floor(out, a) {
|
|
15705
|
-
out[0] = Math.floor(a[0]);
|
|
15706
|
-
out[1] = Math.floor(a[1]);
|
|
15707
|
-
out[2] = Math.floor(a[2]);
|
|
15708
|
-
return out;
|
|
15709
|
-
}
|
|
15710
|
-
/**
|
|
15711
|
-
* Returns the minimum of two vec3's
|
|
15712
|
-
*
|
|
15713
|
-
* @param {vec3} out the receiving vector
|
|
15714
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15715
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15716
|
-
* @returns {vec3} out
|
|
15717
|
-
*/
|
|
15718
|
-
|
|
15719
|
-
function min(out, a, b) {
|
|
15720
|
-
out[0] = Math.min(a[0], b[0]);
|
|
15721
|
-
out[1] = Math.min(a[1], b[1]);
|
|
15722
|
-
out[2] = Math.min(a[2], b[2]);
|
|
15723
|
-
return out;
|
|
15724
|
-
}
|
|
15725
|
-
/**
|
|
15726
|
-
* Returns the maximum of two vec3's
|
|
15727
|
-
*
|
|
15728
|
-
* @param {vec3} out the receiving vector
|
|
15729
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15730
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15731
|
-
* @returns {vec3} out
|
|
15732
|
-
*/
|
|
15733
|
-
|
|
15734
|
-
function max(out, a, b) {
|
|
15735
|
-
out[0] = Math.max(a[0], b[0]);
|
|
15736
|
-
out[1] = Math.max(a[1], b[1]);
|
|
15737
|
-
out[2] = Math.max(a[2], b[2]);
|
|
15738
|
-
return out;
|
|
15739
|
-
}
|
|
15740
|
-
/**
|
|
15741
|
-
* Math.round the components of a vec3
|
|
15742
|
-
*
|
|
15743
|
-
* @param {vec3} out the receiving vector
|
|
15744
|
-
* @param {ReadonlyVec3} a vector to round
|
|
15745
|
-
* @returns {vec3} out
|
|
15746
|
-
*/
|
|
15747
|
-
|
|
15748
|
-
function round(out, a) {
|
|
15749
|
-
out[0] = Math.round(a[0]);
|
|
15750
|
-
out[1] = Math.round(a[1]);
|
|
15751
|
-
out[2] = Math.round(a[2]);
|
|
15752
|
-
return out;
|
|
15753
|
-
}
|
|
15754
|
-
/**
|
|
15755
|
-
* Scales a vec3 by a scalar number
|
|
15756
|
-
*
|
|
15757
|
-
* @param {vec3} out the receiving vector
|
|
15758
|
-
* @param {ReadonlyVec3} a the vector to scale
|
|
15759
|
-
* @param {Number} b amount to scale the vector by
|
|
15760
|
-
* @returns {vec3} out
|
|
15761
|
-
*/
|
|
15762
|
-
|
|
15763
|
-
function scale(out, a, b) {
|
|
15764
|
-
out[0] = a[0] * b;
|
|
15765
|
-
out[1] = a[1] * b;
|
|
15766
|
-
out[2] = a[2] * b;
|
|
15767
|
-
return out;
|
|
15768
|
-
}
|
|
15769
|
-
/**
|
|
15770
|
-
* Adds two vec3's after scaling the second operand by a scalar value
|
|
15771
|
-
*
|
|
15772
|
-
* @param {vec3} out the receiving vector
|
|
15773
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15774
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15775
|
-
* @param {Number} scale the amount to scale b by before adding
|
|
15776
|
-
* @returns {vec3} out
|
|
15777
|
-
*/
|
|
15778
|
-
|
|
15779
|
-
function scaleAndAdd(out, a, b, scale) {
|
|
15780
|
-
out[0] = a[0] + b[0] * scale;
|
|
15781
|
-
out[1] = a[1] + b[1] * scale;
|
|
15782
|
-
out[2] = a[2] + b[2] * scale;
|
|
15783
|
-
return out;
|
|
15784
|
-
}
|
|
15785
|
-
/**
|
|
15786
|
-
* Calculates the euclidian distance between two vec3's
|
|
15787
|
-
*
|
|
15788
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15789
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15790
|
-
* @returns {Number} distance between a and b
|
|
15791
|
-
*/
|
|
15792
|
-
|
|
15793
|
-
function distance(a, b) {
|
|
15794
|
-
var x = b[0] - a[0];
|
|
15795
|
-
var y = b[1] - a[1];
|
|
15796
|
-
var z = b[2] - a[2];
|
|
15797
|
-
return Math.hypot(x, y, z);
|
|
15798
|
-
}
|
|
15799
|
-
/**
|
|
15800
|
-
* Calculates the squared euclidian distance between two vec3's
|
|
15801
|
-
*
|
|
15802
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15803
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15804
|
-
* @returns {Number} squared distance between a and b
|
|
15805
|
-
*/
|
|
15806
|
-
|
|
15807
|
-
function squaredDistance(a, b) {
|
|
15808
|
-
var x = b[0] - a[0];
|
|
15809
|
-
var y = b[1] - a[1];
|
|
15810
|
-
var z = b[2] - a[2];
|
|
15811
|
-
return x * x + y * y + z * z;
|
|
15812
|
-
}
|
|
15813
|
-
/**
|
|
15814
|
-
* Calculates the squared length of a vec3
|
|
15815
|
-
*
|
|
15816
|
-
* @param {ReadonlyVec3} a vector to calculate squared length of
|
|
15817
|
-
* @returns {Number} squared length of a
|
|
15818
|
-
*/
|
|
15819
|
-
|
|
15820
|
-
function squaredLength(a) {
|
|
15821
|
-
var x = a[0];
|
|
15822
|
-
var y = a[1];
|
|
15823
|
-
var z = a[2];
|
|
15824
|
-
return x * x + y * y + z * z;
|
|
15825
|
-
}
|
|
15826
|
-
/**
|
|
15827
|
-
* Negates the components of a vec3
|
|
15828
|
-
*
|
|
15829
|
-
* @param {vec3} out the receiving vector
|
|
15830
|
-
* @param {ReadonlyVec3} a vector to negate
|
|
15831
|
-
* @returns {vec3} out
|
|
15832
|
-
*/
|
|
15833
|
-
|
|
15834
|
-
function negate(out, a) {
|
|
15835
|
-
out[0] = -a[0];
|
|
15836
|
-
out[1] = -a[1];
|
|
15837
|
-
out[2] = -a[2];
|
|
15838
|
-
return out;
|
|
15839
|
-
}
|
|
15840
|
-
/**
|
|
15841
|
-
* Returns the inverse of the components of a vec3
|
|
15842
|
-
*
|
|
15843
|
-
* @param {vec3} out the receiving vector
|
|
15844
|
-
* @param {ReadonlyVec3} a vector to invert
|
|
15845
|
-
* @returns {vec3} out
|
|
15846
|
-
*/
|
|
15847
|
-
|
|
15848
|
-
function inverse(out, a) {
|
|
15849
|
-
out[0] = 1.0 / a[0];
|
|
15850
|
-
out[1] = 1.0 / a[1];
|
|
15851
|
-
out[2] = 1.0 / a[2];
|
|
15852
|
-
return out;
|
|
15853
|
-
}
|
|
15854
|
-
/**
|
|
15855
|
-
* Normalize a vec3
|
|
15856
|
-
*
|
|
15857
|
-
* @param {vec3} out the receiving vector
|
|
15858
|
-
* @param {ReadonlyVec3} a vector to normalize
|
|
15859
|
-
* @returns {vec3} out
|
|
15860
|
-
*/
|
|
15861
|
-
|
|
15862
|
-
function normalize(out, a) {
|
|
15863
|
-
var x = a[0];
|
|
15864
|
-
var y = a[1];
|
|
15865
|
-
var z = a[2];
|
|
15866
|
-
var len = x * x + y * y + z * z;
|
|
15867
|
-
|
|
15868
|
-
if (len > 0) {
|
|
15869
|
-
//TODO: evaluate use of glm_invsqrt here?
|
|
15870
|
-
len = 1 / Math.sqrt(len);
|
|
15871
|
-
}
|
|
15872
|
-
|
|
15873
|
-
out[0] = a[0] * len;
|
|
15874
|
-
out[1] = a[1] * len;
|
|
15875
|
-
out[2] = a[2] * len;
|
|
15876
|
-
return out;
|
|
15877
|
-
}
|
|
15878
|
-
/**
|
|
15879
|
-
* Calculates the dot product of two vec3's
|
|
15880
|
-
*
|
|
15881
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15882
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15883
|
-
* @returns {Number} dot product of a and b
|
|
15884
|
-
*/
|
|
15885
|
-
|
|
15886
|
-
function dot(a, b) {
|
|
15887
|
-
return a[0] * b[0] + a[1] * b[1] + a[2] * b[2];
|
|
15888
|
-
}
|
|
15889
|
-
/**
|
|
15890
|
-
* Computes the cross product of two vec3's
|
|
15891
|
-
*
|
|
15892
|
-
* @param {vec3} out the receiving vector
|
|
15893
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15894
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15895
|
-
* @returns {vec3} out
|
|
15896
|
-
*/
|
|
15897
|
-
|
|
15898
|
-
function cross(out, a, b) {
|
|
15899
|
-
var ax = a[0],
|
|
15900
|
-
ay = a[1],
|
|
15901
|
-
az = a[2];
|
|
15902
|
-
var bx = b[0],
|
|
15903
|
-
by = b[1],
|
|
15904
|
-
bz = b[2];
|
|
15905
|
-
out[0] = ay * bz - az * by;
|
|
15906
|
-
out[1] = az * bx - ax * bz;
|
|
15907
|
-
out[2] = ax * by - ay * bx;
|
|
15908
|
-
return out;
|
|
15909
|
-
}
|
|
15910
|
-
/**
|
|
15911
|
-
* Performs a linear interpolation between two vec3's
|
|
15912
|
-
*
|
|
15913
|
-
* @param {vec3} out the receiving vector
|
|
15914
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15915
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15916
|
-
* @param {Number} t interpolation amount, in the range [0-1], between the two inputs
|
|
15917
|
-
* @returns {vec3} out
|
|
15918
|
-
*/
|
|
15919
|
-
|
|
15920
|
-
function lerp(out, a, b, t) {
|
|
15921
|
-
var ax = a[0];
|
|
15922
|
-
var ay = a[1];
|
|
15923
|
-
var az = a[2];
|
|
15924
|
-
out[0] = ax + t * (b[0] - ax);
|
|
15925
|
-
out[1] = ay + t * (b[1] - ay);
|
|
15926
|
-
out[2] = az + t * (b[2] - az);
|
|
15927
|
-
return out;
|
|
15928
|
-
}
|
|
15929
|
-
/**
|
|
15930
|
-
* Performs a hermite interpolation with two control points
|
|
15931
|
-
*
|
|
15932
|
-
* @param {vec3} out the receiving vector
|
|
15933
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15934
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15935
|
-
* @param {ReadonlyVec3} c the third operand
|
|
15936
|
-
* @param {ReadonlyVec3} d the fourth operand
|
|
15937
|
-
* @param {Number} t interpolation amount, in the range [0-1], between the two inputs
|
|
15938
|
-
* @returns {vec3} out
|
|
15939
|
-
*/
|
|
15940
|
-
|
|
15941
|
-
function hermite(out, a, b, c, d, t) {
|
|
15942
|
-
var factorTimes2 = t * t;
|
|
15943
|
-
var factor1 = factorTimes2 * (2 * t - 3) + 1;
|
|
15944
|
-
var factor2 = factorTimes2 * (t - 2) + t;
|
|
15945
|
-
var factor3 = factorTimes2 * (t - 1);
|
|
15946
|
-
var factor4 = factorTimes2 * (3 - 2 * t);
|
|
15947
|
-
out[0] = a[0] * factor1 + b[0] * factor2 + c[0] * factor3 + d[0] * factor4;
|
|
15948
|
-
out[1] = a[1] * factor1 + b[1] * factor2 + c[1] * factor3 + d[1] * factor4;
|
|
15949
|
-
out[2] = a[2] * factor1 + b[2] * factor2 + c[2] * factor3 + d[2] * factor4;
|
|
15950
|
-
return out;
|
|
15951
|
-
}
|
|
15952
|
-
/**
|
|
15953
|
-
* Performs a bezier interpolation with two control points
|
|
15954
|
-
*
|
|
15955
|
-
* @param {vec3} out the receiving vector
|
|
15956
|
-
* @param {ReadonlyVec3} a the first operand
|
|
15957
|
-
* @param {ReadonlyVec3} b the second operand
|
|
15958
|
-
* @param {ReadonlyVec3} c the third operand
|
|
15959
|
-
* @param {ReadonlyVec3} d the fourth operand
|
|
15960
|
-
* @param {Number} t interpolation amount, in the range [0-1], between the two inputs
|
|
15961
|
-
* @returns {vec3} out
|
|
15962
|
-
*/
|
|
15963
|
-
|
|
15964
|
-
function bezier(out, a, b, c, d, t) {
|
|
15965
|
-
var inverseFactor = 1 - t;
|
|
15966
|
-
var inverseFactorTimesTwo = inverseFactor * inverseFactor;
|
|
15967
|
-
var factorTimes2 = t * t;
|
|
15968
|
-
var factor1 = inverseFactorTimesTwo * inverseFactor;
|
|
15969
|
-
var factor2 = 3 * t * inverseFactorTimesTwo;
|
|
15970
|
-
var factor3 = 3 * factorTimes2 * inverseFactor;
|
|
15971
|
-
var factor4 = factorTimes2 * t;
|
|
15972
|
-
out[0] = a[0] * factor1 + b[0] * factor2 + c[0] * factor3 + d[0] * factor4;
|
|
15973
|
-
out[1] = a[1] * factor1 + b[1] * factor2 + c[1] * factor3 + d[1] * factor4;
|
|
15974
|
-
out[2] = a[2] * factor1 + b[2] * factor2 + c[2] * factor3 + d[2] * factor4;
|
|
15975
|
-
return out;
|
|
15976
|
-
}
|
|
15977
|
-
/**
|
|
15978
|
-
* Generates a random vector with the given scale
|
|
15979
|
-
*
|
|
15980
|
-
* @param {vec3} out the receiving vector
|
|
15981
|
-
* @param {Number} [scale] Length of the resulting vector. If ommitted, a unit vector will be returned
|
|
15982
|
-
* @returns {vec3} out
|
|
15983
|
-
*/
|
|
15984
|
-
|
|
15985
|
-
function random(out, scale) {
|
|
15986
|
-
scale = scale || 1.0;
|
|
15987
|
-
var r = _common_js__WEBPACK_IMPORTED_MODULE_0__["RANDOM"]() * 2.0 * Math.PI;
|
|
15988
|
-
var z = _common_js__WEBPACK_IMPORTED_MODULE_0__["RANDOM"]() * 2.0 - 1.0;
|
|
15989
|
-
var zScale = Math.sqrt(1.0 - z * z) * scale;
|
|
15990
|
-
out[0] = Math.cos(r) * zScale;
|
|
15991
|
-
out[1] = Math.sin(r) * zScale;
|
|
15992
|
-
out[2] = z * scale;
|
|
15993
|
-
return out;
|
|
15994
|
-
}
|
|
15995
|
-
/**
|
|
15996
|
-
* Transforms the vec3 with a mat4.
|
|
15997
|
-
* 4th vector component is implicitly '1'
|
|
15998
|
-
*
|
|
15999
|
-
* @param {vec3} out the receiving vector
|
|
16000
|
-
* @param {ReadonlyVec3} a the vector to transform
|
|
16001
|
-
* @param {ReadonlyMat4} m matrix to transform with
|
|
16002
|
-
* @returns {vec3} out
|
|
16003
|
-
*/
|
|
16004
|
-
|
|
16005
|
-
function transformMat4(out, a, m) {
|
|
16006
|
-
var x = a[0],
|
|
16007
|
-
y = a[1],
|
|
16008
|
-
z = a[2];
|
|
16009
|
-
var w = m[3] * x + m[7] * y + m[11] * z + m[15];
|
|
16010
|
-
w = w || 1.0;
|
|
16011
|
-
out[0] = (m[0] * x + m[4] * y + m[8] * z + m[12]) / w;
|
|
16012
|
-
out[1] = (m[1] * x + m[5] * y + m[9] * z + m[13]) / w;
|
|
16013
|
-
out[2] = (m[2] * x + m[6] * y + m[10] * z + m[14]) / w;
|
|
16014
|
-
return out;
|
|
16015
|
-
}
|
|
16016
|
-
/**
|
|
16017
|
-
* Transforms the vec3 with a mat3.
|
|
16018
|
-
*
|
|
16019
|
-
* @param {vec3} out the receiving vector
|
|
16020
|
-
* @param {ReadonlyVec3} a the vector to transform
|
|
16021
|
-
* @param {ReadonlyMat3} m the 3x3 matrix to transform with
|
|
16022
|
-
* @returns {vec3} out
|
|
16023
|
-
*/
|
|
16024
|
-
|
|
16025
|
-
function transformMat3(out, a, m) {
|
|
16026
|
-
var x = a[0],
|
|
16027
|
-
y = a[1],
|
|
16028
|
-
z = a[2];
|
|
16029
|
-
out[0] = x * m[0] + y * m[3] + z * m[6];
|
|
16030
|
-
out[1] = x * m[1] + y * m[4] + z * m[7];
|
|
16031
|
-
out[2] = x * m[2] + y * m[5] + z * m[8];
|
|
16032
|
-
return out;
|
|
16033
|
-
}
|
|
16034
|
-
/**
|
|
16035
|
-
* Transforms the vec3 with a quat
|
|
16036
|
-
* Can also be used for dual quaternions. (Multiply it with the real part)
|
|
16037
|
-
*
|
|
16038
|
-
* @param {vec3} out the receiving vector
|
|
16039
|
-
* @param {ReadonlyVec3} a the vector to transform
|
|
16040
|
-
* @param {ReadonlyQuat} q quaternion to transform with
|
|
16041
|
-
* @returns {vec3} out
|
|
16042
|
-
*/
|
|
16043
|
-
|
|
16044
|
-
function transformQuat(out, a, q) {
|
|
16045
|
-
// benchmarks: https://jsperf.com/quaternion-transform-vec3-implementations-fixed
|
|
16046
|
-
var qx = q[0],
|
|
16047
|
-
qy = q[1],
|
|
16048
|
-
qz = q[2],
|
|
16049
|
-
qw = q[3];
|
|
16050
|
-
var x = a[0],
|
|
16051
|
-
y = a[1],
|
|
16052
|
-
z = a[2]; // var qvec = [qx, qy, qz];
|
|
16053
|
-
// var uv = vec3.cross([], qvec, a);
|
|
16054
|
-
|
|
16055
|
-
var uvx = qy * z - qz * y,
|
|
16056
|
-
uvy = qz * x - qx * z,
|
|
16057
|
-
uvz = qx * y - qy * x; // var uuv = vec3.cross([], qvec, uv);
|
|
16058
|
-
|
|
16059
|
-
var uuvx = qy * uvz - qz * uvy,
|
|
16060
|
-
uuvy = qz * uvx - qx * uvz,
|
|
16061
|
-
uuvz = qx * uvy - qy * uvx; // vec3.scale(uv, uv, 2 * w);
|
|
16062
|
-
|
|
16063
|
-
var w2 = qw * 2;
|
|
16064
|
-
uvx *= w2;
|
|
16065
|
-
uvy *= w2;
|
|
16066
|
-
uvz *= w2; // vec3.scale(uuv, uuv, 2);
|
|
16067
|
-
|
|
16068
|
-
uuvx *= 2;
|
|
16069
|
-
uuvy *= 2;
|
|
16070
|
-
uuvz *= 2; // return vec3.add(out, a, vec3.add(out, uv, uuv));
|
|
16071
|
-
|
|
16072
|
-
out[0] = x + uvx + uuvx;
|
|
16073
|
-
out[1] = y + uvy + uuvy;
|
|
16074
|
-
out[2] = z + uvz + uuvz;
|
|
16075
|
-
return out;
|
|
16076
|
-
}
|
|
16077
|
-
/**
|
|
16078
|
-
* Rotate a 3D vector around the x-axis
|
|
16079
|
-
* @param {vec3} out The receiving vec3
|
|
16080
|
-
* @param {ReadonlyVec3} a The vec3 point to rotate
|
|
16081
|
-
* @param {ReadonlyVec3} b The origin of the rotation
|
|
16082
|
-
* @param {Number} rad The angle of rotation in radians
|
|
16083
|
-
* @returns {vec3} out
|
|
16084
|
-
*/
|
|
16085
|
-
|
|
16086
|
-
function rotateX(out, a, b, rad) {
|
|
16087
|
-
var p = [],
|
|
16088
|
-
r = []; //Translate point to the origin
|
|
16089
|
-
|
|
16090
|
-
p[0] = a[0] - b[0];
|
|
16091
|
-
p[1] = a[1] - b[1];
|
|
16092
|
-
p[2] = a[2] - b[2]; //perform rotation
|
|
16093
|
-
|
|
16094
|
-
r[0] = p[0];
|
|
16095
|
-
r[1] = p[1] * Math.cos(rad) - p[2] * Math.sin(rad);
|
|
16096
|
-
r[2] = p[1] * Math.sin(rad) + p[2] * Math.cos(rad); //translate to correct position
|
|
16097
|
-
|
|
16098
|
-
out[0] = r[0] + b[0];
|
|
16099
|
-
out[1] = r[1] + b[1];
|
|
16100
|
-
out[2] = r[2] + b[2];
|
|
16101
|
-
return out;
|
|
16102
|
-
}
|
|
16103
|
-
/**
|
|
16104
|
-
* Rotate a 3D vector around the y-axis
|
|
16105
|
-
* @param {vec3} out The receiving vec3
|
|
16106
|
-
* @param {ReadonlyVec3} a The vec3 point to rotate
|
|
16107
|
-
* @param {ReadonlyVec3} b The origin of the rotation
|
|
16108
|
-
* @param {Number} rad The angle of rotation in radians
|
|
16109
|
-
* @returns {vec3} out
|
|
16110
|
-
*/
|
|
16111
|
-
|
|
16112
|
-
function rotateY(out, a, b, rad) {
|
|
16113
|
-
var p = [],
|
|
16114
|
-
r = []; //Translate point to the origin
|
|
16115
|
-
|
|
16116
|
-
p[0] = a[0] - b[0];
|
|
16117
|
-
p[1] = a[1] - b[1];
|
|
16118
|
-
p[2] = a[2] - b[2]; //perform rotation
|
|
16119
|
-
|
|
16120
|
-
r[0] = p[2] * Math.sin(rad) + p[0] * Math.cos(rad);
|
|
16121
|
-
r[1] = p[1];
|
|
16122
|
-
r[2] = p[2] * Math.cos(rad) - p[0] * Math.sin(rad); //translate to correct position
|
|
16123
|
-
|
|
16124
|
-
out[0] = r[0] + b[0];
|
|
16125
|
-
out[1] = r[1] + b[1];
|
|
16126
|
-
out[2] = r[2] + b[2];
|
|
16127
|
-
return out;
|
|
16128
|
-
}
|
|
16129
|
-
/**
|
|
16130
|
-
* Rotate a 3D vector around the z-axis
|
|
16131
|
-
* @param {vec3} out The receiving vec3
|
|
16132
|
-
* @param {ReadonlyVec3} a The vec3 point to rotate
|
|
16133
|
-
* @param {ReadonlyVec3} b The origin of the rotation
|
|
16134
|
-
* @param {Number} rad The angle of rotation in radians
|
|
16135
|
-
* @returns {vec3} out
|
|
16136
|
-
*/
|
|
16137
|
-
|
|
16138
|
-
function rotateZ(out, a, b, rad) {
|
|
16139
|
-
var p = [],
|
|
16140
|
-
r = []; //Translate point to the origin
|
|
16141
|
-
|
|
16142
|
-
p[0] = a[0] - b[0];
|
|
16143
|
-
p[1] = a[1] - b[1];
|
|
16144
|
-
p[2] = a[2] - b[2]; //perform rotation
|
|
16145
|
-
|
|
16146
|
-
r[0] = p[0] * Math.cos(rad) - p[1] * Math.sin(rad);
|
|
16147
|
-
r[1] = p[0] * Math.sin(rad) + p[1] * Math.cos(rad);
|
|
16148
|
-
r[2] = p[2]; //translate to correct position
|
|
16149
|
-
|
|
16150
|
-
out[0] = r[0] + b[0];
|
|
16151
|
-
out[1] = r[1] + b[1];
|
|
16152
|
-
out[2] = r[2] + b[2];
|
|
16153
|
-
return out;
|
|
16154
|
-
}
|
|
16155
|
-
/**
|
|
16156
|
-
* Get the angle between two 3D vectors
|
|
16157
|
-
* @param {ReadonlyVec3} a The first operand
|
|
16158
|
-
* @param {ReadonlyVec3} b The second operand
|
|
16159
|
-
* @returns {Number} The angle in radians
|
|
16160
|
-
*/
|
|
16161
|
-
|
|
16162
|
-
function angle(a, b) {
|
|
16163
|
-
var ax = a[0],
|
|
16164
|
-
ay = a[1],
|
|
16165
|
-
az = a[2],
|
|
16166
|
-
bx = b[0],
|
|
16167
|
-
by = b[1],
|
|
16168
|
-
bz = b[2],
|
|
16169
|
-
mag1 = Math.sqrt(ax * ax + ay * ay + az * az),
|
|
16170
|
-
mag2 = Math.sqrt(bx * bx + by * by + bz * bz),
|
|
16171
|
-
mag = mag1 * mag2,
|
|
16172
|
-
cosine = mag && dot(a, b) / mag;
|
|
16173
|
-
return Math.acos(Math.min(Math.max(cosine, -1), 1));
|
|
16174
|
-
}
|
|
16175
|
-
/**
|
|
16176
|
-
* Set the components of a vec3 to zero
|
|
16177
|
-
*
|
|
16178
|
-
* @param {vec3} out the receiving vector
|
|
16179
|
-
* @returns {vec3} out
|
|
16180
|
-
*/
|
|
16181
|
-
|
|
16182
|
-
function zero(out) {
|
|
16183
|
-
out[0] = 0.0;
|
|
16184
|
-
out[1] = 0.0;
|
|
16185
|
-
out[2] = 0.0;
|
|
16186
|
-
return out;
|
|
16187
|
-
}
|
|
16188
|
-
/**
|
|
16189
|
-
* Returns a string representation of a vector
|
|
16190
|
-
*
|
|
16191
|
-
* @param {ReadonlyVec3} a vector to represent as a string
|
|
16192
|
-
* @returns {String} string representation of the vector
|
|
16193
|
-
*/
|
|
16194
|
-
|
|
16195
|
-
function str(a) {
|
|
16196
|
-
return "vec3(" + a[0] + ", " + a[1] + ", " + a[2] + ")";
|
|
16197
|
-
}
|
|
16198
|
-
/**
|
|
16199
|
-
* Returns whether or not the vectors have exactly the same elements in the same position (when compared with ===)
|
|
16200
|
-
*
|
|
16201
|
-
* @param {ReadonlyVec3} a The first vector.
|
|
16202
|
-
* @param {ReadonlyVec3} b The second vector.
|
|
16203
|
-
* @returns {Boolean} True if the vectors are equal, false otherwise.
|
|
16204
|
-
*/
|
|
16205
|
-
|
|
16206
|
-
function exactEquals(a, b) {
|
|
16207
|
-
return a[0] === b[0] && a[1] === b[1] && a[2] === b[2];
|
|
16208
|
-
}
|
|
16209
|
-
/**
|
|
16210
|
-
* Returns whether or not the vectors have approximately the same elements in the same position.
|
|
16211
|
-
*
|
|
16212
|
-
* @param {ReadonlyVec3} a The first vector.
|
|
16213
|
-
* @param {ReadonlyVec3} b The second vector.
|
|
16214
|
-
* @returns {Boolean} True if the vectors are equal, false otherwise.
|
|
16215
|
-
*/
|
|
16216
|
-
|
|
16217
|
-
function equals(a, b) {
|
|
16218
|
-
var a0 = a[0],
|
|
16219
|
-
a1 = a[1],
|
|
16220
|
-
a2 = a[2];
|
|
16221
|
-
var b0 = b[0],
|
|
16222
|
-
b1 = b[1],
|
|
16223
|
-
b2 = b[2];
|
|
16224
|
-
return Math.abs(a0 - b0) <= _common_js__WEBPACK_IMPORTED_MODULE_0__["EPSILON"] * Math.max(1.0, Math.abs(a0), Math.abs(b0)) && Math.abs(a1 - b1) <= _common_js__WEBPACK_IMPORTED_MODULE_0__["EPSILON"] * Math.max(1.0, Math.abs(a1), Math.abs(b1)) && Math.abs(a2 - b2) <= _common_js__WEBPACK_IMPORTED_MODULE_0__["EPSILON"] * Math.max(1.0, Math.abs(a2), Math.abs(b2));
|
|
16225
|
-
}
|
|
16226
|
-
/**
|
|
16227
|
-
* Alias for {@link vec3.subtract}
|
|
16228
|
-
* @function
|
|
16229
|
-
*/
|
|
16230
|
-
|
|
16231
|
-
var sub = subtract;
|
|
16232
|
-
/**
|
|
16233
|
-
* Alias for {@link vec3.multiply}
|
|
16234
|
-
* @function
|
|
16235
|
-
*/
|
|
16236
|
-
|
|
16237
|
-
var mul = multiply;
|
|
16238
|
-
/**
|
|
16239
|
-
* Alias for {@link vec3.divide}
|
|
16240
|
-
* @function
|
|
16241
|
-
*/
|
|
16242
|
-
|
|
16243
|
-
var div = divide;
|
|
16244
|
-
/**
|
|
16245
|
-
* Alias for {@link vec3.distance}
|
|
16246
|
-
* @function
|
|
16247
|
-
*/
|
|
16248
|
-
|
|
16249
|
-
var dist = distance;
|
|
16250
|
-
/**
|
|
16251
|
-
* Alias for {@link vec3.squaredDistance}
|
|
16252
|
-
* @function
|
|
16253
|
-
*/
|
|
16254
|
-
|
|
16255
|
-
var sqrDist = squaredDistance;
|
|
16256
|
-
/**
|
|
16257
|
-
* Alias for {@link vec3.length}
|
|
16258
|
-
* @function
|
|
16259
|
-
*/
|
|
16260
|
-
|
|
16261
|
-
var len = length;
|
|
16262
|
-
/**
|
|
16263
|
-
* Alias for {@link vec3.squaredLength}
|
|
16264
|
-
* @function
|
|
16265
|
-
*/
|
|
16266
|
-
|
|
16267
|
-
var sqrLen = squaredLength;
|
|
16268
|
-
/**
|
|
16269
|
-
* Perform some operation over an array of vec3s.
|
|
16270
|
-
*
|
|
16271
|
-
* @param {Array} a the array of vectors to iterate over
|
|
16272
|
-
* @param {Number} stride Number of elements between the start of each vec3. If 0 assumes tightly packed
|
|
16273
|
-
* @param {Number} offset Number of elements to skip at the beginning of the array
|
|
16274
|
-
* @param {Number} count Number of vec3s to iterate over. If 0 iterates over entire array
|
|
16275
|
-
* @param {Function} fn Function to call for each vector in the array
|
|
16276
|
-
* @param {Object} [arg] additional argument to pass to fn
|
|
16277
|
-
* @returns {Array} a
|
|
16278
|
-
* @function
|
|
16279
|
-
*/
|
|
16280
|
-
|
|
16281
|
-
var forEach = function () {
|
|
16282
|
-
var vec = create();
|
|
16283
|
-
return function (a, stride, offset, count, fn, arg) {
|
|
16284
|
-
var i, l;
|
|
16285
|
-
|
|
16286
|
-
if (!stride) {
|
|
16287
|
-
stride = 3;
|
|
16288
|
-
}
|
|
16289
|
-
|
|
16290
|
-
if (!offset) {
|
|
16291
|
-
offset = 0;
|
|
16292
|
-
}
|
|
16293
|
-
|
|
16294
|
-
if (count) {
|
|
16295
|
-
l = Math.min(count * stride + offset, a.length);
|
|
16296
|
-
} else {
|
|
16297
|
-
l = a.length;
|
|
16298
|
-
}
|
|
16299
|
-
|
|
16300
|
-
for (i = offset; i < l; i += stride) {
|
|
16301
|
-
vec[0] = a[i];
|
|
16302
|
-
vec[1] = a[i + 1];
|
|
16303
|
-
vec[2] = a[i + 2];
|
|
16304
|
-
fn(vec, vec, arg);
|
|
16305
|
-
a[i] = vec[0];
|
|
16306
|
-
a[i + 1] = vec[1];
|
|
16307
|
-
a[i + 2] = vec[2];
|
|
16308
|
-
}
|
|
16309
|
-
|
|
16310
|
-
return a;
|
|
16311
|
-
};
|
|
16312
|
-
}();
|
|
16313
|
-
|
|
16314
|
-
/***/ }),
|
|
16315
|
-
|
|
16316
|
-
/***/ "./bundle.ts":
|
|
16317
|
-
/*!*******************!*\
|
|
16318
|
-
!*** ./bundle.ts ***!
|
|
16319
|
-
\*******************/
|
|
16320
|
-
/*! no static exports found */
|
|
16321
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
16322
|
-
|
|
16323
|
-
const Extensions = __webpack_require__(/*! ./src */ "./src/index.ts");
|
|
16324
|
-
|
|
16325
|
-
const deck = globalThis.deck || {}; // Check if peer dependencies are included
|
|
16326
|
-
|
|
16327
|
-
if (!deck.Layer) {
|
|
16328
|
-
throw new Error('@deck.gl/core is not found');
|
|
16329
|
-
}
|
|
16330
|
-
|
|
16331
|
-
module.exports = Object.assign(deck, Extensions);
|
|
16332
|
-
|
|
16333
|
-
/***/ }),
|
|
16334
|
-
|
|
16335
|
-
/***/ "./src/brushing/brushing.js":
|
|
16336
|
-
/*!**********************************!*\
|
|
16337
|
-
!*** ./src/brushing/brushing.js ***!
|
|
16338
|
-
\**********************************/
|
|
16339
|
-
/*! exports provided: default */
|
|
16340
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
16341
|
-
|
|
16342
|
-
"use strict";
|
|
16343
|
-
__webpack_require__.r(__webpack_exports__);
|
|
16344
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return BrushingExtension; });
|
|
16345
|
-
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
16346
|
-
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_0__);
|
|
16347
|
-
/* harmony import */ var _shader_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shader-module */ "./src/brushing/shader-module.js");
|
|
16348
|
-
// Copyright (c) 2015 - 2017 Uber Technologies, Inc.
|
|
16349
|
-
//
|
|
16350
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
16351
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
16352
|
-
// in the Software without restriction, including without limitation the rights
|
|
16353
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
16354
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
16355
|
-
// furnished to do so, subject to the following conditions:
|
|
16356
|
-
//
|
|
16357
|
-
// The above copyright notice and this permission notice shall be included in
|
|
16358
|
-
// all copies or substantial portions of the Software.
|
|
16359
|
-
//
|
|
16360
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16361
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16362
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
16363
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
16364
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
16365
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
16366
|
-
// THE SOFTWARE.
|
|
16367
|
-
|
|
16368
|
-
|
|
16369
|
-
const defaultProps = {
|
|
16370
|
-
getBrushingTarget: {
|
|
16371
|
-
type: 'accessor',
|
|
16372
|
-
value: [0, 0]
|
|
16373
|
-
},
|
|
16374
|
-
brushingTarget: 'source',
|
|
16375
|
-
brushingEnabled: true,
|
|
16376
|
-
brushingRadius: 10000
|
|
16377
|
-
};
|
|
16378
|
-
class BrushingExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExtension"] {
|
|
16379
|
-
getShaders(extension) {
|
|
16380
|
-
return {
|
|
16381
|
-
modules: [_shader_module__WEBPACK_IMPORTED_MODULE_1__["default"]]
|
|
16382
|
-
};
|
|
16383
|
-
}
|
|
16384
|
-
|
|
16385
|
-
initializeState(context, extension) {
|
|
16386
|
-
const attributeManager = this.getAttributeManager();
|
|
16387
|
-
|
|
16388
|
-
if (attributeManager) {
|
|
16389
|
-
attributeManager.add({
|
|
16390
|
-
brushingTargets: {
|
|
16391
|
-
size: 2,
|
|
16392
|
-
accessor: 'getBrushingTarget',
|
|
16393
|
-
// Hack: extension's defaultProps is not merged with the layer's defaultProps,
|
|
16394
|
-
// So we can't use the standard accessor when the prop is undefined
|
|
16395
|
-
update: !this.props.getBrushingTarget && extension.useConstantTargetPositions,
|
|
16396
|
-
shaderAttributes: {
|
|
16397
|
-
brushingTargets: {
|
|
16398
|
-
divisor: 0
|
|
16399
|
-
},
|
|
16400
|
-
instanceBrushingTargets: {
|
|
16401
|
-
divisor: 1
|
|
16402
|
-
}
|
|
16403
|
-
}
|
|
16404
|
-
}
|
|
16405
|
-
});
|
|
16406
|
-
} // Trigger redraw when mouse moves
|
|
16407
|
-
// TODO - expose this in a better way
|
|
16408
|
-
|
|
16409
|
-
|
|
16410
|
-
extension.onMouseMove = () => {
|
|
16411
|
-
this.getCurrentLayer().setNeedsRedraw();
|
|
16412
|
-
};
|
|
16413
|
-
|
|
16414
|
-
if (this.context.deck) {
|
|
16415
|
-
this.context.deck.eventManager.on({
|
|
16416
|
-
pointermove: extension.onMouseMove,
|
|
16417
|
-
pointerleave: extension.onMouseMove
|
|
16418
|
-
});
|
|
16419
|
-
}
|
|
16420
|
-
}
|
|
16421
|
-
|
|
16422
|
-
finalizeState(extension) {
|
|
15513
|
+
finalizeState(context, extension) {
|
|
16423
15514
|
// Remove event listeners
|
|
16424
|
-
if (
|
|
16425
|
-
|
|
16426
|
-
|
|
16427
|
-
|
|
15515
|
+
if (context.deck) {
|
|
15516
|
+
// @ts-expect-error (2446) accessing protected property
|
|
15517
|
+
context.deck.eventManager.off({
|
|
15518
|
+
pointermove: this.state.onMouseMove,
|
|
15519
|
+
pointerleave: this.state.onMouseMove
|
|
16428
15520
|
});
|
|
16429
15521
|
}
|
|
16430
15522
|
}
|
|
@@ -16436,14 +15528,16 @@ class BrushingExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Laye
|
|
|
16436
15528
|
}
|
|
16437
15529
|
|
|
16438
15530
|
}
|
|
16439
|
-
|
|
16440
|
-
BrushingExtension
|
|
15531
|
+
|
|
15532
|
+
_defineProperty(BrushingExtension, "defaultProps", defaultProps);
|
|
15533
|
+
|
|
15534
|
+
_defineProperty(BrushingExtension, "extensionName", 'BrushingExtension');
|
|
16441
15535
|
|
|
16442
15536
|
/***/ }),
|
|
16443
15537
|
|
|
16444
|
-
/***/ "./src/brushing/shader-module.
|
|
15538
|
+
/***/ "./src/brushing/shader-module.ts":
|
|
16445
15539
|
/*!***************************************!*\
|
|
16446
|
-
!*** ./src/brushing/shader-module.
|
|
15540
|
+
!*** ./src/brushing/shader-module.ts ***!
|
|
16447
15541
|
\***************************************/
|
|
16448
15542
|
/*! exports provided: default */
|
|
16449
15543
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -16472,6 +15566,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
16472
15566
|
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
16473
15567
|
// THE SOFTWARE.
|
|
16474
15568
|
|
|
15569
|
+
/* eslint-disable camelcase */
|
|
15570
|
+
|
|
16475
15571
|
const vs = `
|
|
16476
15572
|
uniform bool brushing_enabled;
|
|
16477
15573
|
uniform int brushing_target;
|
|
@@ -16554,7 +15650,7 @@ const inject = {
|
|
|
16554
15650
|
fs,
|
|
16555
15651
|
inject,
|
|
16556
15652
|
getUniforms: opts => {
|
|
16557
|
-
if (!opts || !opts
|
|
15653
|
+
if (!opts || !('viewport' in opts)) {
|
|
16558
15654
|
return {};
|
|
16559
15655
|
}
|
|
16560
15656
|
|
|
@@ -16576,9 +15672,9 @@ const inject = {
|
|
|
16576
15672
|
|
|
16577
15673
|
/***/ }),
|
|
16578
15674
|
|
|
16579
|
-
/***/ "./src/clip/clip.
|
|
15675
|
+
/***/ "./src/clip/clip.ts":
|
|
16580
15676
|
/*!**************************!*\
|
|
16581
|
-
!*** ./src/clip/clip.
|
|
15677
|
+
!*** ./src/clip/clip.ts ***!
|
|
16582
15678
|
\**************************/
|
|
16583
15679
|
/*! exports provided: default */
|
|
16584
15680
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -16588,6 +15684,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
16588
15684
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return ClipExtension; });
|
|
16589
15685
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
16590
15686
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_0__);
|
|
15687
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
15688
|
+
|
|
16591
15689
|
// Copyright (c) 2015 - 2017 Uber Technologies, Inc.
|
|
16592
15690
|
//
|
|
16593
15691
|
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
@@ -16664,11 +15762,14 @@ varying vec2 clip_commonPosition;
|
|
|
16664
15762
|
if (!clip_isInBounds(clip_commonPosition)) discard;
|
|
16665
15763
|
`
|
|
16666
15764
|
};
|
|
15765
|
+
/** Adds support for clipping rendered layers by rectangular bounds. */
|
|
15766
|
+
|
|
16667
15767
|
class ClipExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExtension"] {
|
|
16668
15768
|
getShaders() {
|
|
16669
15769
|
// If `clipByInstance: true`, the entire object is shown/hidden based on its anchor position (done by vertex shader)
|
|
16670
15770
|
// Otherwise, the object is trimmed by the clip bounds (done by fragment shader)
|
|
16671
15771
|
// Default behavior: consider a layer instanced if it has attribute `instancePositions`
|
|
15772
|
+
// @ts-expect-error attributeManager is always defined for primitive layers
|
|
16672
15773
|
let clipByInstance = ('instancePositions' in this.getAttributeManager().attributes); // Users can override by setting the `clipByInstance` prop
|
|
16673
15774
|
|
|
16674
15775
|
if ('clipByInstance' in this.props) {
|
|
@@ -16684,6 +15785,8 @@ class ClipExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExt
|
|
|
16684
15785
|
inject: injectionFs
|
|
16685
15786
|
};
|
|
16686
15787
|
}
|
|
15788
|
+
/* eslint-disable camelcase */
|
|
15789
|
+
|
|
16687
15790
|
|
|
16688
15791
|
draw({
|
|
16689
15792
|
uniforms
|
|
@@ -16702,14 +15805,16 @@ class ClipExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExt
|
|
|
16702
15805
|
}
|
|
16703
15806
|
|
|
16704
15807
|
}
|
|
16705
|
-
|
|
16706
|
-
ClipExtension
|
|
15808
|
+
|
|
15809
|
+
_defineProperty(ClipExtension, "defaultProps", defaultProps);
|
|
15810
|
+
|
|
15811
|
+
_defineProperty(ClipExtension, "extensionName", 'ClipExtension');
|
|
16707
15812
|
|
|
16708
15813
|
/***/ }),
|
|
16709
15814
|
|
|
16710
|
-
/***/ "./src/data-filter/aggregator.
|
|
15815
|
+
/***/ "./src/data-filter/aggregator.ts":
|
|
16711
15816
|
/*!***************************************!*\
|
|
16712
|
-
!*** ./src/data-filter/aggregator.
|
|
15817
|
+
!*** ./src/data-filter/aggregator.ts ***!
|
|
16713
15818
|
\***************************************/
|
|
16714
15819
|
/*! exports provided: supportsFloatTarget, getFramebuffer, getModel, parameters */
|
|
16715
15820
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -16772,8 +15877,8 @@ void main() {
|
|
|
16772
15877
|
`;
|
|
16773
15878
|
function supportsFloatTarget(gl) {
|
|
16774
15879
|
// https://developer.mozilla.org/en-US/docs/Web/API/WebGL_API/WebGL_best_practices#Support_for_float_textures_doesnt_mean_you_can_render_into_them!
|
|
16775
|
-
return gl.getExtension('EXT_float_blend') && (gl.getExtension('EXT_color_buffer_float') || // WebGL 1
|
|
16776
|
-
gl.getExtension('WEBGL_color_buffer_float'));
|
|
15880
|
+
return Boolean(gl.getExtension('EXT_float_blend') && (gl.getExtension('EXT_color_buffer_float') || // WebGL 1
|
|
15881
|
+
gl.getExtension('WEBGL_color_buffer_float')));
|
|
16777
15882
|
} // A 1x1 framebuffer object that encodes the total count of filtered items
|
|
16778
15883
|
|
|
16779
15884
|
function getFramebuffer(gl, useFloatTarget) {
|
|
@@ -16824,9 +15929,9 @@ const parameters = {
|
|
|
16824
15929
|
|
|
16825
15930
|
/***/ }),
|
|
16826
15931
|
|
|
16827
|
-
/***/ "./src/data-filter/data-filter.
|
|
15932
|
+
/***/ "./src/data-filter/data-filter.ts":
|
|
16828
15933
|
/*!****************************************!*\
|
|
16829
|
-
!*** ./src/data-filter/data-filter.
|
|
15934
|
+
!*** ./src/data-filter/data-filter.ts ***!
|
|
16830
15935
|
\****************************************/
|
|
16831
15936
|
/*! exports provided: default */
|
|
16832
15937
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -16836,11 +15941,13 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
16836
15941
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return DataFilterExtension; });
|
|
16837
15942
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
16838
15943
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_0__);
|
|
16839
|
-
/* harmony import */ var _shader_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shader-module */ "./src/data-filter/shader-module.
|
|
16840
|
-
/* harmony import */ var _aggregator__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./aggregator */ "./src/data-filter/aggregator.
|
|
15944
|
+
/* harmony import */ var _shader_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shader-module */ "./src/data-filter/shader-module.ts");
|
|
15945
|
+
/* harmony import */ var _aggregator__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./aggregator */ "./src/data-filter/aggregator.ts");
|
|
16841
15946
|
/* harmony import */ var _luma_gl_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @luma.gl/core */ "@luma.gl/core");
|
|
16842
15947
|
/* harmony import */ var _luma_gl_core__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_luma_gl_core__WEBPACK_IMPORTED_MODULE_3__);
|
|
16843
15948
|
/* harmony import */ var _luma_gl_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @luma.gl/constants */ "../../node_modules/@luma.gl/constants/dist/esm/index.js");
|
|
15949
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
15950
|
+
|
|
16844
15951
|
// Copyright (c) 2015 - 2017 Uber Technologies, Inc.
|
|
16845
15952
|
//
|
|
16846
15953
|
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
@@ -16887,6 +15994,8 @@ const DATA_TYPE_FROM_SIZE = {
|
|
|
16887
15994
|
3: 'vec3',
|
|
16888
15995
|
4: 'vec4'
|
|
16889
15996
|
};
|
|
15997
|
+
/** Adds GPU-based data filtering functionalities to layers. It allows the layer to show/hide objects based on user-defined properties. */
|
|
15998
|
+
|
|
16890
15999
|
class DataFilterExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExtension"] {
|
|
16891
16000
|
constructor({
|
|
16892
16001
|
filterSize = 1,
|
|
@@ -16971,7 +16080,7 @@ class DataFilterExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["La
|
|
|
16971
16080
|
}
|
|
16972
16081
|
});
|
|
16973
16082
|
const filterFBO = _aggregator__WEBPACK_IMPORTED_MODULE_2__["getFramebuffer"](gl, useFloatTarget);
|
|
16974
|
-
const filterModel = _aggregator__WEBPACK_IMPORTED_MODULE_2__["getModel"](gl, extension.getShaders(extension), useFloatTarget);
|
|
16083
|
+
const filterModel = _aggregator__WEBPACK_IMPORTED_MODULE_2__["getModel"](gl, extension.getShaders.call(this, extension), useFloatTarget);
|
|
16975
16084
|
this.setState({
|
|
16976
16085
|
filterFBO,
|
|
16977
16086
|
filterModel
|
|
@@ -16985,7 +16094,8 @@ class DataFilterExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["La
|
|
|
16985
16094
|
}) {
|
|
16986
16095
|
if (this.state.filterModel) {
|
|
16987
16096
|
const attributeManager = this.getAttributeManager();
|
|
16988
|
-
const filterNeedsUpdate = attributeManager
|
|
16097
|
+
const filterNeedsUpdate = // attributeManager must be defined for filterModel to be set
|
|
16098
|
+
attributeManager.attributes.filterValues.needsUpdate() || props.filterEnabled !== oldProps.filterEnabled || props.filterRange !== oldProps.filterRange || props.filterSoftRange !== oldProps.filterSoftRange;
|
|
16989
16099
|
|
|
16990
16100
|
if (filterNeedsUpdate) {
|
|
16991
16101
|
this.setState({
|
|
@@ -17057,14 +16167,16 @@ class DataFilterExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["La
|
|
|
17057
16167
|
}
|
|
17058
16168
|
|
|
17059
16169
|
}
|
|
17060
|
-
|
|
17061
|
-
DataFilterExtension
|
|
16170
|
+
|
|
16171
|
+
_defineProperty(DataFilterExtension, "defaultProps", defaultProps);
|
|
16172
|
+
|
|
16173
|
+
_defineProperty(DataFilterExtension, "extensionName", 'DataFilterExtension');
|
|
17062
16174
|
|
|
17063
16175
|
/***/ }),
|
|
17064
16176
|
|
|
17065
|
-
/***/ "./src/data-filter/shader-module.
|
|
16177
|
+
/***/ "./src/data-filter/shader-module.ts":
|
|
17066
16178
|
/*!******************************************!*\
|
|
17067
|
-
!*** ./src/data-filter/shader-module.
|
|
16179
|
+
!*** ./src/data-filter/shader-module.ts ***!
|
|
17068
16180
|
\******************************************/
|
|
17069
16181
|
/*! exports provided: shaderModule, shaderModule64 */
|
|
17070
16182
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -17137,8 +16249,9 @@ uniform bool filter_transformColor;
|
|
|
17137
16249
|
varying float dataFilter_value;
|
|
17138
16250
|
`;
|
|
17139
16251
|
|
|
17140
|
-
|
|
17141
|
-
|
|
16252
|
+
/* eslint-disable camelcase */
|
|
16253
|
+
function getUniforms(opts) {
|
|
16254
|
+
if (!opts || !('extensions' in opts)) {
|
|
17142
16255
|
return {};
|
|
17143
16256
|
}
|
|
17144
16257
|
|
|
@@ -17149,26 +16262,26 @@ const getUniforms = opts => {
|
|
|
17149
16262
|
filterTransformColor = true
|
|
17150
16263
|
} = opts;
|
|
17151
16264
|
const filterSoftRange = opts.filterSoftRange || filterRange;
|
|
17152
|
-
|
|
17153
|
-
|
|
17154
|
-
|
|
17155
|
-
|
|
17156
|
-
|
|
17157
|
-
|
|
17158
|
-
|
|
17159
|
-
|
|
17160
|
-
|
|
17161
|
-
|
|
16265
|
+
return { ...(Number.isFinite(filterRange[0]) ? {
|
|
16266
|
+
filter_min: filterRange[0],
|
|
16267
|
+
filter_softMin: filterSoftRange[0],
|
|
16268
|
+
filter_softMax: filterSoftRange[1],
|
|
16269
|
+
filter_max: filterRange[1]
|
|
16270
|
+
} : {
|
|
16271
|
+
filter_min: filterRange.map(r => r[0]),
|
|
16272
|
+
filter_softMin: filterSoftRange.map(r => r[0]),
|
|
16273
|
+
filter_softMax: filterSoftRange.map(r => r[1]),
|
|
16274
|
+
filter_max: filterRange.map(r => r[1])
|
|
16275
|
+
}),
|
|
16276
|
+
filter_enabled: filterEnabled,
|
|
16277
|
+
filter_useSoftMargin: Boolean(opts.filterSoftRange),
|
|
16278
|
+
filter_transformSize: filterEnabled && filterTransformSize,
|
|
16279
|
+
filter_transformColor: filterEnabled && filterTransformColor
|
|
17162
16280
|
};
|
|
17163
|
-
|
|
17164
|
-
uniforms.filter_useSoftMargin = Boolean(opts.filterSoftRange);
|
|
17165
|
-
uniforms.filter_transformSize = filterEnabled && filterTransformSize;
|
|
17166
|
-
uniforms.filter_transformColor = filterEnabled && filterTransformColor;
|
|
17167
|
-
return uniforms;
|
|
17168
|
-
};
|
|
16281
|
+
}
|
|
17169
16282
|
|
|
17170
|
-
|
|
17171
|
-
if (!opts || !opts
|
|
16283
|
+
function getUniforms64(opts) {
|
|
16284
|
+
if (!opts || !('extensions' in opts)) {
|
|
17172
16285
|
return {};
|
|
17173
16286
|
}
|
|
17174
16287
|
|
|
@@ -17195,7 +16308,7 @@ const getUniforms64 = opts => {
|
|
|
17195
16308
|
}
|
|
17196
16309
|
|
|
17197
16310
|
return uniforms;
|
|
17198
|
-
}
|
|
16311
|
+
}
|
|
17199
16312
|
|
|
17200
16313
|
const inject = {
|
|
17201
16314
|
'vs:#main-start': `
|
|
@@ -17237,9 +16350,9 @@ const shaderModule64 = {
|
|
|
17237
16350
|
|
|
17238
16351
|
/***/ }),
|
|
17239
16352
|
|
|
17240
|
-
/***/ "./src/fill-style/fill-style.
|
|
16353
|
+
/***/ "./src/fill-style/fill-style.ts":
|
|
17241
16354
|
/*!**************************************!*\
|
|
17242
|
-
!*** ./src/fill-style/fill-style.
|
|
16355
|
+
!*** ./src/fill-style/fill-style.ts ***!
|
|
17243
16356
|
\**************************************/
|
|
17244
16357
|
/*! exports provided: default */
|
|
17245
16358
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -17252,7 +16365,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17252
16365
|
/* harmony import */ var _luma_gl_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @luma.gl/core */ "@luma.gl/core");
|
|
17253
16366
|
/* harmony import */ var _luma_gl_core__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_luma_gl_core__WEBPACK_IMPORTED_MODULE_1__);
|
|
17254
16367
|
/* harmony import */ var _luma_gl_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @luma.gl/constants */ "../../node_modules/@luma.gl/constants/dist/esm/index.js");
|
|
17255
|
-
/* harmony import */ var _shaders_glsl__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./shaders.glsl */ "./src/fill-style/shaders.glsl.
|
|
16368
|
+
/* harmony import */ var _shaders_glsl__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./shaders.glsl */ "./src/fill-style/shaders.glsl.ts");
|
|
16369
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
16370
|
+
|
|
17256
16371
|
|
|
17257
16372
|
|
|
17258
16373
|
|
|
@@ -17283,6 +16398,8 @@ const DEFAULT_TEXTURE_PARAMETERS = {
|
|
|
17283
16398
|
[_luma_gl_constants__WEBPACK_IMPORTED_MODULE_2__["default"].TEXTURE_WRAP_S]: _luma_gl_constants__WEBPACK_IMPORTED_MODULE_2__["default"].CLAMP_TO_EDGE,
|
|
17284
16399
|
[_luma_gl_constants__WEBPACK_IMPORTED_MODULE_2__["default"].TEXTURE_WRAP_T]: _luma_gl_constants__WEBPACK_IMPORTED_MODULE_2__["default"].CLAMP_TO_EDGE
|
|
17285
16400
|
};
|
|
16401
|
+
/** Adds selected features to layers that render a "fill", such as the `PolygonLayer` and `ScatterplotLayer`. */
|
|
16402
|
+
|
|
17286
16403
|
class FillStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExtension"] {
|
|
17287
16404
|
constructor({
|
|
17288
16405
|
pattern = false
|
|
@@ -17293,7 +16410,7 @@ class FillStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Lay
|
|
|
17293
16410
|
}
|
|
17294
16411
|
|
|
17295
16412
|
isEnabled(layer) {
|
|
17296
|
-
return layer.getAttributeManager() && !layer.state
|
|
16413
|
+
return layer.getAttributeManager() !== null && !('pathTesselator' in layer.state);
|
|
17297
16414
|
}
|
|
17298
16415
|
|
|
17299
16416
|
getShaders(extension) {
|
|
@@ -17374,11 +16491,11 @@ class FillStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Lay
|
|
|
17374
16491
|
}
|
|
17375
16492
|
|
|
17376
16493
|
if (props.fillPatternAtlas && props.fillPatternAtlas !== oldProps.fillPatternAtlas) {
|
|
17377
|
-
extension.loadPatternAtlas.call(this
|
|
16494
|
+
extension.loadPatternAtlas.call(this);
|
|
17378
16495
|
}
|
|
17379
16496
|
|
|
17380
16497
|
if (props.fillPatternMapping && props.fillPatternMapping !== oldProps.fillPatternMapping) {
|
|
17381
|
-
extension.loadPatternMapping.call(this
|
|
16498
|
+
extension.loadPatternMapping.call(this);
|
|
17382
16499
|
}
|
|
17383
16500
|
}
|
|
17384
16501
|
|
|
@@ -17404,10 +16521,11 @@ class FillStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Lay
|
|
|
17404
16521
|
emptyTexture?.delete();
|
|
17405
16522
|
}
|
|
17406
16523
|
|
|
17407
|
-
async loadPatternAtlas({
|
|
17408
|
-
|
|
17409
|
-
|
|
17410
|
-
|
|
16524
|
+
async loadPatternAtlas() {
|
|
16525
|
+
const {
|
|
16526
|
+
fillPatternAtlas,
|
|
16527
|
+
fetch
|
|
16528
|
+
} = this.props;
|
|
17411
16529
|
this.state.patternTexture?.delete();
|
|
17412
16530
|
this.setState({
|
|
17413
16531
|
patternTexture: null
|
|
@@ -17430,10 +16548,11 @@ class FillStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Lay
|
|
|
17430
16548
|
});
|
|
17431
16549
|
}
|
|
17432
16550
|
|
|
17433
|
-
async loadPatternMapping({
|
|
17434
|
-
|
|
17435
|
-
|
|
17436
|
-
|
|
16551
|
+
async loadPatternMapping() {
|
|
16552
|
+
const {
|
|
16553
|
+
fillPatternMapping,
|
|
16554
|
+
fetch
|
|
16555
|
+
} = this.props;
|
|
17437
16556
|
this.setState({
|
|
17438
16557
|
patternMapping: null
|
|
17439
16558
|
});
|
|
@@ -17462,14 +16581,16 @@ class FillStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Lay
|
|
|
17462
16581
|
}
|
|
17463
16582
|
|
|
17464
16583
|
}
|
|
17465
|
-
|
|
17466
|
-
FillStyleExtension
|
|
16584
|
+
|
|
16585
|
+
_defineProperty(FillStyleExtension, "defaultProps", defaultProps);
|
|
16586
|
+
|
|
16587
|
+
_defineProperty(FillStyleExtension, "extensionName", 'FillStyleExtension');
|
|
17467
16588
|
|
|
17468
16589
|
/***/ }),
|
|
17469
16590
|
|
|
17470
|
-
/***/ "./src/fill-style/shaders.glsl.
|
|
16591
|
+
/***/ "./src/fill-style/shaders.glsl.ts":
|
|
17471
16592
|
/*!****************************************!*\
|
|
17472
|
-
!*** ./src/fill-style/shaders.glsl.
|
|
16593
|
+
!*** ./src/fill-style/shaders.glsl.ts ***!
|
|
17473
16594
|
\****************************************/
|
|
17474
16595
|
/*! exports provided: patternShaders */
|
|
17475
16596
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -17480,10 +16601,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17480
16601
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
17481
16602
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_0__);
|
|
17482
16603
|
|
|
16604
|
+
|
|
17483
16605
|
/*
|
|
17484
16606
|
* fill pattern shader module
|
|
17485
16607
|
*/
|
|
17486
|
-
|
|
17487
16608
|
const patternVs = `
|
|
17488
16609
|
#ifdef NON_INSTANCED_MODEL
|
|
17489
16610
|
#define FILL_PATTERN_FRAME_ATTRIB fillPatternFrames
|
|
@@ -17546,7 +16667,12 @@ const inject = {
|
|
|
17546
16667
|
`
|
|
17547
16668
|
};
|
|
17548
16669
|
|
|
17549
|
-
|
|
16670
|
+
/* eslint-disable camelcase */
|
|
16671
|
+
function getPatternUniforms(opts, uniforms) {
|
|
16672
|
+
if (!opts) {
|
|
16673
|
+
return {};
|
|
16674
|
+
}
|
|
16675
|
+
|
|
17550
16676
|
if ('fillPatternTexture' in opts) {
|
|
17551
16677
|
const {
|
|
17552
16678
|
fillPatternTexture
|
|
@@ -17557,7 +16683,7 @@ function getPatternUniforms(opts = {}, uniforms) {
|
|
|
17557
16683
|
};
|
|
17558
16684
|
}
|
|
17559
16685
|
|
|
17560
|
-
if (opts
|
|
16686
|
+
if ('viewport' in opts) {
|
|
17561
16687
|
const {
|
|
17562
16688
|
viewport,
|
|
17563
16689
|
fillPatternMask = true,
|
|
@@ -17589,9 +16715,9 @@ const patternShaders = {
|
|
|
17589
16715
|
|
|
17590
16716
|
/***/ }),
|
|
17591
16717
|
|
|
17592
|
-
/***/ "./src/fp64/fp64.
|
|
16718
|
+
/***/ "./src/fp64/fp64.ts":
|
|
17593
16719
|
/*!**************************!*\
|
|
17594
|
-
!*** ./src/fp64/fp64.
|
|
16720
|
+
!*** ./src/fp64/fp64.ts ***!
|
|
17595
16721
|
\**************************/
|
|
17596
16722
|
/*! exports provided: default */
|
|
17597
16723
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -17601,7 +16727,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17601
16727
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return Fp64Extension; });
|
|
17602
16728
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
17603
16729
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_0__);
|
|
17604
|
-
/* harmony import */ var _project64__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./project64 */ "./src/fp64/project64.
|
|
16730
|
+
/* harmony import */ var _project64__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./project64 */ "./src/fp64/project64.ts");
|
|
16731
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
16732
|
+
|
|
17605
16733
|
// Copyright (c) 2015 - 2017 Uber Technologies, Inc.
|
|
17606
16734
|
//
|
|
17607
16735
|
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
@@ -17623,8 +16751,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17623
16751
|
// THE SOFTWARE.
|
|
17624
16752
|
|
|
17625
16753
|
|
|
16754
|
+
|
|
16755
|
+
/** @deprecated Adds the legacy 64-bit precision to geospatial layers. */
|
|
17626
16756
|
class Fp64Extension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExtension"] {
|
|
17627
|
-
getShaders(
|
|
16757
|
+
getShaders() {
|
|
17628
16758
|
const {
|
|
17629
16759
|
coordinateSystem
|
|
17630
16760
|
} = this.props;
|
|
@@ -17639,13 +16769,14 @@ class Fp64Extension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExt
|
|
|
17639
16769
|
}
|
|
17640
16770
|
|
|
17641
16771
|
}
|
|
17642
|
-
|
|
16772
|
+
|
|
16773
|
+
_defineProperty(Fp64Extension, "extensionName", 'Fp64Extension');
|
|
17643
16774
|
|
|
17644
16775
|
/***/ }),
|
|
17645
16776
|
|
|
17646
|
-
/***/ "./src/fp64/project64.glsl.
|
|
16777
|
+
/***/ "./src/fp64/project64.glsl.ts":
|
|
17647
16778
|
/*!************************************!*\
|
|
17648
|
-
!*** ./src/fp64/project64.glsl.
|
|
16779
|
+
!*** ./src/fp64/project64.glsl.ts ***!
|
|
17649
16780
|
\************************************/
|
|
17650
16781
|
/*! exports provided: default */
|
|
17651
16782
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -17755,9 +16886,9 @@ vec4 project_position_to_clipspace(
|
|
|
17755
16886
|
|
|
17756
16887
|
/***/ }),
|
|
17757
16888
|
|
|
17758
|
-
/***/ "./src/fp64/project64.
|
|
16889
|
+
/***/ "./src/fp64/project64.ts":
|
|
17759
16890
|
/*!*******************************!*\
|
|
17760
|
-
!*** ./src/fp64/project64.
|
|
16891
|
+
!*** ./src/fp64/project64.ts ***!
|
|
17761
16892
|
\*******************************/
|
|
17762
16893
|
/*! exports provided: default */
|
|
17763
16894
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -17767,7 +16898,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17767
16898
|
/* harmony import */ var _luma_gl_shadertools__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @luma.gl/shadertools */ "../../node_modules/@luma.gl/shadertools/dist/esm/index.js");
|
|
17768
16899
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
17769
16900
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_1__);
|
|
17770
|
-
/* harmony import */ var _project64_glsl__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./project64.glsl */ "./src/fp64/project64.glsl.
|
|
16901
|
+
/* harmony import */ var _project64_glsl__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./project64.glsl */ "./src/fp64/project64.glsl.ts");
|
|
17771
16902
|
// Copyright (c) 2015 - 2017 Uber Technologies, Inc.
|
|
17772
16903
|
//
|
|
17773
16904
|
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
@@ -17788,6 +16919,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17788
16919
|
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
17789
16920
|
// THE SOFTWARE.
|
|
17790
16921
|
|
|
16922
|
+
/* eslint-disable camelcase */
|
|
16923
|
+
|
|
17791
16924
|
const {
|
|
17792
16925
|
fp64ify,
|
|
17793
16926
|
fp64ifyMatrix4
|
|
@@ -17802,11 +16935,10 @@ const {
|
|
|
17802
16935
|
}); // TODO - this module should calculate the 64 bit uniforms
|
|
17803
16936
|
// It is currently done by project to minimize duplicated work
|
|
17804
16937
|
|
|
17805
|
-
const DEFAULT_MODULE_OPTIONS = {};
|
|
17806
16938
|
const getMemoizedUniforms = Object(_deck_gl_core__WEBPACK_IMPORTED_MODULE_1__["_memoize"])(calculateUniforms);
|
|
17807
16939
|
|
|
17808
|
-
function getUniforms(opts
|
|
17809
|
-
if (opts
|
|
16940
|
+
function getUniforms(opts) {
|
|
16941
|
+
if (opts && 'viewport' in opts) {
|
|
17810
16942
|
const {
|
|
17811
16943
|
viewProjectionMatrix,
|
|
17812
16944
|
scale
|
|
@@ -17845,28 +16977,28 @@ function calculateUniforms({
|
|
|
17845
16977
|
|
|
17846
16978
|
"use strict";
|
|
17847
16979
|
__webpack_require__.r(__webpack_exports__);
|
|
17848
|
-
/* harmony import */ var _brushing_brushing__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./brushing/brushing */ "./src/brushing/brushing.
|
|
16980
|
+
/* harmony import */ var _brushing_brushing__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./brushing/brushing */ "./src/brushing/brushing.ts");
|
|
17849
16981
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "BrushingExtension", function() { return _brushing_brushing__WEBPACK_IMPORTED_MODULE_0__["default"]; });
|
|
17850
16982
|
|
|
17851
|
-
/* harmony import */ var _data_filter_data_filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./data-filter/data-filter */ "./src/data-filter/data-filter.
|
|
16983
|
+
/* harmony import */ var _data_filter_data_filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./data-filter/data-filter */ "./src/data-filter/data-filter.ts");
|
|
17852
16984
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "DataFilterExtension", function() { return _data_filter_data_filter__WEBPACK_IMPORTED_MODULE_1__["default"]; });
|
|
17853
16985
|
|
|
17854
|
-
/* harmony import */ var _fp64_fp64__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./fp64/fp64 */ "./src/fp64/fp64.
|
|
16986
|
+
/* harmony import */ var _fp64_fp64__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./fp64/fp64 */ "./src/fp64/fp64.ts");
|
|
17855
16987
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "Fp64Extension", function() { return _fp64_fp64__WEBPACK_IMPORTED_MODULE_2__["default"]; });
|
|
17856
16988
|
|
|
17857
|
-
/* harmony import */ var _path_style_path_style__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./path-style/path-style */ "./src/path-style/path-style.
|
|
16989
|
+
/* harmony import */ var _path_style_path_style__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./path-style/path-style */ "./src/path-style/path-style.ts");
|
|
17858
16990
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "PathStyleExtension", function() { return _path_style_path_style__WEBPACK_IMPORTED_MODULE_3__["default"]; });
|
|
17859
16991
|
|
|
17860
|
-
/* harmony import */ var _fill_style_fill_style__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./fill-style/fill-style */ "./src/fill-style/fill-style.
|
|
16992
|
+
/* harmony import */ var _fill_style_fill_style__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./fill-style/fill-style */ "./src/fill-style/fill-style.ts");
|
|
17861
16993
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "FillStyleExtension", function() { return _fill_style_fill_style__WEBPACK_IMPORTED_MODULE_4__["default"]; });
|
|
17862
16994
|
|
|
17863
|
-
/* harmony import */ var _clip_clip__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./clip/clip */ "./src/clip/clip.
|
|
16995
|
+
/* harmony import */ var _clip_clip__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./clip/clip */ "./src/clip/clip.ts");
|
|
17864
16996
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "ClipExtension", function() { return _clip_clip__WEBPACK_IMPORTED_MODULE_5__["default"]; });
|
|
17865
16997
|
|
|
17866
|
-
/* harmony import */ var _mask_mask__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./mask/mask */ "./src/mask/mask.
|
|
16998
|
+
/* harmony import */ var _mask_mask__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./mask/mask */ "./src/mask/mask.ts");
|
|
17867
16999
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MaskExtension", function() { return _mask_mask__WEBPACK_IMPORTED_MODULE_6__["default"]; });
|
|
17868
17000
|
|
|
17869
|
-
/* harmony import */ var _fp64_project64__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./fp64/project64 */ "./src/fp64/project64.
|
|
17001
|
+
/* harmony import */ var _fp64_project64__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./fp64/project64 */ "./src/fp64/project64.ts");
|
|
17870
17002
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "project64", function() { return _fp64_project64__WEBPACK_IMPORTED_MODULE_7__["default"]; });
|
|
17871
17003
|
|
|
17872
17004
|
|
|
@@ -17877,13 +17009,13 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17877
17009
|
|
|
17878
17010
|
// Shader module
|
|
17879
17011
|
|
|
17880
|
-
|
|
17012
|
+
// Types
|
|
17881
17013
|
|
|
17882
17014
|
/***/ }),
|
|
17883
17015
|
|
|
17884
|
-
/***/ "./src/mask/mask.
|
|
17016
|
+
/***/ "./src/mask/mask.ts":
|
|
17885
17017
|
/*!**************************!*\
|
|
17886
|
-
!*** ./src/mask/mask.
|
|
17018
|
+
!*** ./src/mask/mask.ts ***!
|
|
17887
17019
|
\**************************/
|
|
17888
17020
|
/*! exports provided: default */
|
|
17889
17021
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -17893,19 +17025,23 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17893
17025
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return MaskExtension; });
|
|
17894
17026
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
17895
17027
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_0__);
|
|
17896
|
-
/* harmony import */ var _shader_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shader-module */ "./src/mask/shader-module.
|
|
17028
|
+
/* harmony import */ var _shader_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shader-module */ "./src/mask/shader-module.ts");
|
|
17029
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
17030
|
+
|
|
17897
17031
|
|
|
17898
17032
|
|
|
17899
17033
|
const defaultProps = {
|
|
17900
17034
|
maskId: ''
|
|
17901
17035
|
};
|
|
17036
|
+
|
|
17037
|
+
/** Allows layers to show/hide objects by a geofence. */
|
|
17902
17038
|
class MaskExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExtension"] {
|
|
17903
17039
|
getShaders() {
|
|
17904
17040
|
// Infer by geometry if 'maskByInstance' prop isn't explictly set
|
|
17905
17041
|
let maskByInstance = ('instancePositions' in this.getAttributeManager().attributes); // Users can override by setting the `maskByInstance` prop
|
|
17906
17042
|
|
|
17907
17043
|
if ('maskByInstance' in this.props) {
|
|
17908
|
-
maskByInstance = this.props.maskByInstance;
|
|
17044
|
+
maskByInstance = Boolean(this.props.maskByInstance);
|
|
17909
17045
|
}
|
|
17910
17046
|
|
|
17911
17047
|
this.state.maskByInstance = maskByInstance;
|
|
@@ -17913,6 +17049,8 @@ class MaskExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExt
|
|
|
17913
17049
|
modules: [_shader_module__WEBPACK_IMPORTED_MODULE_1__["default"]]
|
|
17914
17050
|
};
|
|
17915
17051
|
}
|
|
17052
|
+
/* eslint-disable camelcase */
|
|
17053
|
+
|
|
17916
17054
|
|
|
17917
17055
|
draw({
|
|
17918
17056
|
uniforms,
|
|
@@ -17921,7 +17059,7 @@ class MaskExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExt
|
|
|
17921
17059
|
}) {
|
|
17922
17060
|
uniforms.mask_maskByInstance = this.state.maskByInstance;
|
|
17923
17061
|
const {
|
|
17924
|
-
maskId
|
|
17062
|
+
maskId = ''
|
|
17925
17063
|
} = this.props;
|
|
17926
17064
|
const {
|
|
17927
17065
|
maskChannels
|
|
@@ -17964,14 +17102,16 @@ class MaskExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExt
|
|
|
17964
17102
|
}
|
|
17965
17103
|
|
|
17966
17104
|
}
|
|
17967
|
-
|
|
17968
|
-
MaskExtension
|
|
17105
|
+
|
|
17106
|
+
_defineProperty(MaskExtension, "defaultProps", defaultProps);
|
|
17107
|
+
|
|
17108
|
+
_defineProperty(MaskExtension, "extensionName", 'MaskExtension');
|
|
17969
17109
|
|
|
17970
17110
|
/***/ }),
|
|
17971
17111
|
|
|
17972
|
-
/***/ "./src/mask/shader-module.
|
|
17112
|
+
/***/ "./src/mask/shader-module.ts":
|
|
17973
17113
|
/*!***********************************!*\
|
|
17974
|
-
!*** ./src/mask/shader-module.
|
|
17114
|
+
!*** ./src/mask/shader-module.ts ***!
|
|
17975
17115
|
\***********************************/
|
|
17976
17116
|
/*! exports provided: default */
|
|
17977
17117
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -18039,14 +17179,15 @@ varying vec2 mask_texCoords;
|
|
|
18039
17179
|
`
|
|
18040
17180
|
};
|
|
18041
17181
|
|
|
18042
|
-
|
|
18043
|
-
|
|
18044
|
-
|
|
18045
|
-
|
|
18046
|
-
|
|
17182
|
+
/* eslint-disable camelcase */
|
|
17183
|
+
const getMaskUniforms = opts => {
|
|
17184
|
+
if (opts && 'maskMap' in opts) {
|
|
17185
|
+
return {
|
|
17186
|
+
mask_texture: opts.maskMap
|
|
17187
|
+
};
|
|
18047
17188
|
}
|
|
18048
17189
|
|
|
18049
|
-
return
|
|
17190
|
+
return {};
|
|
18050
17191
|
};
|
|
18051
17192
|
|
|
18052
17193
|
/* harmony default export */ __webpack_exports__["default"] = ({
|
|
@@ -18060,9 +17201,9 @@ const getMaskUniforms = (opts = {}) => {
|
|
|
18060
17201
|
|
|
18061
17202
|
/***/ }),
|
|
18062
17203
|
|
|
18063
|
-
/***/ "./src/path-style/path-style.
|
|
17204
|
+
/***/ "./src/path-style/path-style.ts":
|
|
18064
17205
|
/*!**************************************!*\
|
|
18065
|
-
!*** ./src/path-style/path-style.
|
|
17206
|
+
!*** ./src/path-style/path-style.ts ***!
|
|
18066
17207
|
\**************************************/
|
|
18067
17208
|
/*! exports provided: default */
|
|
18068
17209
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
@@ -18072,8 +17213,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
18072
17213
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return PathStyleExtension; });
|
|
18073
17214
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @deck.gl/core */ "@deck.gl/core");
|
|
18074
17215
|
/* harmony import */ var _deck_gl_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_deck_gl_core__WEBPACK_IMPORTED_MODULE_0__);
|
|
18075
|
-
/* harmony import */ var _shaders_glsl__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shaders.glsl */ "./src/path-style/shaders.glsl.
|
|
17216
|
+
/* harmony import */ var _shaders_glsl__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shaders.glsl */ "./src/path-style/shaders.glsl.ts");
|
|
18076
17217
|
/* harmony import */ var gl_matrix_vec3__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! gl-matrix/vec3 */ "../../node_modules/gl-matrix/esm/vec3.js");
|
|
17218
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
17219
|
+
|
|
18077
17220
|
// Copyright (c) 2015 - 2017 Uber Technologies, Inc.
|
|
18078
17221
|
//
|
|
18079
17222
|
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
@@ -18108,6 +17251,8 @@ const defaultProps = {
|
|
|
18108
17251
|
dashJustified: false,
|
|
18109
17252
|
dashGapPickable: false
|
|
18110
17253
|
};
|
|
17254
|
+
|
|
17255
|
+
/** Adds selected features to the `PathLayer` and composite layers that render the `PathLayer`. */
|
|
18111
17256
|
class PathStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["LayerExtension"] {
|
|
18112
17257
|
constructor({
|
|
18113
17258
|
dash = false,
|
|
@@ -18122,7 +17267,7 @@ class PathStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Lay
|
|
|
18122
17267
|
}
|
|
18123
17268
|
|
|
18124
17269
|
isEnabled(layer) {
|
|
18125
|
-
return layer.state
|
|
17270
|
+
return 'pathTesselator' in layer.state;
|
|
18126
17271
|
}
|
|
18127
17272
|
|
|
18128
17273
|
getShaders(extension) {
|
|
@@ -18152,8 +17297,6 @@ class PathStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Lay
|
|
|
18152
17297
|
return;
|
|
18153
17298
|
}
|
|
18154
17299
|
|
|
18155
|
-
extension.enabled = true;
|
|
18156
|
-
|
|
18157
17300
|
if (extension.opts.dash) {
|
|
18158
17301
|
attributeManager.addInstanced({
|
|
18159
17302
|
instanceDashArrays: {
|
|
@@ -18221,14 +17364,16 @@ class PathStyleExtension extends _deck_gl_core__WEBPACK_IMPORTED_MODULE_0__["Lay
|
|
|
18221
17364
|
}
|
|
18222
17365
|
|
|
18223
17366
|
}
|
|
18224
|
-
|
|
18225
|
-
PathStyleExtension
|
|
17367
|
+
|
|
17368
|
+
_defineProperty(PathStyleExtension, "defaultProps", defaultProps);
|
|
17369
|
+
|
|
17370
|
+
_defineProperty(PathStyleExtension, "extensionName", 'PathStyleExtension');
|
|
18226
17371
|
|
|
18227
17372
|
/***/ }),
|
|
18228
17373
|
|
|
18229
|
-
/***/ "./src/path-style/shaders.glsl.
|
|
17374
|
+
/***/ "./src/path-style/shaders.glsl.ts":
|
|
18230
17375
|
/*!****************************************!*\
|
|
18231
|
-
!*** ./src/path-style/shaders.glsl.
|
|
17376
|
+
!*** ./src/path-style/shaders.glsl.ts ***!
|
|
18232
17377
|
\****************************************/
|
|
18233
17378
|
/*! exports provided: dashShaders, offsetShaders */
|
|
18234
17379
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|