@navaramap/engine-api 0.2.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/navara_wasm_api.d.ts +1612 -441
- package/navara_wasm_api.js +2292 -382
- package/navara_wasm_api_bg.wasm +0 -0
- package/package.json +1 -1
package/navara_wasm_api.js
CHANGED
|
@@ -145,10 +145,25 @@ export class BillboardMaterial {
|
|
|
145
145
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
146
146
|
}
|
|
147
147
|
/**
|
|
148
|
-
*
|
|
149
|
-
*
|
|
150
|
-
*
|
|
151
|
-
*
|
|
148
|
+
* Part of the quad placed at the anchor point: `"center"` (default),
|
|
149
|
+
* `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`, `"top-right"`,
|
|
150
|
+
* `"bottom-left"` or `"bottom-right"`, as MapLibre's `icon-anchor`.
|
|
151
|
+
* @returns {string | undefined}
|
|
152
|
+
*/
|
|
153
|
+
get anchor() {
|
|
154
|
+
const ret = wasm.__wbg_get_billboardmaterial_anchor(this.__wbg_ptr);
|
|
155
|
+
let v1;
|
|
156
|
+
if (ret[0] !== 0) {
|
|
157
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
158
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
159
|
+
}
|
|
160
|
+
return v1;
|
|
161
|
+
}
|
|
162
|
+
/**
|
|
163
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
164
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
165
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
166
|
+
* camera.
|
|
152
167
|
* @returns {boolean | undefined}
|
|
153
168
|
*/
|
|
154
169
|
get backfaceCulling() {
|
|
@@ -156,9 +171,12 @@ export class BillboardMaterial {
|
|
|
156
171
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
157
172
|
}
|
|
158
173
|
/**
|
|
159
|
-
*
|
|
160
|
-
* globe surface around its anchor (`"flat"`)
|
|
161
|
-
* `
|
|
174
|
+
* Plane the sprite lies in: the screen (`"upright"`, never foreshortened)
|
|
175
|
+
* or the globe surface around its anchor (`"flat"`), as MapLibre's
|
|
176
|
+
* `icon-pitch-alignment` `viewport` and `map`. Pair with
|
|
177
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
178
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
179
|
+
* `auto`.
|
|
162
180
|
* @returns {string | undefined}
|
|
163
181
|
*/
|
|
164
182
|
get billboardFacing() {
|
|
@@ -170,15 +188,6 @@ export class BillboardMaterial {
|
|
|
170
188
|
}
|
|
171
189
|
return v1;
|
|
172
190
|
}
|
|
173
|
-
/**
|
|
174
|
-
* anchor point of the sprite, range is (-0.5, -0.5) to (0.5, 0.5).
|
|
175
|
-
* Default is (0.0, 0.0) which means the center of the sprite.
|
|
176
|
-
* @returns {Vec2 | undefined}
|
|
177
|
-
*/
|
|
178
|
-
get center() {
|
|
179
|
-
const ret = wasm.__wbg_get_billboardmaterial_center(this.__wbg_ptr);
|
|
180
|
-
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
181
|
-
}
|
|
182
191
|
/**
|
|
183
192
|
* @returns {boolean | undefined}
|
|
184
193
|
*/
|
|
@@ -193,6 +202,21 @@ export class BillboardMaterial {
|
|
|
193
202
|
const ret = wasm.__wbg_get_billboardmaterial_color(this.__wbg_ptr);
|
|
194
203
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
195
204
|
}
|
|
205
|
+
/**
|
|
206
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
207
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
208
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
209
|
+
* @returns {Float32Array | undefined}
|
|
210
|
+
*/
|
|
211
|
+
get declutterPadding() {
|
|
212
|
+
const ret = wasm.__wbg_get_billboardmaterial_declutterPadding(this.__wbg_ptr);
|
|
213
|
+
let v1;
|
|
214
|
+
if (ret[0] !== 0) {
|
|
215
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
216
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
217
|
+
}
|
|
218
|
+
return v1;
|
|
219
|
+
}
|
|
196
220
|
/**
|
|
197
221
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
198
222
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -202,6 +226,17 @@ export class BillboardMaterial {
|
|
|
202
226
|
const ret = wasm.__wbg_get_billboardmaterial_declutterPriority(this.__wbg_ptr);
|
|
203
227
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
204
228
|
}
|
|
229
|
+
/**
|
|
230
|
+
* Coarse placement order for decluttering, compared before
|
|
231
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
232
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
233
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
234
|
+
* @returns {number | undefined}
|
|
235
|
+
*/
|
|
236
|
+
get declutterRank() {
|
|
237
|
+
const ret = wasm.__wbg_get_billboardmaterial_declutterRank(this.__wbg_ptr);
|
|
238
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
239
|
+
}
|
|
205
240
|
/**
|
|
206
241
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
207
242
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -250,8 +285,9 @@ export class BillboardMaterial {
|
|
|
250
285
|
}
|
|
251
286
|
/**
|
|
252
287
|
* Source geometry types this appearance consumes: `"point"`, `"line"`,
|
|
253
|
-
* `"polygon"`. Defaults to `["point"]`; adding `"line"
|
|
254
|
-
*
|
|
288
|
+
* `"polygon"`. Defaults to `["point"]`; adding `"line"` also emits a
|
|
289
|
+
* billboard per line string, at its first vertex, and `"polygon"` one per
|
|
290
|
+
* polygon.
|
|
255
291
|
* @returns {string[] | undefined}
|
|
256
292
|
*/
|
|
257
293
|
get geometryTypes() {
|
|
@@ -270,6 +306,16 @@ export class BillboardMaterial {
|
|
|
270
306
|
const ret = wasm.__wbg_get_billboardmaterial_height(this.__wbg_ptr);
|
|
271
307
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
272
308
|
}
|
|
309
|
+
/**
|
|
310
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
311
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
312
|
+
* Defaults to `false`.
|
|
313
|
+
* @returns {boolean | undefined}
|
|
314
|
+
*/
|
|
315
|
+
get ignorePlacement() {
|
|
316
|
+
const ret = wasm.__wbg_get_billboardmaterial_ignorePlacement(this.__wbg_ptr);
|
|
317
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
318
|
+
}
|
|
273
319
|
/**
|
|
274
320
|
* Avoid overlapping with the globe surface.
|
|
275
321
|
* @returns {boolean | undefined}
|
|
@@ -278,6 +324,16 @@ export class BillboardMaterial {
|
|
|
278
324
|
const ret = wasm.__wbg_get_billboardmaterial_offsetDepth(this.__wbg_ptr);
|
|
279
325
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
280
326
|
}
|
|
327
|
+
/**
|
|
328
|
+
* Shift from the anchor point, x right and y down, in the unit of `size`
|
|
329
|
+
* (meters when `sizeInMeters`, pixels otherwise). Lies in the quad's own
|
|
330
|
+
* plane, so it turns with `rotation`. Defaults to `(0, 0)`.
|
|
331
|
+
* @returns {Vec2 | undefined}
|
|
332
|
+
*/
|
|
333
|
+
get offset() {
|
|
334
|
+
const ret = wasm.__wbg_get_billboardmaterial_offset(this.__wbg_ptr);
|
|
335
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
336
|
+
}
|
|
281
337
|
/**
|
|
282
338
|
* @returns {number | undefined}
|
|
283
339
|
*/
|
|
@@ -286,9 +342,56 @@ export class BillboardMaterial {
|
|
|
286
342
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
287
343
|
}
|
|
288
344
|
/**
|
|
289
|
-
* Whether the
|
|
290
|
-
*
|
|
291
|
-
*
|
|
345
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
346
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
347
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
348
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
349
|
+
* @returns {string | undefined}
|
|
350
|
+
*/
|
|
351
|
+
get overlap() {
|
|
352
|
+
const ret = wasm.__wbg_get_billboardmaterial_overlap(this.__wbg_ptr);
|
|
353
|
+
let v1;
|
|
354
|
+
if (ret[0] !== 0) {
|
|
355
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
356
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
357
|
+
}
|
|
358
|
+
return v1;
|
|
359
|
+
}
|
|
360
|
+
/**
|
|
361
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
362
|
+
* default) puts one per line string, at its first vertex, and one per
|
|
363
|
+
* polygon, `"line"` repeats them along the line every `spacing`,
|
|
364
|
+
* `"line-center"` places a single one at the line's midpoint. Polygon
|
|
365
|
+
* rings are walked like lines. Requires `geometryTypes` to include
|
|
366
|
+
* `"line"` or `"polygon"`.
|
|
367
|
+
* @returns {string | undefined}
|
|
368
|
+
*/
|
|
369
|
+
get placement() {
|
|
370
|
+
const ret = wasm.__wbg_get_billboardmaterial_placement(this.__wbg_ptr);
|
|
371
|
+
let v1;
|
|
372
|
+
if (ret[0] !== 0) {
|
|
373
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
374
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
375
|
+
}
|
|
376
|
+
return v1;
|
|
377
|
+
}
|
|
378
|
+
/**
|
|
379
|
+
* Add the line's tangent bearing at the anchor to `rotation`, so the
|
|
380
|
+
* sprite turns with the line it sits on. Defaults to `true`.
|
|
381
|
+
* @returns {boolean | undefined}
|
|
382
|
+
*/
|
|
383
|
+
get rotateToLine() {
|
|
384
|
+
const ret = wasm.__wbg_get_billboardmaterial_rotateToLine(this.__wbg_ptr);
|
|
385
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
386
|
+
}
|
|
387
|
+
/**
|
|
388
|
+
* Whether the sprite turns with the camera or with the map, as MapLibre's
|
|
389
|
+
* `icon-rotation-alignment` `viewport` and `map`. `true` keeps it reading left to right
|
|
390
|
+
* (a screen-aligned billboard, or a flat quad yawed to the camera).
|
|
391
|
+
* `false` aligns it with the map: upright, it stays on screen but turns
|
|
392
|
+
* with the camera heading so its x-axis points east; flat, it lies
|
|
393
|
+
* north-up. Left unset, it is `true` for `placement: "point"` and `false`
|
|
394
|
+
* along a line, as MapLibre resolves `auto`.
|
|
292
395
|
* @returns {boolean | undefined}
|
|
293
396
|
*/
|
|
294
397
|
get rotateWithCamera() {
|
|
@@ -297,7 +400,7 @@ export class BillboardMaterial {
|
|
|
297
400
|
}
|
|
298
401
|
/**
|
|
299
402
|
* Rotation of the sprite within its own plane, about its anchor point,
|
|
300
|
-
* in degrees, clockwise seen from the front. `
|
|
403
|
+
* in degrees, clockwise seen from the front. `anchor` decides where
|
|
301
404
|
* inside the sprite the pivot sits. Defaults to `0.0`.
|
|
302
405
|
* @returns {number | undefined}
|
|
303
406
|
*/
|
|
@@ -320,6 +423,17 @@ export class BillboardMaterial {
|
|
|
320
423
|
const ret = wasm.__wbg_get_billboardmaterial_sizeInMeters(this.__wbg_ptr);
|
|
321
424
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
322
425
|
}
|
|
426
|
+
/**
|
|
427
|
+
* Whether `size` scales the image's own pixel height instead of being the
|
|
428
|
+
* quad's height, like MapLibre's `icon-size`: `1` draws the image at its
|
|
429
|
+
* natural size. `offset` keeps the unit `sizeInMeters` gives it. Default
|
|
430
|
+
* is false.
|
|
431
|
+
* @returns {boolean | undefined}
|
|
432
|
+
*/
|
|
433
|
+
get sizeRelativeToImage() {
|
|
434
|
+
const ret = wasm.__wbg_get_billboardmaterial_sizeRelativeToImage(this.__wbg_ptr);
|
|
435
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
436
|
+
}
|
|
323
437
|
/**
|
|
324
438
|
* size in pixels/meters (units are determined by `sizeInMeters`).
|
|
325
439
|
* @returns {number | undefined}
|
|
@@ -328,6 +442,59 @@ export class BillboardMaterial {
|
|
|
328
442
|
const ret = wasm.__wbg_get_billboardmaterial_size(this.__wbg_ptr);
|
|
329
443
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
330
444
|
}
|
|
445
|
+
/**
|
|
446
|
+
* Distance between repeated anchors along a line, in screen pixels, for
|
|
447
|
+
* `vector-tile` and `geojson` sources alike. Resolved per anchor as the
|
|
448
|
+
* camera moves: anchors thin out as it pulls back and fill in as it
|
|
449
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
450
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
451
|
+
* `symbol-spacing`, a sprite wider than three quarters of the spacing
|
|
452
|
+
* spreads its repeats to its width plus a quarter of the spacing, and a
|
|
453
|
+
* vector tile places anchors only inside its own bounds. Only used by
|
|
454
|
+
* `placement: "line"`. Defaults to `250.0`.
|
|
455
|
+
* @returns {number | undefined}
|
|
456
|
+
*/
|
|
457
|
+
get spacing() {
|
|
458
|
+
const ret = wasm.__wbg_get_billboardmaterial_spacing(this.__wbg_ptr);
|
|
459
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
460
|
+
}
|
|
461
|
+
/**
|
|
462
|
+
* Whether this may show while its partner at the same anchor (the
|
|
463
|
+
* layer's label for a billboard, its billboard for a label) is hidden.
|
|
464
|
+
* With `false` on both, the two are placed together: both show or
|
|
465
|
+
* neither does. Only meaningful when `declutter` is enabled. Defaults to
|
|
466
|
+
* `true`.
|
|
467
|
+
* @returns {boolean | undefined}
|
|
468
|
+
*/
|
|
469
|
+
get standalone() {
|
|
470
|
+
const ret = wasm.__wbg_get_billboardmaterial_standalone(this.__wbg_ptr);
|
|
471
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
472
|
+
}
|
|
473
|
+
/**
|
|
474
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
475
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
476
|
+
* the screen axes. MapLibre's `icon-translate-anchor`.
|
|
477
|
+
* @returns {string | undefined}
|
|
478
|
+
*/
|
|
479
|
+
get translateAnchor() {
|
|
480
|
+
const ret = wasm.__wbg_get_billboardmaterial_translateAnchor(this.__wbg_ptr);
|
|
481
|
+
let v1;
|
|
482
|
+
if (ret[0] !== 0) {
|
|
483
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
484
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
485
|
+
}
|
|
486
|
+
return v1;
|
|
487
|
+
}
|
|
488
|
+
/**
|
|
489
|
+
* Screen-pixel shift of the drawn quad, x right and y down, applied after
|
|
490
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
491
|
+
* MapLibre's `icon-translate`. Defaults to `(0, 0)`.
|
|
492
|
+
* @returns {Vec2 | undefined}
|
|
493
|
+
*/
|
|
494
|
+
get translate() {
|
|
495
|
+
const ret = wasm.__wbg_get_billboardmaterial_translate(this.__wbg_ptr);
|
|
496
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
497
|
+
}
|
|
331
498
|
/**
|
|
332
499
|
* @returns {boolean | undefined}
|
|
333
500
|
*/
|
|
@@ -354,19 +521,33 @@ export class BillboardMaterial {
|
|
|
354
521
|
wasm.__wbg_set_billboardmaterial_alphaTest(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
355
522
|
}
|
|
356
523
|
/**
|
|
357
|
-
*
|
|
358
|
-
*
|
|
359
|
-
*
|
|
360
|
-
*
|
|
524
|
+
* Part of the quad placed at the anchor point: `"center"` (default),
|
|
525
|
+
* `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`, `"top-right"`,
|
|
526
|
+
* `"bottom-left"` or `"bottom-right"`, as MapLibre's `icon-anchor`.
|
|
527
|
+
* @param {string | null} [arg0]
|
|
528
|
+
*/
|
|
529
|
+
set anchor(arg0) {
|
|
530
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
531
|
+
var len0 = WASM_VECTOR_LEN;
|
|
532
|
+
wasm.__wbg_set_billboardmaterial_anchor(this.__wbg_ptr, ptr0, len0);
|
|
533
|
+
}
|
|
534
|
+
/**
|
|
535
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
536
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
537
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
538
|
+
* camera.
|
|
361
539
|
* @param {boolean | null} [arg0]
|
|
362
540
|
*/
|
|
363
541
|
set backfaceCulling(arg0) {
|
|
364
542
|
wasm.__wbg_set_billboardmaterial_backfaceCulling(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
365
543
|
}
|
|
366
544
|
/**
|
|
367
|
-
*
|
|
368
|
-
* globe surface around its anchor (`"flat"`)
|
|
369
|
-
* `
|
|
545
|
+
* Plane the sprite lies in: the screen (`"upright"`, never foreshortened)
|
|
546
|
+
* or the globe surface around its anchor (`"flat"`), as MapLibre's
|
|
547
|
+
* `icon-pitch-alignment` `viewport` and `map`. Pair with
|
|
548
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
549
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
550
|
+
* `auto`.
|
|
370
551
|
* @param {string | null} [arg0]
|
|
371
552
|
*/
|
|
372
553
|
set billboardFacing(arg0) {
|
|
@@ -374,19 +555,6 @@ export class BillboardMaterial {
|
|
|
374
555
|
var len0 = WASM_VECTOR_LEN;
|
|
375
556
|
wasm.__wbg_set_billboardmaterial_billboardFacing(this.__wbg_ptr, ptr0, len0);
|
|
376
557
|
}
|
|
377
|
-
/**
|
|
378
|
-
* anchor point of the sprite, range is (-0.5, -0.5) to (0.5, 0.5).
|
|
379
|
-
* Default is (0.0, 0.0) which means the center of the sprite.
|
|
380
|
-
* @param {Vec2 | null} [arg0]
|
|
381
|
-
*/
|
|
382
|
-
set center(arg0) {
|
|
383
|
-
let ptr0 = 0;
|
|
384
|
-
if (!isLikeNone(arg0)) {
|
|
385
|
-
_assertClass(arg0, Vec2);
|
|
386
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
387
|
-
}
|
|
388
|
-
wasm.__wbg_set_billboardmaterial_center(this.__wbg_ptr, ptr0);
|
|
389
|
-
}
|
|
390
558
|
/**
|
|
391
559
|
* @param {boolean | null} [arg0]
|
|
392
560
|
*/
|
|
@@ -399,6 +567,17 @@ export class BillboardMaterial {
|
|
|
399
567
|
set color(arg0) {
|
|
400
568
|
wasm.__wbg_set_billboardmaterial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
401
569
|
}
|
|
570
|
+
/**
|
|
571
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
572
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
573
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
574
|
+
* @param {Float32Array | null} [arg0]
|
|
575
|
+
*/
|
|
576
|
+
set declutterPadding(arg0) {
|
|
577
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
578
|
+
var len0 = WASM_VECTOR_LEN;
|
|
579
|
+
wasm.__wbg_set_billboardmaterial_declutterPadding(this.__wbg_ptr, ptr0, len0);
|
|
580
|
+
}
|
|
402
581
|
/**
|
|
403
582
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
404
583
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -407,6 +586,16 @@ export class BillboardMaterial {
|
|
|
407
586
|
set declutterPriority(arg0) {
|
|
408
587
|
wasm.__wbg_set_billboardmaterial_declutterPriority(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
409
588
|
}
|
|
589
|
+
/**
|
|
590
|
+
* Coarse placement order for decluttering, compared before
|
|
591
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
592
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
593
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
594
|
+
* @param {number | null} [arg0]
|
|
595
|
+
*/
|
|
596
|
+
set declutterRank(arg0) {
|
|
597
|
+
wasm.__wbg_set_billboardmaterial_declutterRank(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
598
|
+
}
|
|
410
599
|
/**
|
|
411
600
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
412
601
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -447,8 +636,9 @@ export class BillboardMaterial {
|
|
|
447
636
|
}
|
|
448
637
|
/**
|
|
449
638
|
* Source geometry types this appearance consumes: `"point"`, `"line"`,
|
|
450
|
-
* `"polygon"`. Defaults to `["point"]`; adding `"line"
|
|
451
|
-
*
|
|
639
|
+
* `"polygon"`. Defaults to `["point"]`; adding `"line"` also emits a
|
|
640
|
+
* billboard per line string, at its first vertex, and `"polygon"` one per
|
|
641
|
+
* polygon.
|
|
452
642
|
* @param {string[] | null} [arg0]
|
|
453
643
|
*/
|
|
454
644
|
set geometryTypes(arg0) {
|
|
@@ -462,6 +652,15 @@ export class BillboardMaterial {
|
|
|
462
652
|
set height(arg0) {
|
|
463
653
|
wasm.__wbg_set_billboardmaterial_height(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
464
654
|
}
|
|
655
|
+
/**
|
|
656
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
657
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
658
|
+
* Defaults to `false`.
|
|
659
|
+
* @param {boolean | null} [arg0]
|
|
660
|
+
*/
|
|
661
|
+
set ignorePlacement(arg0) {
|
|
662
|
+
wasm.__wbg_set_billboardmaterial_ignorePlacement(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
663
|
+
}
|
|
465
664
|
/**
|
|
466
665
|
* Avoid overlapping with the globe surface.
|
|
467
666
|
* @param {boolean | null} [arg0]
|
|
@@ -469,6 +668,20 @@ export class BillboardMaterial {
|
|
|
469
668
|
set offsetDepth(arg0) {
|
|
470
669
|
wasm.__wbg_set_billboardmaterial_offsetDepth(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
471
670
|
}
|
|
671
|
+
/**
|
|
672
|
+
* Shift from the anchor point, x right and y down, in the unit of `size`
|
|
673
|
+
* (meters when `sizeInMeters`, pixels otherwise). Lies in the quad's own
|
|
674
|
+
* plane, so it turns with `rotation`. Defaults to `(0, 0)`.
|
|
675
|
+
* @param {Vec2 | null} [arg0]
|
|
676
|
+
*/
|
|
677
|
+
set offset(arg0) {
|
|
678
|
+
let ptr0 = 0;
|
|
679
|
+
if (!isLikeNone(arg0)) {
|
|
680
|
+
_assertClass(arg0, Vec2);
|
|
681
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
682
|
+
}
|
|
683
|
+
wasm.__wbg_set_billboardmaterial_offset(this.__wbg_ptr, ptr0);
|
|
684
|
+
}
|
|
472
685
|
/**
|
|
473
686
|
* @param {number | null} [arg0]
|
|
474
687
|
*/
|
|
@@ -476,9 +689,47 @@ export class BillboardMaterial {
|
|
|
476
689
|
wasm.__wbg_set_billboardmaterial_opacity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
477
690
|
}
|
|
478
691
|
/**
|
|
479
|
-
* Whether the
|
|
480
|
-
*
|
|
481
|
-
*
|
|
692
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
693
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
694
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
695
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
696
|
+
* @param {string | null} [arg0]
|
|
697
|
+
*/
|
|
698
|
+
set overlap(arg0) {
|
|
699
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
700
|
+
var len0 = WASM_VECTOR_LEN;
|
|
701
|
+
wasm.__wbg_set_billboardmaterial_overlap(this.__wbg_ptr, ptr0, len0);
|
|
702
|
+
}
|
|
703
|
+
/**
|
|
704
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
705
|
+
* default) puts one per line string, at its first vertex, and one per
|
|
706
|
+
* polygon, `"line"` repeats them along the line every `spacing`,
|
|
707
|
+
* `"line-center"` places a single one at the line's midpoint. Polygon
|
|
708
|
+
* rings are walked like lines. Requires `geometryTypes` to include
|
|
709
|
+
* `"line"` or `"polygon"`.
|
|
710
|
+
* @param {string | null} [arg0]
|
|
711
|
+
*/
|
|
712
|
+
set placement(arg0) {
|
|
713
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
714
|
+
var len0 = WASM_VECTOR_LEN;
|
|
715
|
+
wasm.__wbg_set_billboardmaterial_placement(this.__wbg_ptr, ptr0, len0);
|
|
716
|
+
}
|
|
717
|
+
/**
|
|
718
|
+
* Add the line's tangent bearing at the anchor to `rotation`, so the
|
|
719
|
+
* sprite turns with the line it sits on. Defaults to `true`.
|
|
720
|
+
* @param {boolean | null} [arg0]
|
|
721
|
+
*/
|
|
722
|
+
set rotateToLine(arg0) {
|
|
723
|
+
wasm.__wbg_set_billboardmaterial_rotateToLine(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
724
|
+
}
|
|
725
|
+
/**
|
|
726
|
+
* Whether the sprite turns with the camera or with the map, as MapLibre's
|
|
727
|
+
* `icon-rotation-alignment` `viewport` and `map`. `true` keeps it reading left to right
|
|
728
|
+
* (a screen-aligned billboard, or a flat quad yawed to the camera).
|
|
729
|
+
* `false` aligns it with the map: upright, it stays on screen but turns
|
|
730
|
+
* with the camera heading so its x-axis points east; flat, it lies
|
|
731
|
+
* north-up. Left unset, it is `true` for `placement: "point"` and `false`
|
|
732
|
+
* along a line, as MapLibre resolves `auto`.
|
|
482
733
|
* @param {boolean | null} [arg0]
|
|
483
734
|
*/
|
|
484
735
|
set rotateWithCamera(arg0) {
|
|
@@ -486,7 +737,7 @@ export class BillboardMaterial {
|
|
|
486
737
|
}
|
|
487
738
|
/**
|
|
488
739
|
* Rotation of the sprite within its own plane, about its anchor point,
|
|
489
|
-
* in degrees, clockwise seen from the front. `
|
|
740
|
+
* in degrees, clockwise seen from the front. `anchor` decides where
|
|
490
741
|
* inside the sprite the pivot sits. Defaults to `0.0`.
|
|
491
742
|
* @param {number | null} [arg0]
|
|
492
743
|
*/
|
|
@@ -506,6 +757,16 @@ export class BillboardMaterial {
|
|
|
506
757
|
set sizeInMeters(arg0) {
|
|
507
758
|
wasm.__wbg_set_billboardmaterial_sizeInMeters(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
508
759
|
}
|
|
760
|
+
/**
|
|
761
|
+
* Whether `size` scales the image's own pixel height instead of being the
|
|
762
|
+
* quad's height, like MapLibre's `icon-size`: `1` draws the image at its
|
|
763
|
+
* natural size. `offset` keeps the unit `sizeInMeters` gives it. Default
|
|
764
|
+
* is false.
|
|
765
|
+
* @param {boolean | null} [arg0]
|
|
766
|
+
*/
|
|
767
|
+
set sizeRelativeToImage(arg0) {
|
|
768
|
+
wasm.__wbg_set_billboardmaterial_sizeRelativeToImage(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
769
|
+
}
|
|
509
770
|
/**
|
|
510
771
|
* size in pixels/meters (units are determined by `sizeInMeters`).
|
|
511
772
|
* @param {number | null} [arg0]
|
|
@@ -513,6 +774,57 @@ export class BillboardMaterial {
|
|
|
513
774
|
set size(arg0) {
|
|
514
775
|
wasm.__wbg_set_billboardmaterial_size(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
515
776
|
}
|
|
777
|
+
/**
|
|
778
|
+
* Distance between repeated anchors along a line, in screen pixels, for
|
|
779
|
+
* `vector-tile` and `geojson` sources alike. Resolved per anchor as the
|
|
780
|
+
* camera moves: anchors thin out as it pulls back and fill in as it
|
|
781
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
782
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
783
|
+
* `symbol-spacing`, a sprite wider than three quarters of the spacing
|
|
784
|
+
* spreads its repeats to its width plus a quarter of the spacing, and a
|
|
785
|
+
* vector tile places anchors only inside its own bounds. Only used by
|
|
786
|
+
* `placement: "line"`. Defaults to `250.0`.
|
|
787
|
+
* @param {number | null} [arg0]
|
|
788
|
+
*/
|
|
789
|
+
set spacing(arg0) {
|
|
790
|
+
wasm.__wbg_set_billboardmaterial_spacing(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
791
|
+
}
|
|
792
|
+
/**
|
|
793
|
+
* Whether this may show while its partner at the same anchor (the
|
|
794
|
+
* layer's label for a billboard, its billboard for a label) is hidden.
|
|
795
|
+
* With `false` on both, the two are placed together: both show or
|
|
796
|
+
* neither does. Only meaningful when `declutter` is enabled. Defaults to
|
|
797
|
+
* `true`.
|
|
798
|
+
* @param {boolean | null} [arg0]
|
|
799
|
+
*/
|
|
800
|
+
set standalone(arg0) {
|
|
801
|
+
wasm.__wbg_set_billboardmaterial_standalone(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
802
|
+
}
|
|
803
|
+
/**
|
|
804
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
805
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
806
|
+
* the screen axes. MapLibre's `icon-translate-anchor`.
|
|
807
|
+
* @param {string | null} [arg0]
|
|
808
|
+
*/
|
|
809
|
+
set translateAnchor(arg0) {
|
|
810
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
811
|
+
var len0 = WASM_VECTOR_LEN;
|
|
812
|
+
wasm.__wbg_set_billboardmaterial_translateAnchor(this.__wbg_ptr, ptr0, len0);
|
|
813
|
+
}
|
|
814
|
+
/**
|
|
815
|
+
* Screen-pixel shift of the drawn quad, x right and y down, applied after
|
|
816
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
817
|
+
* MapLibre's `icon-translate`. Defaults to `(0, 0)`.
|
|
818
|
+
* @param {Vec2 | null} [arg0]
|
|
819
|
+
*/
|
|
820
|
+
set translate(arg0) {
|
|
821
|
+
let ptr0 = 0;
|
|
822
|
+
if (!isLikeNone(arg0)) {
|
|
823
|
+
_assertClass(arg0, Vec2);
|
|
824
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
825
|
+
}
|
|
826
|
+
wasm.__wbg_set_billboardmaterial_translate(this.__wbg_ptr, ptr0);
|
|
827
|
+
}
|
|
516
828
|
/**
|
|
517
829
|
* @param {boolean | null} [arg0]
|
|
518
830
|
*/
|
|
@@ -1220,6 +1532,7 @@ export class CompiledExpression {
|
|
|
1220
1532
|
* * `properties_json` - Feature properties as JSON object
|
|
1221
1533
|
* * `zoom` - Current zoom level
|
|
1222
1534
|
* * `geometry_type` - Optional geometry type string (e.g., "Point", "Polygon")
|
|
1535
|
+
* * `elevation` - Optional terrain elevation in meters for `["elevation"]`
|
|
1223
1536
|
*
|
|
1224
1537
|
* # Returns
|
|
1225
1538
|
* Evaluated value as JsValue. Supported types:
|
|
@@ -1232,12 +1545,13 @@ export class CompiledExpression {
|
|
|
1232
1545
|
* @param {any} properties_json
|
|
1233
1546
|
* @param {number} zoom
|
|
1234
1547
|
* @param {string | null} [geometry_type]
|
|
1548
|
+
* @param {number | null} [elevation]
|
|
1235
1549
|
* @returns {any}
|
|
1236
1550
|
*/
|
|
1237
|
-
evaluate(properties_json, zoom, geometry_type) {
|
|
1551
|
+
evaluate(properties_json, zoom, geometry_type, elevation) {
|
|
1238
1552
|
var ptr0 = isLikeNone(geometry_type) ? 0 : passStringToWasm0(geometry_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1239
1553
|
var len0 = WASM_VECTOR_LEN;
|
|
1240
|
-
const ret = wasm.compiledexpression_evaluate(this.__wbg_ptr, properties_json, zoom, ptr0, len0);
|
|
1554
|
+
const ret = wasm.compiledexpression_evaluate(this.__wbg_ptr, properties_json, zoom, ptr0, len0, !isLikeNone(elevation), isLikeNone(elevation) ? 0 : elevation);
|
|
1241
1555
|
if (ret[2]) {
|
|
1242
1556
|
throw takeFromExternrefTable0(ret[1]);
|
|
1243
1557
|
}
|
|
@@ -1675,15 +1989,15 @@ export class ConstructedPolylineGeometry {
|
|
|
1675
1989
|
/**
|
|
1676
1990
|
* @returns {Float32Array | undefined}
|
|
1677
1991
|
*/
|
|
1678
|
-
|
|
1679
|
-
const ret = wasm.
|
|
1992
|
+
end_normal_and_segment_length() {
|
|
1993
|
+
const ret = wasm.constructedpolylinegeometry_end_normal_and_segment_length(this.__wbg_ptr);
|
|
1680
1994
|
return ret;
|
|
1681
1995
|
}
|
|
1682
1996
|
/**
|
|
1683
1997
|
* @returns {number | undefined}
|
|
1684
1998
|
*/
|
|
1685
|
-
|
|
1686
|
-
const ret = wasm.
|
|
1999
|
+
end_normal_and_segment_length_size() {
|
|
2000
|
+
const ret = wasm.constructedpolylinegeometry_end_normal_and_segment_length_size(this.__wbg_ptr);
|
|
1687
2001
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
1688
2002
|
}
|
|
1689
2003
|
/**
|
|
@@ -1714,6 +2028,20 @@ export class ConstructedPolylineGeometry {
|
|
|
1714
2028
|
const ret = wasm.constructedpolylinegeometry_indices(this.__wbg_ptr);
|
|
1715
2029
|
return ret;
|
|
1716
2030
|
}
|
|
2031
|
+
/**
|
|
2032
|
+
* @returns {Float32Array | undefined}
|
|
2033
|
+
*/
|
|
2034
|
+
line_distance_and_ends() {
|
|
2035
|
+
const ret = wasm.constructedpolylinegeometry_line_distance_and_ends(this.__wbg_ptr);
|
|
2036
|
+
return ret;
|
|
2037
|
+
}
|
|
2038
|
+
/**
|
|
2039
|
+
* @returns {Float32Array | undefined}
|
|
2040
|
+
*/
|
|
2041
|
+
line_segments() {
|
|
2042
|
+
const ret = wasm.constructedpolylinegeometry_line_segments(this.__wbg_ptr);
|
|
2043
|
+
return ret;
|
|
2044
|
+
}
|
|
1717
2045
|
/**
|
|
1718
2046
|
* @returns {Float32Array}
|
|
1719
2047
|
*/
|
|
@@ -1759,15 +2087,15 @@ export class ConstructedPolylineGeometry {
|
|
|
1759
2087
|
/**
|
|
1760
2088
|
* @returns {Float32Array}
|
|
1761
2089
|
*/
|
|
1762
|
-
|
|
1763
|
-
const ret = wasm.
|
|
2090
|
+
right_normal_and_line_length() {
|
|
2091
|
+
const ret = wasm.constructedpolylinegeometry_right_normal_and_line_length(this.__wbg_ptr);
|
|
1764
2092
|
return ret;
|
|
1765
2093
|
}
|
|
1766
2094
|
/**
|
|
1767
2095
|
* @returns {number}
|
|
1768
2096
|
*/
|
|
1769
|
-
|
|
1770
|
-
const ret = wasm.
|
|
2097
|
+
right_normal_and_line_length_size() {
|
|
2098
|
+
const ret = wasm.constructedpolylinegeometry_right_normal_and_line_length_size(this.__wbg_ptr);
|
|
1771
2099
|
return ret;
|
|
1772
2100
|
}
|
|
1773
2101
|
/**
|
|
@@ -1808,15 +2136,15 @@ export class ConstructedPolylineGeometry {
|
|
|
1808
2136
|
/**
|
|
1809
2137
|
* @returns {Float32Array | undefined}
|
|
1810
2138
|
*/
|
|
1811
|
-
|
|
1812
|
-
const ret = wasm.
|
|
2139
|
+
start_normal_and_length_high() {
|
|
2140
|
+
const ret = wasm.constructedpolylinegeometry_start_normal_and_length_high(this.__wbg_ptr);
|
|
1813
2141
|
return ret;
|
|
1814
2142
|
}
|
|
1815
2143
|
/**
|
|
1816
2144
|
* @returns {number | undefined}
|
|
1817
2145
|
*/
|
|
1818
|
-
|
|
1819
|
-
const ret = wasm.
|
|
2146
|
+
start_normal_and_length_high_size() {
|
|
2147
|
+
const ret = wasm.constructedpolylinegeometry_start_normal_and_length_high_size(this.__wbg_ptr);
|
|
1820
2148
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
1821
2149
|
}
|
|
1822
2150
|
/**
|
|
@@ -2071,6 +2399,52 @@ export class ElevationHeatmapMaterial {
|
|
|
2071
2399
|
const ptr = this.__destroy_into_raw();
|
|
2072
2400
|
wasm.__wbg_elevationheatmapmaterial_free(ptr, 0);
|
|
2073
2401
|
}
|
|
2402
|
+
/**
|
|
2403
|
+
* Color map lookup table for this layer's elevation heatmap rendering.
|
|
2404
|
+
* Flattened RGBA array: [r0,g0,b0,a0, r1,g1,b1,a1, ...], evenly spaced over
|
|
2405
|
+
* [minHeight, maxHeight]. When None, the elevation renders as grayscale.
|
|
2406
|
+
* Managed on the web side (ColorMapAtlas); Rust only hashes it to detect
|
|
2407
|
+
* changes.
|
|
2408
|
+
* @returns {Float32Array | undefined}
|
|
2409
|
+
*/
|
|
2410
|
+
get colorMap() {
|
|
2411
|
+
const ret = wasm.__wbg_get_elevationheatmapmaterial_colorMap(this.__wbg_ptr);
|
|
2412
|
+
let v1;
|
|
2413
|
+
if (ret[0] !== 0) {
|
|
2414
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
2415
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2416
|
+
}
|
|
2417
|
+
return v1;
|
|
2418
|
+
}
|
|
2419
|
+
/**
|
|
2420
|
+
* Optional ascending stop elevations in meters, one per colorMap entry.
|
|
2421
|
+
* When set, colorMap entry i is placed at elevation colorStops[i] instead
|
|
2422
|
+
* of being evenly spaced over [minHeight, maxHeight].
|
|
2423
|
+
* Managed on the web side (ColorMapAtlas); Rust only hashes it to detect
|
|
2424
|
+
* changes.
|
|
2425
|
+
* @returns {Float32Array | undefined}
|
|
2426
|
+
*/
|
|
2427
|
+
get colorStops() {
|
|
2428
|
+
const ret = wasm.__wbg_get_elevationheatmapmaterial_colorStops(this.__wbg_ptr);
|
|
2429
|
+
let v1;
|
|
2430
|
+
if (ret[0] !== 0) {
|
|
2431
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
2432
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2433
|
+
}
|
|
2434
|
+
return v1;
|
|
2435
|
+
}
|
|
2436
|
+
/**
|
|
2437
|
+
* @returns {string | undefined}
|
|
2438
|
+
*/
|
|
2439
|
+
get filter() {
|
|
2440
|
+
const ret = wasm.__wbg_get_elevationheatmapmaterial_filter(this.__wbg_ptr);
|
|
2441
|
+
let v1;
|
|
2442
|
+
if (ret[0] !== 0) {
|
|
2443
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
2444
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
2445
|
+
}
|
|
2446
|
+
return v1;
|
|
2447
|
+
}
|
|
2074
2448
|
/**
|
|
2075
2449
|
* @returns {number | undefined}
|
|
2076
2450
|
*/
|
|
@@ -2099,6 +2473,40 @@ export class ElevationHeatmapMaterial {
|
|
|
2099
2473
|
const ret = wasm.__wbg_get_elevationheatmapmaterial_minHeight(this.__wbg_ptr);
|
|
2100
2474
|
return ret[0] === 0 ? undefined : ret[1];
|
|
2101
2475
|
}
|
|
2476
|
+
/**
|
|
2477
|
+
* Color map lookup table for this layer's elevation heatmap rendering.
|
|
2478
|
+
* Flattened RGBA array: [r0,g0,b0,a0, r1,g1,b1,a1, ...], evenly spaced over
|
|
2479
|
+
* [minHeight, maxHeight]. When None, the elevation renders as grayscale.
|
|
2480
|
+
* Managed on the web side (ColorMapAtlas); Rust only hashes it to detect
|
|
2481
|
+
* changes.
|
|
2482
|
+
* @param {Float32Array | null} [arg0]
|
|
2483
|
+
*/
|
|
2484
|
+
set colorMap(arg0) {
|
|
2485
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2486
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2487
|
+
wasm.__wbg_set_elevationheatmapmaterial_colorMap(this.__wbg_ptr, ptr0, len0);
|
|
2488
|
+
}
|
|
2489
|
+
/**
|
|
2490
|
+
* Optional ascending stop elevations in meters, one per colorMap entry.
|
|
2491
|
+
* When set, colorMap entry i is placed at elevation colorStops[i] instead
|
|
2492
|
+
* of being evenly spaced over [minHeight, maxHeight].
|
|
2493
|
+
* Managed on the web side (ColorMapAtlas); Rust only hashes it to detect
|
|
2494
|
+
* changes.
|
|
2495
|
+
* @param {Float32Array | null} [arg0]
|
|
2496
|
+
*/
|
|
2497
|
+
set colorStops(arg0) {
|
|
2498
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2499
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2500
|
+
wasm.__wbg_set_elevationheatmapmaterial_colorStops(this.__wbg_ptr, ptr0, len0);
|
|
2501
|
+
}
|
|
2502
|
+
/**
|
|
2503
|
+
* @param {string | null} [arg0]
|
|
2504
|
+
*/
|
|
2505
|
+
set filter(arg0) {
|
|
2506
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2507
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2508
|
+
wasm.__wbg_set_elevationheatmapmaterial_filter(this.__wbg_ptr, ptr0, len0);
|
|
2509
|
+
}
|
|
2102
2510
|
/**
|
|
2103
2511
|
* @param {number | null} [arg0]
|
|
2104
2512
|
*/
|
|
@@ -2512,6 +2920,13 @@ export class Geometry {
|
|
|
2512
2920
|
const ret = wasm.geometry_transferNormals(this.__wbg_ptr);
|
|
2513
2921
|
return ret;
|
|
2514
2922
|
}
|
|
2923
|
+
/**
|
|
2924
|
+
* @returns {Float32Array | undefined}
|
|
2925
|
+
*/
|
|
2926
|
+
transferSkirtHeights() {
|
|
2927
|
+
const ret = wasm.geometry_transferSkirtHeights(this.__wbg_ptr);
|
|
2928
|
+
return ret;
|
|
2929
|
+
}
|
|
2515
2930
|
/**
|
|
2516
2931
|
* @returns {Uint32Array | undefined}
|
|
2517
2932
|
*/
|
|
@@ -2582,17 +2997,6 @@ export class Globe {
|
|
|
2582
2997
|
const ret = wasm.__wbg_get_globe_color(this.__wbg_ptr);
|
|
2583
2998
|
return ret >>> 0;
|
|
2584
2999
|
}
|
|
2585
|
-
/**
|
|
2586
|
-
* Color map lookup table for elevation heatmap rendering.
|
|
2587
|
-
* Flattened RGB array: [r0,g0,b0, r1,g1,b1, ...].
|
|
2588
|
-
* @returns {Float32Array}
|
|
2589
|
-
*/
|
|
2590
|
-
get elevationColormap() {
|
|
2591
|
-
const ret = wasm.__wbg_get_globe_elevationColormap(this.__wbg_ptr);
|
|
2592
|
-
var v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
2593
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2594
|
-
return v1;
|
|
2595
|
-
}
|
|
2596
3000
|
/**
|
|
2597
3001
|
* Whether to hide underground geometry. Disabling this value might cause unexpected behavior when using effect.
|
|
2598
3002
|
* @returns {boolean}
|
|
@@ -2671,12 +3075,9 @@ export class Globe {
|
|
|
2671
3075
|
* @param {boolean} transparent
|
|
2672
3076
|
* @param {number} opacity
|
|
2673
3077
|
* @param {boolean} wireframe
|
|
2674
|
-
* @param {Float32Array} elevation_colormap
|
|
2675
3078
|
*/
|
|
2676
|
-
constructor(max_sse, segments, color, hide_underground, use_normal, transparent, opacity, wireframe
|
|
2677
|
-
const
|
|
2678
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2679
|
-
const ret = wasm.globe_new(max_sse, segments, color, hide_underground, use_normal, transparent, opacity, wireframe, ptr0, len0);
|
|
3079
|
+
constructor(max_sse, segments, color, hide_underground, use_normal, transparent, opacity, wireframe) {
|
|
3080
|
+
const ret = wasm.globe_new(max_sse, segments, color, hide_underground, use_normal, transparent, opacity, wireframe);
|
|
2680
3081
|
this.__wbg_ptr = ret;
|
|
2681
3082
|
GlobeFinalization.register(this, this.__wbg_ptr, this);
|
|
2682
3083
|
return this;
|
|
@@ -2688,16 +3089,6 @@ export class Globe {
|
|
|
2688
3089
|
set color(arg0) {
|
|
2689
3090
|
wasm.__wbg_set_globe_color(this.__wbg_ptr, arg0);
|
|
2690
3091
|
}
|
|
2691
|
-
/**
|
|
2692
|
-
* Color map lookup table for elevation heatmap rendering.
|
|
2693
|
-
* Flattened RGB array: [r0,g0,b0, r1,g1,b1, ...].
|
|
2694
|
-
* @param {Float32Array} arg0
|
|
2695
|
-
*/
|
|
2696
|
-
set elevationColormap(arg0) {
|
|
2697
|
-
const ptr0 = passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2698
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2699
|
-
wasm.__wbg_set_globe_elevationColormap(this.__wbg_ptr, ptr0, len0);
|
|
2700
|
-
}
|
|
2701
3092
|
/**
|
|
2702
3093
|
* Whether to hide underground geometry. Disabling this value might cause unexpected behavior when using effect.
|
|
2703
3094
|
* @param {boolean} arg0
|
|
@@ -2865,10 +3256,89 @@ export class LLE {
|
|
|
2865
3256
|
}
|
|
2866
3257
|
if (Symbol.dispose) LLE.prototype[Symbol.dispose] = LLE.prototype.free;
|
|
2867
3258
|
|
|
2868
|
-
export class
|
|
2869
|
-
|
|
2870
|
-
const
|
|
2871
|
-
|
|
3259
|
+
export class LineDashAtlas {
|
|
3260
|
+
__destroy_into_raw() {
|
|
3261
|
+
const ptr = this.__wbg_ptr;
|
|
3262
|
+
this.__wbg_ptr = 0;
|
|
3263
|
+
LineDashAtlasFinalization.unregister(this);
|
|
3264
|
+
return ptr;
|
|
3265
|
+
}
|
|
3266
|
+
free() {
|
|
3267
|
+
const ptr = this.__destroy_into_raw();
|
|
3268
|
+
wasm.__wbg_linedashatlas_free(ptr, 0);
|
|
3269
|
+
}
|
|
3270
|
+
/**
|
|
3271
|
+
* The rows as RGBA float texels, `rowTexels` wide and `rowCapacity`
|
|
3272
|
+
* high. A view into WASM memory: copy it before the next allocation.
|
|
3273
|
+
* @returns {Float32Array}
|
|
3274
|
+
*/
|
|
3275
|
+
get data() {
|
|
3276
|
+
const ret = wasm.linedashatlas_data(this.__wbg_ptr);
|
|
3277
|
+
return ret;
|
|
3278
|
+
}
|
|
3279
|
+
/**
|
|
3280
|
+
* Changes whenever a row is written into `data`.
|
|
3281
|
+
* @returns {number}
|
|
3282
|
+
*/
|
|
3283
|
+
get dataVersion() {
|
|
3284
|
+
const ret = wasm.linedashatlas_dataVersion(this.__wbg_ptr);
|
|
3285
|
+
return ret >>> 0;
|
|
3286
|
+
}
|
|
3287
|
+
constructor() {
|
|
3288
|
+
const ret = wasm.linedashatlas_new();
|
|
3289
|
+
this.__wbg_ptr = ret;
|
|
3290
|
+
LineDashAtlasFinalization.register(this, this.__wbg_ptr, this);
|
|
3291
|
+
return this;
|
|
3292
|
+
}
|
|
3293
|
+
/**
|
|
3294
|
+
* Returns the row holding the pattern of `dash_array` drawn with `cap`
|
|
3295
|
+
* (`"butt" | "round" | "square"`), adding it on first use, and holds it
|
|
3296
|
+
* until `release`. A solid line with butt ends, and a pattern the atlas
|
|
3297
|
+
* cannot hold, are row `0`; the latter warns once per reason. An unknown
|
|
3298
|
+
* cap warns once and draws as `"butt"`.
|
|
3299
|
+
* @param {Float32Array | null | undefined} dash_array
|
|
3300
|
+
* @param {string} cap
|
|
3301
|
+
* @returns {number}
|
|
3302
|
+
*/
|
|
3303
|
+
register(dash_array, cap) {
|
|
3304
|
+
var ptr0 = isLikeNone(dash_array) ? 0 : passArrayF32ToWasm0(dash_array, wasm.__wbindgen_malloc);
|
|
3305
|
+
var len0 = WASM_VECTOR_LEN;
|
|
3306
|
+
const ptr1 = passStringToWasm0(cap, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3307
|
+
const len1 = WASM_VECTOR_LEN;
|
|
3308
|
+
const ret = wasm.linedashatlas_register(this.__wbg_ptr, ptr0, len0, ptr1, len1);
|
|
3309
|
+
return ret >>> 0;
|
|
3310
|
+
}
|
|
3311
|
+
/**
|
|
3312
|
+
* Ends one `register` of `row`; the last one frees the row for another
|
|
3313
|
+
* pattern. A row nobody holds is left as is and warns once.
|
|
3314
|
+
* @param {number} row
|
|
3315
|
+
*/
|
|
3316
|
+
release(row) {
|
|
3317
|
+
wasm.linedashatlas_release(this.__wbg_ptr, row);
|
|
3318
|
+
}
|
|
3319
|
+
/**
|
|
3320
|
+
* Rows `data` holds; it grows when a row is added past it.
|
|
3321
|
+
* @returns {number}
|
|
3322
|
+
*/
|
|
3323
|
+
get rowCapacity() {
|
|
3324
|
+
const ret = wasm.linedashatlas_rowCapacity(this.__wbg_ptr);
|
|
3325
|
+
return ret >>> 0;
|
|
3326
|
+
}
|
|
3327
|
+
/**
|
|
3328
|
+
* RGBA texels per row.
|
|
3329
|
+
* @returns {number}
|
|
3330
|
+
*/
|
|
3331
|
+
get rowTexels() {
|
|
3332
|
+
const ret = wasm.linedashatlas_rowTexels(this.__wbg_ptr);
|
|
3333
|
+
return ret >>> 0;
|
|
3334
|
+
}
|
|
3335
|
+
}
|
|
3336
|
+
if (Symbol.dispose) LineDashAtlas.prototype[Symbol.dispose] = LineDashAtlas.prototype.free;
|
|
3337
|
+
|
|
3338
|
+
export class ModelInternalMaterial {
|
|
3339
|
+
static __wrap(ptr) {
|
|
3340
|
+
const obj = Object.create(ModelInternalMaterial.prototype);
|
|
3341
|
+
obj.__wbg_ptr = ptr;
|
|
2872
3342
|
ModelInternalMaterialFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2873
3343
|
return obj;
|
|
2874
3344
|
}
|
|
@@ -2970,13 +3440,6 @@ export class ModelMaterial {
|
|
|
2970
3440
|
const ret = wasm.__wbg_get_modelmaterial_animationSpeed(this.__wbg_ptr);
|
|
2971
3441
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
2972
3442
|
}
|
|
2973
|
-
/**
|
|
2974
|
-
* @returns {boolean | undefined}
|
|
2975
|
-
*/
|
|
2976
|
-
get applyWaterNormal() {
|
|
2977
|
-
const ret = wasm.__wbg_get_modelmaterial_applyWaterNormal(this.__wbg_ptr);
|
|
2978
|
-
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
2979
|
-
}
|
|
2980
3443
|
/**
|
|
2981
3444
|
* @returns {boolean | undefined}
|
|
2982
3445
|
*/
|
|
@@ -3037,6 +3500,15 @@ export class ModelMaterial {
|
|
|
3037
3500
|
const ret = wasm.__wbg_get_modelmaterial_emissiveIntensity(this.__wbg_ptr);
|
|
3038
3501
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3039
3502
|
}
|
|
3503
|
+
/**
|
|
3504
|
+
* Speed in m/s of the current carrying the water's waves
|
|
3505
|
+
* along `waveDirection`. Default: 0.
|
|
3506
|
+
* @returns {number | undefined}
|
|
3507
|
+
*/
|
|
3508
|
+
get flowSpeed() {
|
|
3509
|
+
const ret = wasm.__wbg_get_modelmaterial_flowSpeed(this.__wbg_ptr);
|
|
3510
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3511
|
+
}
|
|
3040
3512
|
/**
|
|
3041
3513
|
* @returns {number | undefined}
|
|
3042
3514
|
*/
|
|
@@ -3124,6 +3596,7 @@ export class ModelMaterial {
|
|
|
3124
3596
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3125
3597
|
}
|
|
3126
3598
|
/**
|
|
3599
|
+
* Phong shininess of the non-water `specular` highlight.
|
|
3127
3600
|
* @returns {number | undefined}
|
|
3128
3601
|
*/
|
|
3129
3602
|
get shininess() {
|
|
@@ -3167,6 +3640,7 @@ export class ModelMaterial {
|
|
|
3167
3640
|
}
|
|
3168
3641
|
/**
|
|
3169
3642
|
* Enabling this value allows using `shininess` and `specular_strength`.
|
|
3643
|
+
* Has no effect on water.
|
|
3170
3644
|
* @returns {boolean | undefined}
|
|
3171
3645
|
*/
|
|
3172
3646
|
get specular() {
|
|
@@ -3194,28 +3668,54 @@ export class ModelMaterial {
|
|
|
3194
3668
|
return v1;
|
|
3195
3669
|
}
|
|
3196
3670
|
/**
|
|
3197
|
-
*
|
|
3671
|
+
* Extent of the water body, which bounds how far the wind blows over it
|
|
3672
|
+
* and so how large its waves grow: `"ocean"` (the default; open sea),
|
|
3673
|
+
* `"large"` (a bay or a large lake, about 20 km), `"medium"` (a lake or a
|
|
3674
|
+
* wide river, about 2 km) or `"small"` (a river or a pond, about 200 m).
|
|
3675
|
+
* @returns {string | undefined}
|
|
3676
|
+
*/
|
|
3677
|
+
get waterScale() {
|
|
3678
|
+
const ret = wasm.__wbg_get_modelmaterial_waterScale(this.__wbg_ptr);
|
|
3679
|
+
let v1;
|
|
3680
|
+
if (ret[0] !== 0) {
|
|
3681
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
3682
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
3683
|
+
}
|
|
3684
|
+
return v1;
|
|
3685
|
+
}
|
|
3686
|
+
/**
|
|
3687
|
+
* Apply a water material on the polygon. It might slow down the loading of the mesh.
|
|
3688
|
+
* @returns {boolean | undefined}
|
|
3689
|
+
*/
|
|
3690
|
+
get water() {
|
|
3691
|
+
const ret = wasm.__wbg_get_modelmaterial_water(this.__wbg_ptr);
|
|
3692
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3693
|
+
}
|
|
3694
|
+
/**
|
|
3695
|
+
* Where the water's waves travel, in degrees clockwise from north.
|
|
3696
|
+
* Default: 0.
|
|
3198
3697
|
* @returns {number | undefined}
|
|
3199
3698
|
*/
|
|
3200
|
-
get
|
|
3201
|
-
const ret = wasm.
|
|
3699
|
+
get waveDirection() {
|
|
3700
|
+
const ret = wasm.__wbg_get_modelmaterial_waveDirection(this.__wbg_ptr);
|
|
3202
3701
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3203
3702
|
}
|
|
3204
3703
|
/**
|
|
3205
|
-
*
|
|
3704
|
+
* Scales the water's wave slopes; 0 is a flat mirror.
|
|
3206
3705
|
* @returns {number | undefined}
|
|
3207
3706
|
*/
|
|
3208
|
-
get
|
|
3209
|
-
const ret = wasm.
|
|
3707
|
+
get waveExaggeration() {
|
|
3708
|
+
const ret = wasm.__wbg_get_modelmaterial_waveExaggeration(this.__wbg_ptr);
|
|
3210
3709
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3211
3710
|
}
|
|
3212
3711
|
/**
|
|
3213
|
-
*
|
|
3214
|
-
*
|
|
3712
|
+
* Sets the size, steepness and speed of the water's waves: about 1 is a
|
|
3713
|
+
* calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
3714
|
+
* @returns {number | undefined}
|
|
3215
3715
|
*/
|
|
3216
|
-
get
|
|
3217
|
-
const ret = wasm.
|
|
3218
|
-
return ret ===
|
|
3716
|
+
get waveStrength() {
|
|
3717
|
+
const ret = wasm.__wbg_get_modelmaterial_waveStrength(this.__wbg_ptr);
|
|
3718
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3219
3719
|
}
|
|
3220
3720
|
/**
|
|
3221
3721
|
* @param {ModelInternalMaterial | null} [arg0]
|
|
@@ -3242,12 +3742,6 @@ export class ModelMaterial {
|
|
|
3242
3742
|
set animationSpeed(arg0) {
|
|
3243
3743
|
wasm.__wbg_set_modelmaterial_animationSpeed(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3244
3744
|
}
|
|
3245
|
-
/**
|
|
3246
|
-
* @param {boolean | null} [arg0]
|
|
3247
|
-
*/
|
|
3248
|
-
set applyWaterNormal(arg0) {
|
|
3249
|
-
wasm.__wbg_set_modelmaterial_applyWaterNormal(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
3250
|
-
}
|
|
3251
3745
|
/**
|
|
3252
3746
|
* @param {boolean | null} [arg0]
|
|
3253
3747
|
*/
|
|
@@ -3298,6 +3792,14 @@ export class ModelMaterial {
|
|
|
3298
3792
|
set emissiveIntensity(arg0) {
|
|
3299
3793
|
wasm.__wbg_set_modelmaterial_emissiveIntensity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3300
3794
|
}
|
|
3795
|
+
/**
|
|
3796
|
+
* Speed in m/s of the current carrying the water's waves
|
|
3797
|
+
* along `waveDirection`. Default: 0.
|
|
3798
|
+
* @param {number | null} [arg0]
|
|
3799
|
+
*/
|
|
3800
|
+
set flowSpeed(arg0) {
|
|
3801
|
+
wasm.__wbg_set_modelmaterial_flowSpeed(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3802
|
+
}
|
|
3301
3803
|
/**
|
|
3302
3804
|
* @param {number | null} [arg0]
|
|
3303
3805
|
*/
|
|
@@ -3374,6 +3876,7 @@ export class ModelMaterial {
|
|
|
3374
3876
|
wasm.__wbg_set_modelmaterial_roughness(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3375
3877
|
}
|
|
3376
3878
|
/**
|
|
3879
|
+
* Phong shininess of the non-water `specular` highlight.
|
|
3377
3880
|
* @param {number | null} [arg0]
|
|
3378
3881
|
*/
|
|
3379
3882
|
set shininess(arg0) {
|
|
@@ -3411,6 +3914,7 @@ export class ModelMaterial {
|
|
|
3411
3914
|
}
|
|
3412
3915
|
/**
|
|
3413
3916
|
* Enabling this value allows using `shininess` and `specular_strength`.
|
|
3917
|
+
* Has no effect on water.
|
|
3414
3918
|
* @param {boolean | null} [arg0]
|
|
3415
3919
|
*/
|
|
3416
3920
|
set specular(arg0) {
|
|
@@ -3432,25 +3936,46 @@ export class ModelMaterial {
|
|
|
3432
3936
|
wasm.__wbg_set_modelmaterial_url(this.__wbg_ptr, ptr0, len0);
|
|
3433
3937
|
}
|
|
3434
3938
|
/**
|
|
3435
|
-
*
|
|
3939
|
+
* Extent of the water body, which bounds how far the wind blows over it
|
|
3940
|
+
* and so how large its waves grow: `"ocean"` (the default; open sea),
|
|
3941
|
+
* `"large"` (a bay or a large lake, about 20 km), `"medium"` (a lake or a
|
|
3942
|
+
* wide river, about 2 km) or `"small"` (a river or a pond, about 200 m).
|
|
3943
|
+
* @param {string | null} [arg0]
|
|
3944
|
+
*/
|
|
3945
|
+
set waterScale(arg0) {
|
|
3946
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3947
|
+
var len0 = WASM_VECTOR_LEN;
|
|
3948
|
+
wasm.__wbg_set_modelmaterial_waterScale(this.__wbg_ptr, ptr0, len0);
|
|
3949
|
+
}
|
|
3950
|
+
/**
|
|
3951
|
+
* Apply a water material on the polygon. It might slow down the loading of the mesh.
|
|
3952
|
+
* @param {boolean | null} [arg0]
|
|
3953
|
+
*/
|
|
3954
|
+
set water(arg0) {
|
|
3955
|
+
wasm.__wbg_set_modelmaterial_water(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
3956
|
+
}
|
|
3957
|
+
/**
|
|
3958
|
+
* Where the water's waves travel, in degrees clockwise from north.
|
|
3959
|
+
* Default: 0.
|
|
3436
3960
|
* @param {number | null} [arg0]
|
|
3437
3961
|
*/
|
|
3438
|
-
set
|
|
3439
|
-
wasm.
|
|
3962
|
+
set waveDirection(arg0) {
|
|
3963
|
+
wasm.__wbg_set_modelmaterial_waveDirection(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3440
3964
|
}
|
|
3441
3965
|
/**
|
|
3442
|
-
*
|
|
3966
|
+
* Scales the water's wave slopes; 0 is a flat mirror.
|
|
3443
3967
|
* @param {number | null} [arg0]
|
|
3444
3968
|
*/
|
|
3445
|
-
set
|
|
3446
|
-
wasm.
|
|
3969
|
+
set waveExaggeration(arg0) {
|
|
3970
|
+
wasm.__wbg_set_modelmaterial_waveExaggeration(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3447
3971
|
}
|
|
3448
3972
|
/**
|
|
3449
|
-
*
|
|
3450
|
-
*
|
|
3973
|
+
* Sets the size, steepness and speed of the water's waves: about 1 is a
|
|
3974
|
+
* calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
3975
|
+
* @param {number | null} [arg0]
|
|
3451
3976
|
*/
|
|
3452
|
-
set
|
|
3453
|
-
wasm.
|
|
3977
|
+
set waveStrength(arg0) {
|
|
3978
|
+
wasm.__wbg_set_modelmaterial_waveStrength(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3454
3979
|
}
|
|
3455
3980
|
}
|
|
3456
3981
|
if (Symbol.dispose) ModelMaterial.prototype[Symbol.dispose] = ModelMaterial.prototype.free;
|
|
@@ -3582,25 +4107,31 @@ export class PointMaterial {
|
|
|
3582
4107
|
wasm.__wbg_pointmaterial_free(ptr, 0);
|
|
3583
4108
|
}
|
|
3584
4109
|
/**
|
|
3585
|
-
*
|
|
3586
|
-
*
|
|
3587
|
-
*
|
|
3588
|
-
*
|
|
4110
|
+
* Part of the quad placed at the anchor point: `"center"` (default),
|
|
4111
|
+
* `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`, `"top-right"`,
|
|
4112
|
+
* `"bottom-left"` or `"bottom-right"`, as MapLibre's `icon-anchor`.
|
|
4113
|
+
* @returns {string | undefined}
|
|
4114
|
+
*/
|
|
4115
|
+
get anchor() {
|
|
4116
|
+
const ret = wasm.__wbg_get_pointmaterial_anchor(this.__wbg_ptr);
|
|
4117
|
+
let v1;
|
|
4118
|
+
if (ret[0] !== 0) {
|
|
4119
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
4120
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
4121
|
+
}
|
|
4122
|
+
return v1;
|
|
4123
|
+
}
|
|
4124
|
+
/**
|
|
4125
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
4126
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
4127
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
4128
|
+
* camera.
|
|
3589
4129
|
* @returns {boolean | undefined}
|
|
3590
4130
|
*/
|
|
3591
4131
|
get backfaceCulling() {
|
|
3592
4132
|
const ret = wasm.__wbg_get_pointmaterial_backfaceCulling(this.__wbg_ptr);
|
|
3593
4133
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3594
4134
|
}
|
|
3595
|
-
/**
|
|
3596
|
-
* anchor point of the sprite, range is (-0.5, -0.5) to (0.5, 0.5).
|
|
3597
|
-
* Default is (0.0, 0.0) which means the center of the sprite.
|
|
3598
|
-
* @returns {Vec2 | undefined}
|
|
3599
|
-
*/
|
|
3600
|
-
get center() {
|
|
3601
|
-
const ret = wasm.__wbg_get_pointmaterial_center(this.__wbg_ptr);
|
|
3602
|
-
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
3603
|
-
}
|
|
3604
4135
|
/**
|
|
3605
4136
|
* @returns {boolean | undefined}
|
|
3606
4137
|
*/
|
|
@@ -3615,6 +4146,21 @@ export class PointMaterial {
|
|
|
3615
4146
|
const ret = wasm.__wbg_get_pointmaterial_color(this.__wbg_ptr);
|
|
3616
4147
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3617
4148
|
}
|
|
4149
|
+
/**
|
|
4150
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
4151
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
4152
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
4153
|
+
* @returns {Float32Array | undefined}
|
|
4154
|
+
*/
|
|
4155
|
+
get declutterPadding() {
|
|
4156
|
+
const ret = wasm.__wbg_get_pointmaterial_declutterPadding(this.__wbg_ptr);
|
|
4157
|
+
let v1;
|
|
4158
|
+
if (ret[0] !== 0) {
|
|
4159
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
4160
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
4161
|
+
}
|
|
4162
|
+
return v1;
|
|
4163
|
+
}
|
|
3618
4164
|
/**
|
|
3619
4165
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
3620
4166
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -3624,6 +4170,17 @@ export class PointMaterial {
|
|
|
3624
4170
|
const ret = wasm.__wbg_get_pointmaterial_declutterPriority(this.__wbg_ptr);
|
|
3625
4171
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3626
4172
|
}
|
|
4173
|
+
/**
|
|
4174
|
+
* Coarse placement order for decluttering, compared before
|
|
4175
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
4176
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
4177
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
4178
|
+
* @returns {number | undefined}
|
|
4179
|
+
*/
|
|
4180
|
+
get declutterRank() {
|
|
4181
|
+
const ret = wasm.__wbg_get_pointmaterial_declutterRank(this.__wbg_ptr);
|
|
4182
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4183
|
+
}
|
|
3627
4184
|
/**
|
|
3628
4185
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
3629
4186
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -3692,6 +4249,16 @@ export class PointMaterial {
|
|
|
3692
4249
|
const ret = wasm.__wbg_get_pointmaterial_height(this.__wbg_ptr);
|
|
3693
4250
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3694
4251
|
}
|
|
4252
|
+
/**
|
|
4253
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
4254
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
4255
|
+
* Defaults to `false`.
|
|
4256
|
+
* @returns {boolean | undefined}
|
|
4257
|
+
*/
|
|
4258
|
+
get ignorePlacement() {
|
|
4259
|
+
const ret = wasm.__wbg_get_pointmaterial_ignorePlacement(this.__wbg_ptr);
|
|
4260
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4261
|
+
}
|
|
3695
4262
|
/**
|
|
3696
4263
|
* Avoid overlapping with the globe surface.
|
|
3697
4264
|
* @returns {boolean | undefined}
|
|
@@ -3700,6 +4267,16 @@ export class PointMaterial {
|
|
|
3700
4267
|
const ret = wasm.__wbg_get_pointmaterial_offsetDepth(this.__wbg_ptr);
|
|
3701
4268
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3702
4269
|
}
|
|
4270
|
+
/**
|
|
4271
|
+
* Shift from the anchor point, x right and y down, in the unit of `size`
|
|
4272
|
+
* (meters when `sizeInMeters`, pixels otherwise). Lies in the quad's own
|
|
4273
|
+
* plane, so it turns with `rotation`. Defaults to `(0, 0)`.
|
|
4274
|
+
* @returns {Vec2 | undefined}
|
|
4275
|
+
*/
|
|
4276
|
+
get offset() {
|
|
4277
|
+
const ret = wasm.__wbg_get_pointmaterial_offset(this.__wbg_ptr);
|
|
4278
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
4279
|
+
}
|
|
3703
4280
|
/**
|
|
3704
4281
|
* @returns {number | undefined}
|
|
3705
4282
|
*/
|
|
@@ -3708,9 +4285,45 @@ export class PointMaterial {
|
|
|
3708
4285
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3709
4286
|
}
|
|
3710
4287
|
/**
|
|
3711
|
-
* Whether the
|
|
3712
|
-
*
|
|
3713
|
-
* `
|
|
4288
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
4289
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
4290
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
4291
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
4292
|
+
* @returns {string | undefined}
|
|
4293
|
+
*/
|
|
4294
|
+
get overlap() {
|
|
4295
|
+
const ret = wasm.__wbg_get_pointmaterial_overlap(this.__wbg_ptr);
|
|
4296
|
+
let v1;
|
|
4297
|
+
if (ret[0] !== 0) {
|
|
4298
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
4299
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
4300
|
+
}
|
|
4301
|
+
return v1;
|
|
4302
|
+
}
|
|
4303
|
+
/**
|
|
4304
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
4305
|
+
* default) puts one at every line and polygon-ring vertex, `"line"`
|
|
4306
|
+
* repeats them along the line every `spacing`, `"line-center"` places a
|
|
4307
|
+
* single one at the line's midpoint. Polygon rings are walked like lines. Requires `geometryTypes`
|
|
4308
|
+
* to include `"line"` or `"polygon"`.
|
|
4309
|
+
* @returns {string | undefined}
|
|
4310
|
+
*/
|
|
4311
|
+
get placement() {
|
|
4312
|
+
const ret = wasm.__wbg_get_pointmaterial_placement(this.__wbg_ptr);
|
|
4313
|
+
let v1;
|
|
4314
|
+
if (ret[0] !== 0) {
|
|
4315
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
4316
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
4317
|
+
}
|
|
4318
|
+
return v1;
|
|
4319
|
+
}
|
|
4320
|
+
/**
|
|
4321
|
+
* Plane the point lies in: the screen (`"upright"`, never foreshortened)
|
|
4322
|
+
* or the globe surface around its anchor (`"flat"`), as MapLibre's
|
|
4323
|
+
* `icon-pitch-alignment` `viewport` and `map`. Pair with
|
|
4324
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
4325
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
4326
|
+
* `auto`.
|
|
3714
4327
|
* @returns {string | undefined}
|
|
3715
4328
|
*/
|
|
3716
4329
|
get pointFacing() {
|
|
@@ -3723,9 +4336,22 @@ export class PointMaterial {
|
|
|
3723
4336
|
return v1;
|
|
3724
4337
|
}
|
|
3725
4338
|
/**
|
|
3726
|
-
*
|
|
3727
|
-
*
|
|
3728
|
-
*
|
|
4339
|
+
* Add the line's tangent bearing at the anchor to `rotation`, so the
|
|
4340
|
+
* sprite turns with the line it sits on. Defaults to `true`.
|
|
4341
|
+
* @returns {boolean | undefined}
|
|
4342
|
+
*/
|
|
4343
|
+
get rotateToLine() {
|
|
4344
|
+
const ret = wasm.__wbg_get_pointmaterial_rotateToLine(this.__wbg_ptr);
|
|
4345
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4346
|
+
}
|
|
4347
|
+
/**
|
|
4348
|
+
* Whether the point turns with the camera or with the map, as MapLibre's
|
|
4349
|
+
* `icon-rotation-alignment` `viewport` and `map`. `true` keeps it reading left to right
|
|
4350
|
+
* (a screen-aligned billboard, or a flat quad yawed to the camera).
|
|
4351
|
+
* `false` aligns it with the map: upright, it stays on screen but turns
|
|
4352
|
+
* with the camera heading so its x-axis points east; flat, it lies
|
|
4353
|
+
* north-up. Left unset, it is `true` for `placement: "point"` and `false`
|
|
4354
|
+
* along a line, as MapLibre resolves `auto`.
|
|
3729
4355
|
* @returns {boolean | undefined}
|
|
3730
4356
|
*/
|
|
3731
4357
|
get rotateWithCamera() {
|
|
@@ -3734,7 +4360,7 @@ export class PointMaterial {
|
|
|
3734
4360
|
}
|
|
3735
4361
|
/**
|
|
3736
4362
|
* Rotation of the point within its own plane, about its anchor point, in
|
|
3737
|
-
* degrees, clockwise seen from the front. `
|
|
4363
|
+
* degrees, clockwise seen from the front. `anchor` decides where inside
|
|
3738
4364
|
* the quad the pivot sits. Defaults to `0.0`.
|
|
3739
4365
|
* @returns {number | undefined}
|
|
3740
4366
|
*/
|
|
@@ -3765,6 +4391,47 @@ export class PointMaterial {
|
|
|
3765
4391
|
const ret = wasm.__wbg_get_pointmaterial_size(this.__wbg_ptr);
|
|
3766
4392
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3767
4393
|
}
|
|
4394
|
+
/**
|
|
4395
|
+
* Distance between repeated anchors along a line, in screen pixels, for
|
|
4396
|
+
* `vector-tile` and `geojson` sources alike. Resolved per anchor as the
|
|
4397
|
+
* camera moves: anchors thin out as it pulls back and fill in as it
|
|
4398
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
4399
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
4400
|
+
* `symbol-spacing`, a sprite wider than three quarters of the spacing
|
|
4401
|
+
* spreads its repeats to its width plus a quarter of the spacing, and a
|
|
4402
|
+
* vector tile places anchors only inside its own bounds. Only used by
|
|
4403
|
+
* `placement: "line"`. Defaults to `250.0`.
|
|
4404
|
+
* @returns {number | undefined}
|
|
4405
|
+
*/
|
|
4406
|
+
get spacing() {
|
|
4407
|
+
const ret = wasm.__wbg_get_pointmaterial_spacing(this.__wbg_ptr);
|
|
4408
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4409
|
+
}
|
|
4410
|
+
/**
|
|
4411
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
4412
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
4413
|
+
* the screen axes. MapLibre's `icon-translate-anchor`.
|
|
4414
|
+
* @returns {string | undefined}
|
|
4415
|
+
*/
|
|
4416
|
+
get translateAnchor() {
|
|
4417
|
+
const ret = wasm.__wbg_get_pointmaterial_translateAnchor(this.__wbg_ptr);
|
|
4418
|
+
let v1;
|
|
4419
|
+
if (ret[0] !== 0) {
|
|
4420
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
4421
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
4422
|
+
}
|
|
4423
|
+
return v1;
|
|
4424
|
+
}
|
|
4425
|
+
/**
|
|
4426
|
+
* Screen-pixel shift of the drawn quad, x right and y down, applied after
|
|
4427
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
4428
|
+
* MapLibre's `icon-translate`. Defaults to `(0, 0)`.
|
|
4429
|
+
* @returns {Vec2 | undefined}
|
|
4430
|
+
*/
|
|
4431
|
+
get translate() {
|
|
4432
|
+
const ret = wasm.__wbg_get_pointmaterial_translate(this.__wbg_ptr);
|
|
4433
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
4434
|
+
}
|
|
3768
4435
|
/**
|
|
3769
4436
|
* @returns {boolean | undefined}
|
|
3770
4437
|
*/
|
|
@@ -3773,27 +4440,25 @@ export class PointMaterial {
|
|
|
3773
4440
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3774
4441
|
}
|
|
3775
4442
|
/**
|
|
3776
|
-
*
|
|
3777
|
-
*
|
|
3778
|
-
*
|
|
3779
|
-
*
|
|
3780
|
-
* @param {boolean | null} [arg0]
|
|
4443
|
+
* Part of the quad placed at the anchor point: `"center"` (default),
|
|
4444
|
+
* `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`, `"top-right"`,
|
|
4445
|
+
* `"bottom-left"` or `"bottom-right"`, as MapLibre's `icon-anchor`.
|
|
4446
|
+
* @param {string | null} [arg0]
|
|
3781
4447
|
*/
|
|
3782
|
-
set
|
|
3783
|
-
|
|
4448
|
+
set anchor(arg0) {
|
|
4449
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4450
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4451
|
+
wasm.__wbg_set_pointmaterial_anchor(this.__wbg_ptr, ptr0, len0);
|
|
3784
4452
|
}
|
|
3785
4453
|
/**
|
|
3786
|
-
*
|
|
3787
|
-
*
|
|
3788
|
-
*
|
|
4454
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
4455
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
4456
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
4457
|
+
* camera.
|
|
4458
|
+
* @param {boolean | null} [arg0]
|
|
3789
4459
|
*/
|
|
3790
|
-
set
|
|
3791
|
-
|
|
3792
|
-
if (!isLikeNone(arg0)) {
|
|
3793
|
-
_assertClass(arg0, Vec2);
|
|
3794
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
3795
|
-
}
|
|
3796
|
-
wasm.__wbg_set_pointmaterial_center(this.__wbg_ptr, ptr0);
|
|
4460
|
+
set backfaceCulling(arg0) {
|
|
4461
|
+
wasm.__wbg_set_pointmaterial_backfaceCulling(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
3797
4462
|
}
|
|
3798
4463
|
/**
|
|
3799
4464
|
* @param {boolean | null} [arg0]
|
|
@@ -3807,6 +4472,17 @@ export class PointMaterial {
|
|
|
3807
4472
|
set color(arg0) {
|
|
3808
4473
|
wasm.__wbg_set_pointmaterial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
3809
4474
|
}
|
|
4475
|
+
/**
|
|
4476
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
4477
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
4478
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
4479
|
+
* @param {Float32Array | null} [arg0]
|
|
4480
|
+
*/
|
|
4481
|
+
set declutterPadding(arg0) {
|
|
4482
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
4483
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4484
|
+
wasm.__wbg_set_pointmaterial_declutterPadding(this.__wbg_ptr, ptr0, len0);
|
|
4485
|
+
}
|
|
3810
4486
|
/**
|
|
3811
4487
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
3812
4488
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -3815,6 +4491,16 @@ export class PointMaterial {
|
|
|
3815
4491
|
set declutterPriority(arg0) {
|
|
3816
4492
|
wasm.__wbg_set_pointmaterial_declutterPriority(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3817
4493
|
}
|
|
4494
|
+
/**
|
|
4495
|
+
* Coarse placement order for decluttering, compared before
|
|
4496
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
4497
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
4498
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
4499
|
+
* @param {number | null} [arg0]
|
|
4500
|
+
*/
|
|
4501
|
+
set declutterRank(arg0) {
|
|
4502
|
+
wasm.__wbg_set_pointmaterial_declutterRank(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4503
|
+
}
|
|
3818
4504
|
/**
|
|
3819
4505
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
3820
4506
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -3870,6 +4556,15 @@ export class PointMaterial {
|
|
|
3870
4556
|
set height(arg0) {
|
|
3871
4557
|
wasm.__wbg_set_pointmaterial_height(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3872
4558
|
}
|
|
4559
|
+
/**
|
|
4560
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
4561
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
4562
|
+
* Defaults to `false`.
|
|
4563
|
+
* @param {boolean | null} [arg0]
|
|
4564
|
+
*/
|
|
4565
|
+
set ignorePlacement(arg0) {
|
|
4566
|
+
wasm.__wbg_set_pointmaterial_ignorePlacement(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4567
|
+
}
|
|
3873
4568
|
/**
|
|
3874
4569
|
* Avoid overlapping with the globe surface.
|
|
3875
4570
|
* @param {boolean | null} [arg0]
|
|
@@ -3877,6 +4572,20 @@ export class PointMaterial {
|
|
|
3877
4572
|
set offsetDepth(arg0) {
|
|
3878
4573
|
wasm.__wbg_set_pointmaterial_offsetDepth(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
3879
4574
|
}
|
|
4575
|
+
/**
|
|
4576
|
+
* Shift from the anchor point, x right and y down, in the unit of `size`
|
|
4577
|
+
* (meters when `sizeInMeters`, pixels otherwise). Lies in the quad's own
|
|
4578
|
+
* plane, so it turns with `rotation`. Defaults to `(0, 0)`.
|
|
4579
|
+
* @param {Vec2 | null} [arg0]
|
|
4580
|
+
*/
|
|
4581
|
+
set offset(arg0) {
|
|
4582
|
+
let ptr0 = 0;
|
|
4583
|
+
if (!isLikeNone(arg0)) {
|
|
4584
|
+
_assertClass(arg0, Vec2);
|
|
4585
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
4586
|
+
}
|
|
4587
|
+
wasm.__wbg_set_pointmaterial_offset(this.__wbg_ptr, ptr0);
|
|
4588
|
+
}
|
|
3880
4589
|
/**
|
|
3881
4590
|
* @param {number | null} [arg0]
|
|
3882
4591
|
*/
|
|
@@ -3884,9 +4593,37 @@ export class PointMaterial {
|
|
|
3884
4593
|
wasm.__wbg_set_pointmaterial_opacity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3885
4594
|
}
|
|
3886
4595
|
/**
|
|
3887
|
-
* Whether the
|
|
3888
|
-
*
|
|
3889
|
-
* `
|
|
4596
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
4597
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
4598
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
4599
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
4600
|
+
* @param {string | null} [arg0]
|
|
4601
|
+
*/
|
|
4602
|
+
set overlap(arg0) {
|
|
4603
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4604
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4605
|
+
wasm.__wbg_set_pointmaterial_overlap(this.__wbg_ptr, ptr0, len0);
|
|
4606
|
+
}
|
|
4607
|
+
/**
|
|
4608
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
4609
|
+
* default) puts one at every line and polygon-ring vertex, `"line"`
|
|
4610
|
+
* repeats them along the line every `spacing`, `"line-center"` places a
|
|
4611
|
+
* single one at the line's midpoint. Polygon rings are walked like lines. Requires `geometryTypes`
|
|
4612
|
+
* to include `"line"` or `"polygon"`.
|
|
4613
|
+
* @param {string | null} [arg0]
|
|
4614
|
+
*/
|
|
4615
|
+
set placement(arg0) {
|
|
4616
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4617
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4618
|
+
wasm.__wbg_set_pointmaterial_placement(this.__wbg_ptr, ptr0, len0);
|
|
4619
|
+
}
|
|
4620
|
+
/**
|
|
4621
|
+
* Plane the point lies in: the screen (`"upright"`, never foreshortened)
|
|
4622
|
+
* or the globe surface around its anchor (`"flat"`), as MapLibre's
|
|
4623
|
+
* `icon-pitch-alignment` `viewport` and `map`. Pair with
|
|
4624
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
4625
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
4626
|
+
* `auto`.
|
|
3890
4627
|
* @param {string | null} [arg0]
|
|
3891
4628
|
*/
|
|
3892
4629
|
set pointFacing(arg0) {
|
|
@@ -3895,9 +4632,21 @@ export class PointMaterial {
|
|
|
3895
4632
|
wasm.__wbg_set_pointmaterial_pointFacing(this.__wbg_ptr, ptr0, len0);
|
|
3896
4633
|
}
|
|
3897
4634
|
/**
|
|
3898
|
-
*
|
|
3899
|
-
*
|
|
3900
|
-
*
|
|
4635
|
+
* Add the line's tangent bearing at the anchor to `rotation`, so the
|
|
4636
|
+
* sprite turns with the line it sits on. Defaults to `true`.
|
|
4637
|
+
* @param {boolean | null} [arg0]
|
|
4638
|
+
*/
|
|
4639
|
+
set rotateToLine(arg0) {
|
|
4640
|
+
wasm.__wbg_set_pointmaterial_rotateToLine(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4641
|
+
}
|
|
4642
|
+
/**
|
|
4643
|
+
* Whether the point turns with the camera or with the map, as MapLibre's
|
|
4644
|
+
* `icon-rotation-alignment` `viewport` and `map`. `true` keeps it reading left to right
|
|
4645
|
+
* (a screen-aligned billboard, or a flat quad yawed to the camera).
|
|
4646
|
+
* `false` aligns it with the map: upright, it stays on screen but turns
|
|
4647
|
+
* with the camera heading so its x-axis points east; flat, it lies
|
|
4648
|
+
* north-up. Left unset, it is `true` for `placement: "point"` and `false`
|
|
4649
|
+
* along a line, as MapLibre resolves `auto`.
|
|
3901
4650
|
* @param {boolean | null} [arg0]
|
|
3902
4651
|
*/
|
|
3903
4652
|
set rotateWithCamera(arg0) {
|
|
@@ -3905,7 +4654,7 @@ export class PointMaterial {
|
|
|
3905
4654
|
}
|
|
3906
4655
|
/**
|
|
3907
4656
|
* Rotation of the point within its own plane, about its anchor point, in
|
|
3908
|
-
* degrees, clockwise seen from the front. `
|
|
4657
|
+
* degrees, clockwise seen from the front. `anchor` decides where inside
|
|
3909
4658
|
* the quad the pivot sits. Defaults to `0.0`.
|
|
3910
4659
|
* @param {number | null} [arg0]
|
|
3911
4660
|
*/
|
|
@@ -3933,12 +4682,52 @@ export class PointMaterial {
|
|
|
3933
4682
|
wasm.__wbg_set_pointmaterial_size(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3934
4683
|
}
|
|
3935
4684
|
/**
|
|
3936
|
-
*
|
|
4685
|
+
* Distance between repeated anchors along a line, in screen pixels, for
|
|
4686
|
+
* `vector-tile` and `geojson` sources alike. Resolved per anchor as the
|
|
4687
|
+
* camera moves: anchors thin out as it pulls back and fill in as it
|
|
4688
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
4689
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
4690
|
+
* `symbol-spacing`, a sprite wider than three quarters of the spacing
|
|
4691
|
+
* spreads its repeats to its width plus a quarter of the spacing, and a
|
|
4692
|
+
* vector tile places anchors only inside its own bounds. Only used by
|
|
4693
|
+
* `placement: "line"`. Defaults to `250.0`.
|
|
4694
|
+
* @param {number | null} [arg0]
|
|
3937
4695
|
*/
|
|
3938
|
-
set
|
|
3939
|
-
wasm.
|
|
4696
|
+
set spacing(arg0) {
|
|
4697
|
+
wasm.__wbg_set_pointmaterial_spacing(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3940
4698
|
}
|
|
3941
|
-
|
|
4699
|
+
/**
|
|
4700
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
4701
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
4702
|
+
* the screen axes. MapLibre's `icon-translate-anchor`.
|
|
4703
|
+
* @param {string | null} [arg0]
|
|
4704
|
+
*/
|
|
4705
|
+
set translateAnchor(arg0) {
|
|
4706
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4707
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4708
|
+
wasm.__wbg_set_pointmaterial_translateAnchor(this.__wbg_ptr, ptr0, len0);
|
|
4709
|
+
}
|
|
4710
|
+
/**
|
|
4711
|
+
* Screen-pixel shift of the drawn quad, x right and y down, applied after
|
|
4712
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
4713
|
+
* MapLibre's `icon-translate`. Defaults to `(0, 0)`.
|
|
4714
|
+
* @param {Vec2 | null} [arg0]
|
|
4715
|
+
*/
|
|
4716
|
+
set translate(arg0) {
|
|
4717
|
+
let ptr0 = 0;
|
|
4718
|
+
if (!isLikeNone(arg0)) {
|
|
4719
|
+
_assertClass(arg0, Vec2);
|
|
4720
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
4721
|
+
}
|
|
4722
|
+
wasm.__wbg_set_pointmaterial_translate(this.__wbg_ptr, ptr0);
|
|
4723
|
+
}
|
|
4724
|
+
/**
|
|
4725
|
+
* @param {boolean | null} [arg0]
|
|
4726
|
+
*/
|
|
4727
|
+
set transparent(arg0) {
|
|
4728
|
+
wasm.__wbg_set_pointmaterial_transparent(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4729
|
+
}
|
|
4730
|
+
}
|
|
3942
4731
|
if (Symbol.dispose) PointMaterial.prototype[Symbol.dispose] = PointMaterial.prototype.free;
|
|
3943
4732
|
|
|
3944
4733
|
export class PolygonGeometry {
|
|
@@ -4227,13 +5016,6 @@ export class PolygonMaterial {
|
|
|
4227
5016
|
const ret = wasm.__wbg_get_polygonmaterial___internal__(this.__wbg_ptr);
|
|
4228
5017
|
return ret === 0 ? undefined : PolygonInternalMaterial.__wrap(ret);
|
|
4229
5018
|
}
|
|
4230
|
-
/**
|
|
4231
|
-
* @returns {boolean | undefined}
|
|
4232
|
-
*/
|
|
4233
|
-
get applyWaterNormal() {
|
|
4234
|
-
const ret = wasm.__wbg_get_polygonmaterial_applyWaterNormal(this.__wbg_ptr);
|
|
4235
|
-
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4236
|
-
}
|
|
4237
5019
|
/**
|
|
4238
5020
|
* @returns {boolean | undefined}
|
|
4239
5021
|
*/
|
|
@@ -4255,6 +5037,14 @@ export class PolygonMaterial {
|
|
|
4255
5037
|
const ret = wasm.__wbg_get_polygonmaterial_color(this.__wbg_ptr);
|
|
4256
5038
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4257
5039
|
}
|
|
5040
|
+
/**
|
|
5041
|
+
* Write depth before blending so a transparent layer blends only its nearest surface.
|
|
5042
|
+
* @returns {boolean | undefined}
|
|
5043
|
+
*/
|
|
5044
|
+
get depthPrePass() {
|
|
5045
|
+
const ret = wasm.__wbg_get_polygonmaterial_depthPrePass(this.__wbg_ptr);
|
|
5046
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5047
|
+
}
|
|
4258
5048
|
/**
|
|
4259
5049
|
* IDs of selective effects to apply (e.g., "bloom", "outline")
|
|
4260
5050
|
* @returns {string[] | undefined}
|
|
@@ -4291,6 +5081,15 @@ export class PolygonMaterial {
|
|
|
4291
5081
|
const ret = wasm.__wbg_get_polygonmaterial_extrudedHeight(this.__wbg_ptr);
|
|
4292
5082
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4293
5083
|
}
|
|
5084
|
+
/**
|
|
5085
|
+
* Speed in m/s of the current carrying the water's waves
|
|
5086
|
+
* along `waveDirection`. Default: 0.
|
|
5087
|
+
* @returns {number | undefined}
|
|
5088
|
+
*/
|
|
5089
|
+
get flowSpeed() {
|
|
5090
|
+
const ret = wasm.__wbg_get_polygonmaterial_flowSpeed(this.__wbg_ptr);
|
|
5091
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
5092
|
+
}
|
|
4294
5093
|
/**
|
|
4295
5094
|
* @returns {number | undefined}
|
|
4296
5095
|
*/
|
|
@@ -4388,6 +5187,15 @@ export class PolygonMaterial {
|
|
|
4388
5187
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4389
5188
|
}
|
|
4390
5189
|
/**
|
|
5190
|
+
* Shade the extruded sides with the surface normal instead of their own.
|
|
5191
|
+
* @returns {boolean | undefined}
|
|
5192
|
+
*/
|
|
5193
|
+
get shadeSidesAsSurface() {
|
|
5194
|
+
const ret = wasm.__wbg_get_polygonmaterial_shadeSidesAsSurface(this.__wbg_ptr);
|
|
5195
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5196
|
+
}
|
|
5197
|
+
/**
|
|
5198
|
+
* Phong shininess of the non-water `specular` highlight.
|
|
4391
5199
|
* @returns {number | undefined}
|
|
4392
5200
|
*/
|
|
4393
5201
|
get shininess() {
|
|
@@ -4410,6 +5218,7 @@ export class PolygonMaterial {
|
|
|
4410
5218
|
}
|
|
4411
5219
|
/**
|
|
4412
5220
|
* Enabling this value allows using `shininess` and `specular_strength`.
|
|
5221
|
+
* Has no effect on water.
|
|
4413
5222
|
* @returns {boolean | undefined}
|
|
4414
5223
|
*/
|
|
4415
5224
|
get specular() {
|
|
@@ -4446,28 +5255,54 @@ export class PolygonMaterial {
|
|
|
4446
5255
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4447
5256
|
}
|
|
4448
5257
|
/**
|
|
4449
|
-
*
|
|
5258
|
+
* Extent of the water body, which bounds how far the wind blows over it
|
|
5259
|
+
* and so how large its waves grow: `"ocean"` (the default; open sea),
|
|
5260
|
+
* `"large"` (a bay or a large lake, about 20 km), `"medium"` (a lake or a
|
|
5261
|
+
* wide river, about 2 km) or `"small"` (a river or a pond, about 200 m).
|
|
5262
|
+
* @returns {string | undefined}
|
|
5263
|
+
*/
|
|
5264
|
+
get waterScale() {
|
|
5265
|
+
const ret = wasm.__wbg_get_polygonmaterial_waterScale(this.__wbg_ptr);
|
|
5266
|
+
let v1;
|
|
5267
|
+
if (ret[0] !== 0) {
|
|
5268
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
5269
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
5270
|
+
}
|
|
5271
|
+
return v1;
|
|
5272
|
+
}
|
|
5273
|
+
/**
|
|
5274
|
+
* Apply a water material on the polygon. It might slow down the loading of the mesh.
|
|
5275
|
+
* @returns {boolean | undefined}
|
|
5276
|
+
*/
|
|
5277
|
+
get water() {
|
|
5278
|
+
const ret = wasm.__wbg_get_polygonmaterial_water(this.__wbg_ptr);
|
|
5279
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5280
|
+
}
|
|
5281
|
+
/**
|
|
5282
|
+
* Where the water's waves travel, in degrees clockwise from north.
|
|
5283
|
+
* Default: 0.
|
|
4450
5284
|
* @returns {number | undefined}
|
|
4451
5285
|
*/
|
|
4452
|
-
get
|
|
4453
|
-
const ret = wasm.
|
|
5286
|
+
get waveDirection() {
|
|
5287
|
+
const ret = wasm.__wbg_get_polygonmaterial_waveDirection(this.__wbg_ptr);
|
|
4454
5288
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4455
5289
|
}
|
|
4456
5290
|
/**
|
|
4457
|
-
*
|
|
5291
|
+
* Scales the water's wave slopes; 0 is a flat mirror.
|
|
4458
5292
|
* @returns {number | undefined}
|
|
4459
5293
|
*/
|
|
4460
|
-
get
|
|
4461
|
-
const ret = wasm.
|
|
5294
|
+
get waveExaggeration() {
|
|
5295
|
+
const ret = wasm.__wbg_get_polygonmaterial_waveExaggeration(this.__wbg_ptr);
|
|
4462
5296
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4463
5297
|
}
|
|
4464
5298
|
/**
|
|
4465
|
-
*
|
|
4466
|
-
*
|
|
5299
|
+
* Sets the size, steepness and speed of the water's waves: about 1 is a
|
|
5300
|
+
* calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
5301
|
+
* @returns {number | undefined}
|
|
4467
5302
|
*/
|
|
4468
|
-
get
|
|
4469
|
-
const ret = wasm.
|
|
4470
|
-
return ret ===
|
|
5303
|
+
get waveStrength() {
|
|
5304
|
+
const ret = wasm.__wbg_get_polygonmaterial_waveStrength(this.__wbg_ptr);
|
|
5305
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4471
5306
|
}
|
|
4472
5307
|
/**
|
|
4473
5308
|
* @returns {boolean | undefined}
|
|
@@ -4512,12 +5347,6 @@ export class PolygonMaterial {
|
|
|
4512
5347
|
}
|
|
4513
5348
|
wasm.__wbg_set_polygonmaterial___internal__(this.__wbg_ptr, ptr0);
|
|
4514
5349
|
}
|
|
4515
|
-
/**
|
|
4516
|
-
* @param {boolean | null} [arg0]
|
|
4517
|
-
*/
|
|
4518
|
-
set applyWaterNormal(arg0) {
|
|
4519
|
-
wasm.__wbg_set_polygonmaterial_applyWaterNormal(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4520
|
-
}
|
|
4521
5350
|
/**
|
|
4522
5351
|
* @param {boolean | null} [arg0]
|
|
4523
5352
|
*/
|
|
@@ -4536,6 +5365,13 @@ export class PolygonMaterial {
|
|
|
4536
5365
|
set color(arg0) {
|
|
4537
5366
|
wasm.__wbg_set_polygonmaterial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
4538
5367
|
}
|
|
5368
|
+
/**
|
|
5369
|
+
* Write depth before blending so a transparent layer blends only its nearest surface.
|
|
5370
|
+
* @param {boolean | null} [arg0]
|
|
5371
|
+
*/
|
|
5372
|
+
set depthPrePass(arg0) {
|
|
5373
|
+
wasm.__wbg_set_polygonmaterial_depthPrePass(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
5374
|
+
}
|
|
4539
5375
|
/**
|
|
4540
5376
|
* IDs of selective effects to apply (e.g., "bloom", "outline")
|
|
4541
5377
|
* @param {string[] | null} [arg0]
|
|
@@ -4565,6 +5401,14 @@ export class PolygonMaterial {
|
|
|
4565
5401
|
set extrudedHeight(arg0) {
|
|
4566
5402
|
wasm.__wbg_set_polygonmaterial_extrudedHeight(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4567
5403
|
}
|
|
5404
|
+
/**
|
|
5405
|
+
* Speed in m/s of the current carrying the water's waves
|
|
5406
|
+
* along `waveDirection`. Default: 0.
|
|
5407
|
+
* @param {number | null} [arg0]
|
|
5408
|
+
*/
|
|
5409
|
+
set flowSpeed(arg0) {
|
|
5410
|
+
wasm.__wbg_set_polygonmaterial_flowSpeed(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
5411
|
+
}
|
|
4568
5412
|
/**
|
|
4569
5413
|
* @param {number | null} [arg0]
|
|
4570
5414
|
*/
|
|
@@ -4650,6 +5494,14 @@ export class PolygonMaterial {
|
|
|
4650
5494
|
wasm.__wbg_set_polygonmaterial_roughness(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4651
5495
|
}
|
|
4652
5496
|
/**
|
|
5497
|
+
* Shade the extruded sides with the surface normal instead of their own.
|
|
5498
|
+
* @param {boolean | null} [arg0]
|
|
5499
|
+
*/
|
|
5500
|
+
set shadeSidesAsSurface(arg0) {
|
|
5501
|
+
wasm.__wbg_set_polygonmaterial_shadeSidesAsSurface(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
5502
|
+
}
|
|
5503
|
+
/**
|
|
5504
|
+
* Phong shininess of the non-water `specular` highlight.
|
|
4653
5505
|
* @param {number | null} [arg0]
|
|
4654
5506
|
*/
|
|
4655
5507
|
set shininess(arg0) {
|
|
@@ -4669,6 +5521,7 @@ export class PolygonMaterial {
|
|
|
4669
5521
|
}
|
|
4670
5522
|
/**
|
|
4671
5523
|
* Enabling this value allows using `shininess` and `specular_strength`.
|
|
5524
|
+
* Has no effect on water.
|
|
4672
5525
|
* @param {boolean | null} [arg0]
|
|
4673
5526
|
*/
|
|
4674
5527
|
set specular(arg0) {
|
|
@@ -4701,25 +5554,46 @@ export class PolygonMaterial {
|
|
|
4701
5554
|
wasm.__wbg_set_polygonmaterial_transparent(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4702
5555
|
}
|
|
4703
5556
|
/**
|
|
4704
|
-
*
|
|
5557
|
+
* Extent of the water body, which bounds how far the wind blows over it
|
|
5558
|
+
* and so how large its waves grow: `"ocean"` (the default; open sea),
|
|
5559
|
+
* `"large"` (a bay or a large lake, about 20 km), `"medium"` (a lake or a
|
|
5560
|
+
* wide river, about 2 km) or `"small"` (a river or a pond, about 200 m).
|
|
5561
|
+
* @param {string | null} [arg0]
|
|
5562
|
+
*/
|
|
5563
|
+
set waterScale(arg0) {
|
|
5564
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
5565
|
+
var len0 = WASM_VECTOR_LEN;
|
|
5566
|
+
wasm.__wbg_set_polygonmaterial_waterScale(this.__wbg_ptr, ptr0, len0);
|
|
5567
|
+
}
|
|
5568
|
+
/**
|
|
5569
|
+
* Apply a water material on the polygon. It might slow down the loading of the mesh.
|
|
5570
|
+
* @param {boolean | null} [arg0]
|
|
5571
|
+
*/
|
|
5572
|
+
set water(arg0) {
|
|
5573
|
+
wasm.__wbg_set_polygonmaterial_water(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
5574
|
+
}
|
|
5575
|
+
/**
|
|
5576
|
+
* Where the water's waves travel, in degrees clockwise from north.
|
|
5577
|
+
* Default: 0.
|
|
4705
5578
|
* @param {number | null} [arg0]
|
|
4706
5579
|
*/
|
|
4707
|
-
set
|
|
4708
|
-
wasm.
|
|
5580
|
+
set waveDirection(arg0) {
|
|
5581
|
+
wasm.__wbg_set_polygonmaterial_waveDirection(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4709
5582
|
}
|
|
4710
5583
|
/**
|
|
4711
|
-
*
|
|
5584
|
+
* Scales the water's wave slopes; 0 is a flat mirror.
|
|
4712
5585
|
* @param {number | null} [arg0]
|
|
4713
5586
|
*/
|
|
4714
|
-
set
|
|
4715
|
-
wasm.
|
|
5587
|
+
set waveExaggeration(arg0) {
|
|
5588
|
+
wasm.__wbg_set_polygonmaterial_waveExaggeration(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4716
5589
|
}
|
|
4717
5590
|
/**
|
|
4718
|
-
*
|
|
4719
|
-
*
|
|
5591
|
+
* Sets the size, steepness and speed of the water's waves: about 1 is a
|
|
5592
|
+
* calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
5593
|
+
* @param {number | null} [arg0]
|
|
4720
5594
|
*/
|
|
4721
|
-
set
|
|
4722
|
-
wasm.
|
|
5595
|
+
set waveStrength(arg0) {
|
|
5596
|
+
wasm.__wbg_set_polygonmaterial_waveStrength(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4723
5597
|
}
|
|
4724
5598
|
/**
|
|
4725
5599
|
* @param {boolean | null} [arg0]
|
|
@@ -4800,15 +5674,15 @@ export class PolylineGeometry {
|
|
|
4800
5674
|
/**
|
|
4801
5675
|
* @returns {Float32Array | undefined}
|
|
4802
5676
|
*/
|
|
4803
|
-
|
|
4804
|
-
const ret = wasm.
|
|
5677
|
+
end_normal_and_segment_length() {
|
|
5678
|
+
const ret = wasm.polylinegeometry_end_normal_and_segment_length(this.__wbg_ptr);
|
|
4805
5679
|
return ret;
|
|
4806
5680
|
}
|
|
4807
5681
|
/**
|
|
4808
5682
|
* @returns {number | undefined}
|
|
4809
5683
|
*/
|
|
4810
|
-
|
|
4811
|
-
const ret = wasm.
|
|
5684
|
+
end_normal_and_segment_length_size() {
|
|
5685
|
+
const ret = wasm.polylinegeometry_end_normal_and_segment_length_size(this.__wbg_ptr);
|
|
4812
5686
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
4813
5687
|
}
|
|
4814
5688
|
/**
|
|
@@ -4832,6 +5706,20 @@ export class PolylineGeometry {
|
|
|
4832
5706
|
const ret = wasm.polylinegeometry_indices(this.__wbg_ptr);
|
|
4833
5707
|
return ret;
|
|
4834
5708
|
}
|
|
5709
|
+
/**
|
|
5710
|
+
* @returns {Float32Array | undefined}
|
|
5711
|
+
*/
|
|
5712
|
+
line_distance_and_ends() {
|
|
5713
|
+
const ret = wasm.polylinegeometry_line_distance_and_ends(this.__wbg_ptr);
|
|
5714
|
+
return ret;
|
|
5715
|
+
}
|
|
5716
|
+
/**
|
|
5717
|
+
* @returns {Float32Array | undefined}
|
|
5718
|
+
*/
|
|
5719
|
+
line_segments() {
|
|
5720
|
+
const ret = wasm.polylinegeometry_line_segments(this.__wbg_ptr);
|
|
5721
|
+
return ret;
|
|
5722
|
+
}
|
|
4835
5723
|
/**
|
|
4836
5724
|
* @returns {Float32Array}
|
|
4837
5725
|
*/
|
|
@@ -4877,15 +5765,15 @@ export class PolylineGeometry {
|
|
|
4877
5765
|
/**
|
|
4878
5766
|
* @returns {Float32Array}
|
|
4879
5767
|
*/
|
|
4880
|
-
|
|
4881
|
-
const ret = wasm.
|
|
5768
|
+
right_normal_and_line_length() {
|
|
5769
|
+
const ret = wasm.polylinegeometry_right_normal_and_line_length(this.__wbg_ptr);
|
|
4882
5770
|
return ret;
|
|
4883
5771
|
}
|
|
4884
5772
|
/**
|
|
4885
5773
|
* @returns {number}
|
|
4886
5774
|
*/
|
|
4887
|
-
|
|
4888
|
-
const ret = wasm.
|
|
5775
|
+
right_normal_and_line_length_size() {
|
|
5776
|
+
const ret = wasm.polylinegeometry_right_normal_and_line_length_size(this.__wbg_ptr);
|
|
4889
5777
|
return ret;
|
|
4890
5778
|
}
|
|
4891
5779
|
/**
|
|
@@ -4926,15 +5814,15 @@ export class PolylineGeometry {
|
|
|
4926
5814
|
/**
|
|
4927
5815
|
* @returns {Float32Array | undefined}
|
|
4928
5816
|
*/
|
|
4929
|
-
|
|
4930
|
-
const ret = wasm.
|
|
5817
|
+
start_normal_and_length_high() {
|
|
5818
|
+
const ret = wasm.polylinegeometry_start_normal_and_length_high(this.__wbg_ptr);
|
|
4931
5819
|
return ret;
|
|
4932
5820
|
}
|
|
4933
5821
|
/**
|
|
4934
5822
|
* @returns {number | undefined}
|
|
4935
5823
|
*/
|
|
4936
|
-
|
|
4937
|
-
const ret = wasm.
|
|
5824
|
+
start_normal_and_length_high_size() {
|
|
5825
|
+
const ret = wasm.polylinegeometry_start_normal_and_length_high_size(this.__wbg_ptr);
|
|
4938
5826
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
4939
5827
|
}
|
|
4940
5828
|
/**
|
|
@@ -5017,15 +5905,15 @@ export class PolylineGeometryAttributes {
|
|
|
5017
5905
|
/**
|
|
5018
5906
|
* @returns {Float32Array | undefined}
|
|
5019
5907
|
*/
|
|
5020
|
-
|
|
5021
|
-
const ret = wasm.
|
|
5908
|
+
transfer_end_normal_and_segment_length() {
|
|
5909
|
+
const ret = wasm.polylinegeometryattributes_transfer_end_normal_and_segment_length(this.__wbg_ptr);
|
|
5022
5910
|
return ret;
|
|
5023
5911
|
}
|
|
5024
5912
|
/**
|
|
5025
5913
|
* @returns {number | undefined}
|
|
5026
5914
|
*/
|
|
5027
|
-
|
|
5028
|
-
const ret = wasm.
|
|
5915
|
+
transfer_end_normal_and_segment_length_size() {
|
|
5916
|
+
const ret = wasm.polylinegeometryattributes_transfer_end_normal_and_segment_length_size(this.__wbg_ptr);
|
|
5029
5917
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
5030
5918
|
}
|
|
5031
5919
|
/**
|
|
@@ -5042,6 +5930,20 @@ export class PolylineGeometryAttributes {
|
|
|
5042
5930
|
const ret = wasm.polylinegeometryattributes_transfer_forward_offset_size(this.__wbg_ptr);
|
|
5043
5931
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
5044
5932
|
}
|
|
5933
|
+
/**
|
|
5934
|
+
* @returns {Float32Array | undefined}
|
|
5935
|
+
*/
|
|
5936
|
+
transfer_line_distance_and_ends() {
|
|
5937
|
+
const ret = wasm.polylinegeometryattributes_transfer_line_distance_and_ends(this.__wbg_ptr);
|
|
5938
|
+
return ret;
|
|
5939
|
+
}
|
|
5940
|
+
/**
|
|
5941
|
+
* @returns {Float32Array | undefined}
|
|
5942
|
+
*/
|
|
5943
|
+
transfer_line_segments() {
|
|
5944
|
+
const ret = wasm.polylinegeometryattributes_transfer_line_segments(this.__wbg_ptr);
|
|
5945
|
+
return ret;
|
|
5946
|
+
}
|
|
5045
5947
|
/**
|
|
5046
5948
|
* @returns {Float32Array}
|
|
5047
5949
|
*/
|
|
@@ -5087,15 +5989,15 @@ export class PolylineGeometryAttributes {
|
|
|
5087
5989
|
/**
|
|
5088
5990
|
* @returns {Float32Array}
|
|
5089
5991
|
*/
|
|
5090
|
-
|
|
5091
|
-
const ret = wasm.
|
|
5992
|
+
transfer_right_normal_and_line_length() {
|
|
5993
|
+
const ret = wasm.polylinegeometryattributes_transfer_right_normal_and_line_length(this.__wbg_ptr);
|
|
5092
5994
|
return ret;
|
|
5093
5995
|
}
|
|
5094
5996
|
/**
|
|
5095
5997
|
* @returns {number}
|
|
5096
5998
|
*/
|
|
5097
|
-
|
|
5098
|
-
const ret = wasm.
|
|
5999
|
+
transfer_right_normal_and_line_length_size() {
|
|
6000
|
+
const ret = wasm.polylinegeometryattributes_transfer_right_normal_and_line_length_size(this.__wbg_ptr);
|
|
5099
6001
|
return ret;
|
|
5100
6002
|
}
|
|
5101
6003
|
/**
|
|
@@ -5136,15 +6038,15 @@ export class PolylineGeometryAttributes {
|
|
|
5136
6038
|
/**
|
|
5137
6039
|
* @returns {Float32Array | undefined}
|
|
5138
6040
|
*/
|
|
5139
|
-
|
|
5140
|
-
const ret = wasm.
|
|
6041
|
+
transfer_start_normal_and_length_high() {
|
|
6042
|
+
const ret = wasm.polylinegeometryattributes_transfer_start_normal_and_length_high(this.__wbg_ptr);
|
|
5141
6043
|
return ret;
|
|
5142
6044
|
}
|
|
5143
6045
|
/**
|
|
5144
6046
|
* @returns {number | undefined}
|
|
5145
6047
|
*/
|
|
5146
|
-
|
|
5147
|
-
const ret = wasm.
|
|
6048
|
+
transfer_start_normal_and_length_high_size() {
|
|
6049
|
+
const ret = wasm.polylinegeometryattributes_transfer_start_normal_and_length_high_size(this.__wbg_ptr);
|
|
5148
6050
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
5149
6051
|
}
|
|
5150
6052
|
/**
|
|
@@ -5212,6 +6114,23 @@ export class PolylineMaterial {
|
|
|
5212
6114
|
const ret = wasm.__wbg_get_polylinematerial___internal__(this.__wbg_ptr);
|
|
5213
6115
|
return ret === 0 ? undefined : PolylineInternalMaterial.__wrap(ret);
|
|
5214
6116
|
}
|
|
6117
|
+
/**
|
|
6118
|
+
* Shape of the ends of the line and of its dashes: `"butt"` (the
|
|
6119
|
+
* default), `"round"` or `"square"`. `"round"` adds a half circle one
|
|
6120
|
+
* half line width in radius beyond both ends of the line and of every
|
|
6121
|
+
* dash, so a zero-length dash becomes a dot. `"square"` extends the ends
|
|
6122
|
+
* of the line by half a line width and leaves the dashes' ends square.
|
|
6123
|
+
* @returns {string | undefined}
|
|
6124
|
+
*/
|
|
6125
|
+
get cap() {
|
|
6126
|
+
const ret = wasm.__wbg_get_polylinematerial_cap(this.__wbg_ptr);
|
|
6127
|
+
let v1;
|
|
6128
|
+
if (ret[0] !== 0) {
|
|
6129
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
6130
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
6131
|
+
}
|
|
6132
|
+
return v1;
|
|
6133
|
+
}
|
|
5215
6134
|
/**
|
|
5216
6135
|
* @returns {boolean | undefined}
|
|
5217
6136
|
*/
|
|
@@ -5233,6 +6152,22 @@ export class PolylineMaterial {
|
|
|
5233
6152
|
const ret = wasm.__wbg_get_polylinematerial_color(this.__wbg_ptr);
|
|
5234
6153
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
5235
6154
|
}
|
|
6155
|
+
/**
|
|
6156
|
+
* Alternating dash and gap lengths, in multiples of the line width,
|
|
6157
|
+
* repeated along the line. The pattern's period is the sum of the
|
|
6158
|
+
* entries, so an odd-length array ends in a dash that runs into the first
|
|
6159
|
+
* one. An empty array draws a solid line, which is the default.
|
|
6160
|
+
* @returns {Float32Array | undefined}
|
|
6161
|
+
*/
|
|
6162
|
+
get dashArray() {
|
|
6163
|
+
const ret = wasm.__wbg_get_polylinematerial_dashArray(this.__wbg_ptr);
|
|
6164
|
+
let v1;
|
|
6165
|
+
if (ret[0] !== 0) {
|
|
6166
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
6167
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
6168
|
+
}
|
|
6169
|
+
return v1;
|
|
6170
|
+
}
|
|
5236
6171
|
/**
|
|
5237
6172
|
* Enable writing to depth buffer
|
|
5238
6173
|
* @returns {boolean | undefined}
|
|
@@ -5396,6 +6331,19 @@ export class PolylineMaterial {
|
|
|
5396
6331
|
}
|
|
5397
6332
|
wasm.__wbg_set_polylinematerial___internal__(this.__wbg_ptr, ptr0);
|
|
5398
6333
|
}
|
|
6334
|
+
/**
|
|
6335
|
+
* Shape of the ends of the line and of its dashes: `"butt"` (the
|
|
6336
|
+
* default), `"round"` or `"square"`. `"round"` adds a half circle one
|
|
6337
|
+
* half line width in radius beyond both ends of the line and of every
|
|
6338
|
+
* dash, so a zero-length dash becomes a dot. `"square"` extends the ends
|
|
6339
|
+
* of the line by half a line width and leaves the dashes' ends square.
|
|
6340
|
+
* @param {string | null} [arg0]
|
|
6341
|
+
*/
|
|
6342
|
+
set cap(arg0) {
|
|
6343
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
6344
|
+
var len0 = WASM_VECTOR_LEN;
|
|
6345
|
+
wasm.__wbg_set_polylinematerial_cap(this.__wbg_ptr, ptr0, len0);
|
|
6346
|
+
}
|
|
5399
6347
|
/**
|
|
5400
6348
|
* @param {boolean | null} [arg0]
|
|
5401
6349
|
*/
|
|
@@ -5414,6 +6362,18 @@ export class PolylineMaterial {
|
|
|
5414
6362
|
set color(arg0) {
|
|
5415
6363
|
wasm.__wbg_set_polylinematerial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
5416
6364
|
}
|
|
6365
|
+
/**
|
|
6366
|
+
* Alternating dash and gap lengths, in multiples of the line width,
|
|
6367
|
+
* repeated along the line. The pattern's period is the sum of the
|
|
6368
|
+
* entries, so an odd-length array ends in a dash that runs into the first
|
|
6369
|
+
* one. An empty array draws a solid line, which is the default.
|
|
6370
|
+
* @param {Float32Array | null} [arg0]
|
|
6371
|
+
*/
|
|
6372
|
+
set dashArray(arg0) {
|
|
6373
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6374
|
+
var len0 = WASM_VECTOR_LEN;
|
|
6375
|
+
wasm.__wbg_set_polylinematerial_dashArray(this.__wbg_ptr, ptr0, len0);
|
|
6376
|
+
}
|
|
5417
6377
|
/**
|
|
5418
6378
|
* Enable writing to depth buffer
|
|
5419
6379
|
* @param {boolean | null} [arg0]
|
|
@@ -5615,6 +6575,17 @@ export class RasterTileInternalMaterial {
|
|
|
5615
6575
|
const ret = wasm.__wbg_get_rastertileinternalmaterial_castShadow(this.__wbg_ptr);
|
|
5616
6576
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5617
6577
|
}
|
|
6578
|
+
/**
|
|
6579
|
+
* Per-slot layer IDs used to look up each layer's colorMap atlas row; an
|
|
6580
|
+
* empty string for slots without an elevation heatmap.
|
|
6581
|
+
* @returns {string[]}
|
|
6582
|
+
*/
|
|
6583
|
+
get colorMapLayerIds() {
|
|
6584
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_colorMapLayerIds(this.__wbg_ptr);
|
|
6585
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
6586
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
6587
|
+
return v1;
|
|
6588
|
+
}
|
|
5618
6589
|
/**
|
|
5619
6590
|
* @returns {Uint32Array}
|
|
5620
6591
|
*/
|
|
@@ -5625,73 +6596,115 @@ export class RasterTileInternalMaterial {
|
|
|
5625
6596
|
return v1;
|
|
5626
6597
|
}
|
|
5627
6598
|
/**
|
|
5628
|
-
* @returns {
|
|
6599
|
+
* @returns {Float64Array}
|
|
5629
6600
|
*/
|
|
5630
|
-
get
|
|
5631
|
-
const ret = wasm.
|
|
5632
|
-
|
|
6601
|
+
get elevationBScalers() {
|
|
6602
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationBScalers(this.__wbg_ptr);
|
|
6603
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6604
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6605
|
+
return v1;
|
|
5633
6606
|
}
|
|
5634
6607
|
/**
|
|
5635
|
-
* @returns {
|
|
6608
|
+
* @returns {Float64Array}
|
|
5636
6609
|
*/
|
|
5637
|
-
get
|
|
5638
|
-
const ret = wasm.
|
|
5639
|
-
|
|
6610
|
+
get elevationBoundaries() {
|
|
6611
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationBoundaries(this.__wbg_ptr);
|
|
6612
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6613
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6614
|
+
return v1;
|
|
5640
6615
|
}
|
|
5641
6616
|
/**
|
|
5642
|
-
* @returns {
|
|
6617
|
+
* @returns {Float64Array}
|
|
5643
6618
|
*/
|
|
5644
|
-
get
|
|
5645
|
-
const ret = wasm.
|
|
5646
|
-
|
|
6619
|
+
get elevationEpsilons() {
|
|
6620
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationEpsilons(this.__wbg_ptr);
|
|
6621
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6622
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6623
|
+
return v1;
|
|
5647
6624
|
}
|
|
5648
6625
|
/**
|
|
5649
|
-
* @returns {
|
|
6626
|
+
* @returns {Float64Array}
|
|
5650
6627
|
*/
|
|
5651
|
-
get
|
|
5652
|
-
const ret = wasm.
|
|
5653
|
-
|
|
6628
|
+
get elevationGScalers() {
|
|
6629
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationGScalers(this.__wbg_ptr);
|
|
6630
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6631
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6632
|
+
return v1;
|
|
5654
6633
|
}
|
|
5655
6634
|
/**
|
|
5656
|
-
*
|
|
6635
|
+
* Per-layer filter modes: "linear" or "nearest"
|
|
6636
|
+
* @returns {string[]}
|
|
5657
6637
|
*/
|
|
5658
|
-
get
|
|
5659
|
-
const ret = wasm.
|
|
5660
|
-
|
|
6638
|
+
get elevationHeatmapFilters() {
|
|
6639
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationHeatmapFilters(this.__wbg_ptr);
|
|
6640
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
6641
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
6642
|
+
return v1;
|
|
5661
6643
|
}
|
|
5662
6644
|
/**
|
|
5663
|
-
*
|
|
6645
|
+
* Per-layer maximum heights for elevation normalization
|
|
6646
|
+
* @returns {Float64Array}
|
|
5664
6647
|
*/
|
|
5665
|
-
get
|
|
5666
|
-
const ret = wasm.
|
|
5667
|
-
|
|
6648
|
+
get elevationMaxHeights() {
|
|
6649
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationMaxHeights(this.__wbg_ptr);
|
|
6650
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6651
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6652
|
+
return v1;
|
|
5668
6653
|
}
|
|
5669
6654
|
/**
|
|
5670
|
-
* @returns {
|
|
6655
|
+
* @returns {Float64Array}
|
|
5671
6656
|
*/
|
|
5672
|
-
get
|
|
5673
|
-
const ret = wasm.
|
|
5674
|
-
|
|
6657
|
+
get elevationMaxOffsets() {
|
|
6658
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationMaxOffsets(this.__wbg_ptr);
|
|
6659
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6660
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6661
|
+
return v1;
|
|
5675
6662
|
}
|
|
5676
6663
|
/**
|
|
5677
|
-
*
|
|
6664
|
+
* Per-layer minimum heights for elevation normalization
|
|
6665
|
+
* @returns {Float64Array}
|
|
5678
6666
|
*/
|
|
5679
|
-
get
|
|
5680
|
-
const ret = wasm.
|
|
5681
|
-
|
|
6667
|
+
get elevationMinHeights() {
|
|
6668
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationMinHeights(this.__wbg_ptr);
|
|
6669
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6670
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6671
|
+
return v1;
|
|
5682
6672
|
}
|
|
5683
6673
|
/**
|
|
5684
|
-
* @returns {
|
|
6674
|
+
* @returns {Float64Array}
|
|
5685
6675
|
*/
|
|
5686
|
-
get
|
|
5687
|
-
const ret = wasm.
|
|
5688
|
-
|
|
6676
|
+
get elevationMinOffsets() {
|
|
6677
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationMinOffsets(this.__wbg_ptr);
|
|
6678
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6679
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6680
|
+
return v1;
|
|
5689
6681
|
}
|
|
5690
6682
|
/**
|
|
6683
|
+
* @returns {Float64Array}
|
|
6684
|
+
*/
|
|
6685
|
+
get elevationOffsets() {
|
|
6686
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationOffsets(this.__wbg_ptr);
|
|
6687
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6688
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6689
|
+
return v1;
|
|
6690
|
+
}
|
|
6691
|
+
/**
|
|
6692
|
+
* Per-layer DEM decoder parameters
|
|
6693
|
+
* @returns {Float64Array}
|
|
6694
|
+
*/
|
|
6695
|
+
get elevationRScalers() {
|
|
6696
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationRScalers(this.__wbg_ptr);
|
|
6697
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6698
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6699
|
+
return v1;
|
|
6700
|
+
}
|
|
6701
|
+
/**
|
|
6702
|
+
* Speed in m/s of the current carrying the waves on the watermask's water
|
|
6703
|
+
* along `waveDirection`.
|
|
5691
6704
|
* @returns {number}
|
|
5692
6705
|
*/
|
|
5693
|
-
get
|
|
5694
|
-
const ret = wasm.
|
|
6706
|
+
get flowSpeed() {
|
|
6707
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_flowSpeed(this.__wbg_ptr);
|
|
5695
6708
|
return ret;
|
|
5696
6709
|
}
|
|
5697
6710
|
/**
|
|
@@ -5795,18 +6808,24 @@ export class RasterTileInternalMaterial {
|
|
|
5795
6808
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5796
6809
|
}
|
|
5797
6810
|
/**
|
|
5798
|
-
*
|
|
6811
|
+
* Per-layer logarithmic boundaries
|
|
6812
|
+
* @returns {Float64Array}
|
|
5799
6813
|
*/
|
|
5800
|
-
get
|
|
5801
|
-
const ret = wasm.
|
|
5802
|
-
|
|
6814
|
+
get logBoundaries() {
|
|
6815
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_logBoundaries(this.__wbg_ptr);
|
|
6816
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6817
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6818
|
+
return v1;
|
|
5803
6819
|
}
|
|
5804
6820
|
/**
|
|
5805
|
-
*
|
|
6821
|
+
* Per-layer logarithmic scaling flags
|
|
6822
|
+
* @returns {Uint8Array}
|
|
5806
6823
|
*/
|
|
5807
|
-
get
|
|
5808
|
-
const ret = wasm.
|
|
5809
|
-
|
|
6824
|
+
get logarithmics() {
|
|
6825
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_logarithmics(this.__wbg_ptr);
|
|
6826
|
+
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
6827
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
6828
|
+
return v1;
|
|
5810
6829
|
}
|
|
5811
6830
|
/**
|
|
5812
6831
|
* @returns {Float32Array}
|
|
@@ -5849,6 +6868,41 @@ export class RasterTileInternalMaterial {
|
|
|
5849
6868
|
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
5850
6869
|
return v1;
|
|
5851
6870
|
}
|
|
6871
|
+
/**
|
|
6872
|
+
* Body color of the watermask's water from the terrain layer; `None`
|
|
6873
|
+
* keeps the imagery or globe color.
|
|
6874
|
+
* @returns {number | undefined}
|
|
6875
|
+
*/
|
|
6876
|
+
get waterMaskColor() {
|
|
6877
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_waterMaskColor(this.__wbg_ptr);
|
|
6878
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6879
|
+
}
|
|
6880
|
+
/**
|
|
6881
|
+
* Where the waves on the watermask's water travel, in degrees clockwise
|
|
6882
|
+
* from north.
|
|
6883
|
+
* @returns {number}
|
|
6884
|
+
*/
|
|
6885
|
+
get waveDirection() {
|
|
6886
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_waveDirection(this.__wbg_ptr);
|
|
6887
|
+
return ret;
|
|
6888
|
+
}
|
|
6889
|
+
/**
|
|
6890
|
+
* Scales the wave slopes on the watermask's water; 0 is a flat mirror.
|
|
6891
|
+
* @returns {number}
|
|
6892
|
+
*/
|
|
6893
|
+
get waveExaggeration() {
|
|
6894
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_waveExaggeration(this.__wbg_ptr);
|
|
6895
|
+
return ret;
|
|
6896
|
+
}
|
|
6897
|
+
/**
|
|
6898
|
+
* Sets the size, slope and speed of the waves on the watermask's water, in
|
|
6899
|
+
* m/s.
|
|
6900
|
+
* @returns {number}
|
|
6901
|
+
*/
|
|
6902
|
+
get waveStrength() {
|
|
6903
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_waveStrength(this.__wbg_ptr);
|
|
6904
|
+
return ret;
|
|
6905
|
+
}
|
|
5852
6906
|
/**
|
|
5853
6907
|
* @returns {any[]}
|
|
5854
6908
|
*/
|
|
@@ -5876,6 +6930,16 @@ export class RasterTileInternalMaterial {
|
|
|
5876
6930
|
set castShadow(arg0) {
|
|
5877
6931
|
wasm.__wbg_set_rastertileinternalmaterial_castShadow(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
5878
6932
|
}
|
|
6933
|
+
/**
|
|
6934
|
+
* Per-slot layer IDs used to look up each layer's colorMap atlas row; an
|
|
6935
|
+
* empty string for slots without an elevation heatmap.
|
|
6936
|
+
* @param {string[]} arg0
|
|
6937
|
+
*/
|
|
6938
|
+
set colorMapLayerIds(arg0) {
|
|
6939
|
+
const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6940
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6941
|
+
wasm.__wbg_set_rastertileinternalmaterial_colorMapLayerIds(this.__wbg_ptr, ptr0, len0);
|
|
6942
|
+
}
|
|
5879
6943
|
/**
|
|
5880
6944
|
* @param {Uint32Array} arg0
|
|
5881
6945
|
*/
|
|
@@ -5885,64 +6949,104 @@ export class RasterTileInternalMaterial {
|
|
|
5885
6949
|
wasm.__wbg_set_rastertileinternalmaterial_colors(this.__wbg_ptr, ptr0, len0);
|
|
5886
6950
|
}
|
|
5887
6951
|
/**
|
|
5888
|
-
* @param {
|
|
6952
|
+
* @param {Float64Array} arg0
|
|
5889
6953
|
*/
|
|
5890
|
-
set
|
|
5891
|
-
|
|
6954
|
+
set elevationBScalers(arg0) {
|
|
6955
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6956
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6957
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationBScalers(this.__wbg_ptr, ptr0, len0);
|
|
5892
6958
|
}
|
|
5893
6959
|
/**
|
|
5894
|
-
* @param {
|
|
6960
|
+
* @param {Float64Array} arg0
|
|
5895
6961
|
*/
|
|
5896
|
-
set
|
|
5897
|
-
|
|
6962
|
+
set elevationBoundaries(arg0) {
|
|
6963
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6964
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6965
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationBoundaries(this.__wbg_ptr, ptr0, len0);
|
|
5898
6966
|
}
|
|
5899
6967
|
/**
|
|
5900
|
-
* @param {
|
|
6968
|
+
* @param {Float64Array} arg0
|
|
5901
6969
|
*/
|
|
5902
|
-
set
|
|
5903
|
-
|
|
6970
|
+
set elevationEpsilons(arg0) {
|
|
6971
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6972
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6973
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationEpsilons(this.__wbg_ptr, ptr0, len0);
|
|
5904
6974
|
}
|
|
5905
6975
|
/**
|
|
5906
|
-
* @param {
|
|
6976
|
+
* @param {Float64Array} arg0
|
|
5907
6977
|
*/
|
|
5908
|
-
set
|
|
5909
|
-
|
|
6978
|
+
set elevationGScalers(arg0) {
|
|
6979
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6980
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6981
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationGScalers(this.__wbg_ptr, ptr0, len0);
|
|
5910
6982
|
}
|
|
5911
6983
|
/**
|
|
5912
|
-
*
|
|
6984
|
+
* Per-layer filter modes: "linear" or "nearest"
|
|
6985
|
+
* @param {string[]} arg0
|
|
5913
6986
|
*/
|
|
5914
|
-
set
|
|
5915
|
-
|
|
6987
|
+
set elevationHeatmapFilters(arg0) {
|
|
6988
|
+
const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6989
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6990
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationHeatmapFilters(this.__wbg_ptr, ptr0, len0);
|
|
5916
6991
|
}
|
|
5917
6992
|
/**
|
|
5918
|
-
*
|
|
6993
|
+
* Per-layer maximum heights for elevation normalization
|
|
6994
|
+
* @param {Float64Array} arg0
|
|
5919
6995
|
*/
|
|
5920
|
-
set
|
|
5921
|
-
|
|
6996
|
+
set elevationMaxHeights(arg0) {
|
|
6997
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6998
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6999
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationMaxHeights(this.__wbg_ptr, ptr0, len0);
|
|
5922
7000
|
}
|
|
5923
7001
|
/**
|
|
5924
|
-
* @param {
|
|
7002
|
+
* @param {Float64Array} arg0
|
|
5925
7003
|
*/
|
|
5926
|
-
set
|
|
5927
|
-
|
|
7004
|
+
set elevationMaxOffsets(arg0) {
|
|
7005
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7006
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7007
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationMaxOffsets(this.__wbg_ptr, ptr0, len0);
|
|
5928
7008
|
}
|
|
5929
7009
|
/**
|
|
5930
|
-
*
|
|
7010
|
+
* Per-layer minimum heights for elevation normalization
|
|
7011
|
+
* @param {Float64Array} arg0
|
|
5931
7012
|
*/
|
|
5932
|
-
set
|
|
5933
|
-
|
|
7013
|
+
set elevationMinHeights(arg0) {
|
|
7014
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7015
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7016
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationMinHeights(this.__wbg_ptr, ptr0, len0);
|
|
5934
7017
|
}
|
|
5935
7018
|
/**
|
|
5936
|
-
* @param {
|
|
7019
|
+
* @param {Float64Array} arg0
|
|
7020
|
+
*/
|
|
7021
|
+
set elevationMinOffsets(arg0) {
|
|
7022
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7023
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7024
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationMinOffsets(this.__wbg_ptr, ptr0, len0);
|
|
7025
|
+
}
|
|
7026
|
+
/**
|
|
7027
|
+
* @param {Float64Array} arg0
|
|
7028
|
+
*/
|
|
7029
|
+
set elevationOffsets(arg0) {
|
|
7030
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7031
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7032
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationOffsets(this.__wbg_ptr, ptr0, len0);
|
|
7033
|
+
}
|
|
7034
|
+
/**
|
|
7035
|
+
* Per-layer DEM decoder parameters
|
|
7036
|
+
* @param {Float64Array} arg0
|
|
5937
7037
|
*/
|
|
5938
|
-
set
|
|
5939
|
-
|
|
7038
|
+
set elevationRScalers(arg0) {
|
|
7039
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7040
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7041
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationRScalers(this.__wbg_ptr, ptr0, len0);
|
|
5940
7042
|
}
|
|
5941
7043
|
/**
|
|
7044
|
+
* Speed in m/s of the current carrying the waves on the watermask's water
|
|
7045
|
+
* along `waveDirection`.
|
|
5942
7046
|
* @param {number} arg0
|
|
5943
7047
|
*/
|
|
5944
|
-
set
|
|
5945
|
-
wasm.
|
|
7048
|
+
set flowSpeed(arg0) {
|
|
7049
|
+
wasm.__wbg_set_rastertileinternalmaterial_flowSpeed(this.__wbg_ptr, arg0);
|
|
5946
7050
|
}
|
|
5947
7051
|
/**
|
|
5948
7052
|
* @param {number} arg0
|
|
@@ -6032,16 +7136,22 @@ export class RasterTileInternalMaterial {
|
|
|
6032
7136
|
wasm.__wbg_set_rastertileinternalmaterial_lit(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6033
7137
|
}
|
|
6034
7138
|
/**
|
|
6035
|
-
*
|
|
7139
|
+
* Per-layer logarithmic boundaries
|
|
7140
|
+
* @param {Float64Array} arg0
|
|
6036
7141
|
*/
|
|
6037
|
-
set
|
|
6038
|
-
|
|
7142
|
+
set logBoundaries(arg0) {
|
|
7143
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7144
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7145
|
+
wasm.__wbg_set_rastertileinternalmaterial_logBoundaries(this.__wbg_ptr, ptr0, len0);
|
|
6039
7146
|
}
|
|
6040
7147
|
/**
|
|
6041
|
-
*
|
|
7148
|
+
* Per-layer logarithmic scaling flags
|
|
7149
|
+
* @param {Uint8Array} arg0
|
|
6042
7150
|
*/
|
|
6043
|
-
set
|
|
6044
|
-
|
|
7151
|
+
set logarithmics(arg0) {
|
|
7152
|
+
const ptr0 = passArray8ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7153
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7154
|
+
wasm.__wbg_set_rastertileinternalmaterial_logarithmics(this.__wbg_ptr, ptr0, len0);
|
|
6045
7155
|
}
|
|
6046
7156
|
/**
|
|
6047
7157
|
* @param {Float32Array} arg0
|
|
@@ -6079,6 +7189,37 @@ export class RasterTileInternalMaterial {
|
|
|
6079
7189
|
const len0 = WASM_VECTOR_LEN;
|
|
6080
7190
|
wasm.__wbg_set_rastertileinternalmaterial_terrainLatRange(this.__wbg_ptr, ptr0, len0);
|
|
6081
7191
|
}
|
|
7192
|
+
/**
|
|
7193
|
+
* Body color of the watermask's water from the terrain layer; `None`
|
|
7194
|
+
* keeps the imagery or globe color.
|
|
7195
|
+
* @param {number | null} [arg0]
|
|
7196
|
+
*/
|
|
7197
|
+
set waterMaskColor(arg0) {
|
|
7198
|
+
wasm.__wbg_set_rastertileinternalmaterial_waterMaskColor(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
7199
|
+
}
|
|
7200
|
+
/**
|
|
7201
|
+
* Where the waves on the watermask's water travel, in degrees clockwise
|
|
7202
|
+
* from north.
|
|
7203
|
+
* @param {number} arg0
|
|
7204
|
+
*/
|
|
7205
|
+
set waveDirection(arg0) {
|
|
7206
|
+
wasm.__wbg_set_rastertileinternalmaterial_waveDirection(this.__wbg_ptr, arg0);
|
|
7207
|
+
}
|
|
7208
|
+
/**
|
|
7209
|
+
* Scales the wave slopes on the watermask's water; 0 is a flat mirror.
|
|
7210
|
+
* @param {number} arg0
|
|
7211
|
+
*/
|
|
7212
|
+
set waveExaggeration(arg0) {
|
|
7213
|
+
wasm.__wbg_set_rastertileinternalmaterial_waveExaggeration(this.__wbg_ptr, arg0);
|
|
7214
|
+
}
|
|
7215
|
+
/**
|
|
7216
|
+
* Sets the size, slope and speed of the waves on the watermask's water, in
|
|
7217
|
+
* m/s.
|
|
7218
|
+
* @param {number} arg0
|
|
7219
|
+
*/
|
|
7220
|
+
set waveStrength(arg0) {
|
|
7221
|
+
wasm.__wbg_set_rastertileinternalmaterial_waveStrength(this.__wbg_ptr, arg0);
|
|
7222
|
+
}
|
|
6082
7223
|
}
|
|
6083
7224
|
if (Symbol.dispose) RasterTileInternalMaterial.prototype[Symbol.dispose] = RasterTileInternalMaterial.prototype.free;
|
|
6084
7225
|
|
|
@@ -6250,6 +7391,13 @@ export class ReturnedConstructedTerrainMesh {
|
|
|
6250
7391
|
const ret = wasm.returnedconstructedterrainmesh_transferNormals(this.__wbg_ptr);
|
|
6251
7392
|
return ret;
|
|
6252
7393
|
}
|
|
7394
|
+
/**
|
|
7395
|
+
* @returns {Float32Array | undefined}
|
|
7396
|
+
*/
|
|
7397
|
+
transferSkirtHeights() {
|
|
7398
|
+
const ret = wasm.returnedconstructedterrainmesh_transferSkirtHeights(this.__wbg_ptr);
|
|
7399
|
+
return ret;
|
|
7400
|
+
}
|
|
6253
7401
|
/**
|
|
6254
7402
|
* @returns {Uint32Array | undefined}
|
|
6255
7403
|
*/
|
|
@@ -6349,6 +7497,36 @@ export class TerrainMaterial {
|
|
|
6349
7497
|
const ret = wasm.__wbg_get_terrainmaterial_castShadow(this.__wbg_ptr);
|
|
6350
7498
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6351
7499
|
}
|
|
7500
|
+
/**
|
|
7501
|
+
* Height in meters that stays in place while the terrain is exaggerated:
|
|
7502
|
+
* a terrain height `h` is rendered at
|
|
7503
|
+
* `(h - exaggerationRelativeHeight) * exaggeration + exaggerationRelativeHeight`.
|
|
7504
|
+
* Default: 0.
|
|
7505
|
+
* @returns {number | undefined}
|
|
7506
|
+
*/
|
|
7507
|
+
get exaggerationRelativeHeight() {
|
|
7508
|
+
const ret = wasm.__wbg_get_terrainmaterial_exaggerationRelativeHeight(this.__wbg_ptr);
|
|
7509
|
+
return ret[0] === 0 ? undefined : ret[1];
|
|
7510
|
+
}
|
|
7511
|
+
/**
|
|
7512
|
+
* Vertical exaggeration of the terrain. Terrain heights are scaled by this
|
|
7513
|
+
* factor around `exaggerationRelativeHeight`. A negative value is treated
|
|
7514
|
+
* as 0, which flattens the terrain. Default: 1.
|
|
7515
|
+
* @returns {number | undefined}
|
|
7516
|
+
*/
|
|
7517
|
+
get exaggeration() {
|
|
7518
|
+
const ret = wasm.__wbg_get_terrainmaterial_exaggeration(this.__wbg_ptr);
|
|
7519
|
+
return ret[0] === 0 ? undefined : ret[1];
|
|
7520
|
+
}
|
|
7521
|
+
/**
|
|
7522
|
+
* Speed in m/s of the current carrying the waves on the watermask's water
|
|
7523
|
+
* along `waveDirection`. Default: 0.
|
|
7524
|
+
* @returns {number | undefined}
|
|
7525
|
+
*/
|
|
7526
|
+
get flowSpeed() {
|
|
7527
|
+
const ret = wasm.__wbg_get_terrainmaterial_flowSpeed(this.__wbg_ptr);
|
|
7528
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7529
|
+
}
|
|
6352
7530
|
/**
|
|
6353
7531
|
* Applies the lighting equation to the color output. When `false` the
|
|
6354
7532
|
* material outputs plain albedo (for deferred lighting) while normals and
|
|
@@ -6398,12 +7576,66 @@ export class TerrainMaterial {
|
|
|
6398
7576
|
const ret = wasm.__wbg_get_terrainmaterial_skirt(this.__wbg_ptr);
|
|
6399
7577
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6400
7578
|
}
|
|
7579
|
+
/**
|
|
7580
|
+
* Where the waves on the watermask's water travel, in degrees clockwise
|
|
7581
|
+
* from north. Default: 0.
|
|
7582
|
+
* @returns {number | undefined}
|
|
7583
|
+
*/
|
|
7584
|
+
get waveDirection() {
|
|
7585
|
+
const ret = wasm.__wbg_get_terrainmaterial_waveDirection(this.__wbg_ptr);
|
|
7586
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7587
|
+
}
|
|
7588
|
+
/**
|
|
7589
|
+
* Scales the wave slopes on the watermask's water, keeping their size and
|
|
7590
|
+
* speed; 0 is a flat mirror. Default: 1.
|
|
7591
|
+
* @returns {number | undefined}
|
|
7592
|
+
*/
|
|
7593
|
+
get waveExaggeration() {
|
|
7594
|
+
const ret = wasm.__wbg_get_terrainmaterial_waveExaggeration(this.__wbg_ptr);
|
|
7595
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7596
|
+
}
|
|
7597
|
+
/**
|
|
7598
|
+
* Sets the size, steepness and speed of the waves on the watermask's water:
|
|
7599
|
+
* about 1 is a calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
7600
|
+
* @returns {number | undefined}
|
|
7601
|
+
*/
|
|
7602
|
+
get waveStrength() {
|
|
7603
|
+
const ret = wasm.__wbg_get_terrainmaterial_waveStrength(this.__wbg_ptr);
|
|
7604
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7605
|
+
}
|
|
6401
7606
|
/**
|
|
6402
7607
|
* @param {boolean | null} [arg0]
|
|
6403
7608
|
*/
|
|
6404
7609
|
set castShadow(arg0) {
|
|
6405
7610
|
wasm.__wbg_set_terrainmaterial_castShadow(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6406
7611
|
}
|
|
7612
|
+
/**
|
|
7613
|
+
* Height in meters that stays in place while the terrain is exaggerated:
|
|
7614
|
+
* a terrain height `h` is rendered at
|
|
7615
|
+
* `(h - exaggerationRelativeHeight) * exaggeration + exaggerationRelativeHeight`.
|
|
7616
|
+
* Default: 0.
|
|
7617
|
+
* @param {number | null} [arg0]
|
|
7618
|
+
*/
|
|
7619
|
+
set exaggerationRelativeHeight(arg0) {
|
|
7620
|
+
wasm.__wbg_set_terrainmaterial_exaggerationRelativeHeight(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? 0 : arg0);
|
|
7621
|
+
}
|
|
7622
|
+
/**
|
|
7623
|
+
* Vertical exaggeration of the terrain. Terrain heights are scaled by this
|
|
7624
|
+
* factor around `exaggerationRelativeHeight`. A negative value is treated
|
|
7625
|
+
* as 0, which flattens the terrain. Default: 1.
|
|
7626
|
+
* @param {number | null} [arg0]
|
|
7627
|
+
*/
|
|
7628
|
+
set exaggeration(arg0) {
|
|
7629
|
+
wasm.__wbg_set_terrainmaterial_exaggeration(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? 0 : arg0);
|
|
7630
|
+
}
|
|
7631
|
+
/**
|
|
7632
|
+
* Speed in m/s of the current carrying the waves on the watermask's water
|
|
7633
|
+
* along `waveDirection`. Default: 0.
|
|
7634
|
+
* @param {number | null} [arg0]
|
|
7635
|
+
*/
|
|
7636
|
+
set flowSpeed(arg0) {
|
|
7637
|
+
wasm.__wbg_set_terrainmaterial_flowSpeed(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7638
|
+
}
|
|
6407
7639
|
/**
|
|
6408
7640
|
* Applies the lighting equation to the color output. When `false` the
|
|
6409
7641
|
* material outputs plain albedo (for deferred lighting) while normals and
|
|
@@ -6447,6 +7679,47 @@ export class TerrainMaterial {
|
|
|
6447
7679
|
set skirt(arg0) {
|
|
6448
7680
|
wasm.__wbg_set_terrainmaterial_skirt(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6449
7681
|
}
|
|
7682
|
+
/**
|
|
7683
|
+
* Where the waves on the watermask's water travel, in degrees clockwise
|
|
7684
|
+
* from north. Default: 0.
|
|
7685
|
+
* @param {number | null} [arg0]
|
|
7686
|
+
*/
|
|
7687
|
+
set waveDirection(arg0) {
|
|
7688
|
+
wasm.__wbg_set_terrainmaterial_waveDirection(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7689
|
+
}
|
|
7690
|
+
/**
|
|
7691
|
+
* Scales the wave slopes on the watermask's water, keeping their size and
|
|
7692
|
+
* speed; 0 is a flat mirror. Default: 1.
|
|
7693
|
+
* @param {number | null} [arg0]
|
|
7694
|
+
*/
|
|
7695
|
+
set waveExaggeration(arg0) {
|
|
7696
|
+
wasm.__wbg_set_terrainmaterial_waveExaggeration(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7697
|
+
}
|
|
7698
|
+
/**
|
|
7699
|
+
* Sets the size, steepness and speed of the waves on the watermask's water:
|
|
7700
|
+
* about 1 is a calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
7701
|
+
* @param {number | null} [arg0]
|
|
7702
|
+
*/
|
|
7703
|
+
set waveStrength(arg0) {
|
|
7704
|
+
wasm.__wbg_set_terrainmaterial_waveStrength(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7705
|
+
}
|
|
7706
|
+
/**
|
|
7707
|
+
* @param {number | null} [color]
|
|
7708
|
+
*/
|
|
7709
|
+
set waterMaskColor(color) {
|
|
7710
|
+
wasm.terrainmaterial_set_waterMaskColor(this.__wbg_ptr, isLikeNone(color) ? Number.MAX_SAFE_INTEGER : (color) >>> 0);
|
|
7711
|
+
}
|
|
7712
|
+
/**
|
|
7713
|
+
* Body color of the water the source's watermask marks. The water shows
|
|
7714
|
+
* this color under its reflections instead of the imagery or globe color
|
|
7715
|
+
* beneath it. Requires `requestWaterMask` on a quantized-mesh source.
|
|
7716
|
+
* An update with `undefined` uses that imagery or globe color.
|
|
7717
|
+
* @returns {number | undefined}
|
|
7718
|
+
*/
|
|
7719
|
+
get waterMaskColor() {
|
|
7720
|
+
const ret = wasm.terrainmaterial_waterMaskColor(this.__wbg_ptr);
|
|
7721
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7722
|
+
}
|
|
6450
7723
|
}
|
|
6451
7724
|
if (Symbol.dispose) TerrainMaterial.prototype[Symbol.dispose] = TerrainMaterial.prototype.free;
|
|
6452
7725
|
|
|
@@ -6462,10 +7735,27 @@ export class TextMaterial {
|
|
|
6462
7735
|
wasm.__wbg_textmaterial_free(ptr, 0);
|
|
6463
7736
|
}
|
|
6464
7737
|
/**
|
|
6465
|
-
*
|
|
6466
|
-
*
|
|
6467
|
-
*
|
|
6468
|
-
*
|
|
7738
|
+
* Part of the text block placed at the anchor point: `"center"`
|
|
7739
|
+
* (default), `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`,
|
|
7740
|
+
* `"top-right"`, `"bottom-left"` or `"bottom-right"`, as MapLibre's
|
|
7741
|
+
* `text-anchor`. The block is as wide as its widest line and one line
|
|
7742
|
+
* height tall per line.
|
|
7743
|
+
* @returns {string | undefined}
|
|
7744
|
+
*/
|
|
7745
|
+
get anchor() {
|
|
7746
|
+
const ret = wasm.__wbg_get_textmaterial_anchor(this.__wbg_ptr);
|
|
7747
|
+
let v1;
|
|
7748
|
+
if (ret[0] !== 0) {
|
|
7749
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
7750
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
7751
|
+
}
|
|
7752
|
+
return v1;
|
|
7753
|
+
}
|
|
7754
|
+
/**
|
|
7755
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
7756
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
7757
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
7758
|
+
* camera.
|
|
6469
7759
|
* @returns {boolean | undefined}
|
|
6470
7760
|
*/
|
|
6471
7761
|
get backfaceCulling() {
|
|
@@ -6493,13 +7783,6 @@ export class TextMaterial {
|
|
|
6493
7783
|
const ret = wasm.__wbg_get_textmaterial_borderWidth(this.__wbg_ptr);
|
|
6494
7784
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6495
7785
|
}
|
|
6496
|
-
/**
|
|
6497
|
-
* @returns {Vec2 | undefined}
|
|
6498
|
-
*/
|
|
6499
|
-
get center() {
|
|
6500
|
-
const ret = wasm.__wbg_get_textmaterial_center(this.__wbg_ptr);
|
|
6501
|
-
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
6502
|
-
}
|
|
6503
7786
|
/**
|
|
6504
7787
|
* @returns {boolean | undefined}
|
|
6505
7788
|
*/
|
|
@@ -6514,6 +7797,21 @@ export class TextMaterial {
|
|
|
6514
7797
|
const ret = wasm.__wbg_get_textmaterial_color(this.__wbg_ptr);
|
|
6515
7798
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6516
7799
|
}
|
|
7800
|
+
/**
|
|
7801
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
7802
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
7803
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
7804
|
+
* @returns {Float32Array | undefined}
|
|
7805
|
+
*/
|
|
7806
|
+
get declutterPadding() {
|
|
7807
|
+
const ret = wasm.__wbg_get_textmaterial_declutterPadding(this.__wbg_ptr);
|
|
7808
|
+
let v1;
|
|
7809
|
+
if (ret[0] !== 0) {
|
|
7810
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
7811
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
7812
|
+
}
|
|
7813
|
+
return v1;
|
|
7814
|
+
}
|
|
6517
7815
|
/**
|
|
6518
7816
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
6519
7817
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -6523,6 +7821,17 @@ export class TextMaterial {
|
|
|
6523
7821
|
const ret = wasm.__wbg_get_textmaterial_declutterPriority(this.__wbg_ptr);
|
|
6524
7822
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6525
7823
|
}
|
|
7824
|
+
/**
|
|
7825
|
+
* Coarse placement order for decluttering, compared before
|
|
7826
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
7827
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
7828
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
7829
|
+
* @returns {number | undefined}
|
|
7830
|
+
*/
|
|
7831
|
+
get declutterRank() {
|
|
7832
|
+
const ret = wasm.__wbg_get_textmaterial_declutterRank(this.__wbg_ptr);
|
|
7833
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7834
|
+
}
|
|
6526
7835
|
/**
|
|
6527
7836
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
6528
7837
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -6596,8 +7905,9 @@ export class TextMaterial {
|
|
|
6596
7905
|
}
|
|
6597
7906
|
/**
|
|
6598
7907
|
* Source geometry types this appearance consumes: `"point"`, `"line"`,
|
|
6599
|
-
* `"polygon"`. Defaults to `["point"]`; adding `"line"
|
|
6600
|
-
*
|
|
7908
|
+
* `"polygon"`. Defaults to `["point"]`; adding `"line"` also emits a
|
|
7909
|
+
* label per line string, at its first vertex, and `"polygon"` one per
|
|
7910
|
+
* polygon.
|
|
6601
7911
|
* @returns {string[] | undefined}
|
|
6602
7912
|
*/
|
|
6603
7913
|
get geometryTypes() {
|
|
@@ -6628,6 +7938,25 @@ export class TextMaterial {
|
|
|
6628
7938
|
const ret = wasm.__wbg_get_textmaterial_highQuality(this.__wbg_ptr);
|
|
6629
7939
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6630
7940
|
}
|
|
7941
|
+
/**
|
|
7942
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
7943
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
7944
|
+
* Defaults to `false`.
|
|
7945
|
+
* @returns {boolean | undefined}
|
|
7946
|
+
*/
|
|
7947
|
+
get ignorePlacement() {
|
|
7948
|
+
const ret = wasm.__wbg_get_textmaterial_ignorePlacement(this.__wbg_ptr);
|
|
7949
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
7950
|
+
}
|
|
7951
|
+
/**
|
|
7952
|
+
* Flip a label that would otherwise read right-to-left, so names stay
|
|
7953
|
+
* legible whichever way the underlying line runs. Defaults to `true`.
|
|
7954
|
+
* @returns {boolean | undefined}
|
|
7955
|
+
*/
|
|
7956
|
+
get keepUpright() {
|
|
7957
|
+
const ret = wasm.__wbg_get_textmaterial_keepUpright(this.__wbg_ptr);
|
|
7958
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
7959
|
+
}
|
|
6631
7960
|
/**
|
|
6632
7961
|
* Language code for text shaping (e.g., "en", "ja", "ar"). Used for proper text rendering.
|
|
6633
7962
|
* @returns {string | undefined}
|
|
@@ -6642,14 +7971,47 @@ export class TextMaterial {
|
|
|
6642
7971
|
return v1;
|
|
6643
7972
|
}
|
|
6644
7973
|
/**
|
|
6645
|
-
*
|
|
6646
|
-
*
|
|
7974
|
+
* Extra space between characters, in ems (multiples of `size`). Not
|
|
7975
|
+
* added after the last character; ignored for Arabic-script text.
|
|
7976
|
+
* Negative values tighten. Defaults to `0.0`.
|
|
7977
|
+
* @returns {number | undefined}
|
|
7978
|
+
*/
|
|
7979
|
+
get letterSpacing() {
|
|
7980
|
+
const ret = wasm.__wbg_get_textmaterial_letterSpacing(this.__wbg_ptr);
|
|
7981
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7982
|
+
}
|
|
7983
|
+
/**
|
|
7984
|
+
* Distance between the baselines of a multi-line label, in ems
|
|
7985
|
+
* (multiples of `size`). Defaults to the font's natural line height
|
|
7986
|
+
* (ascender − descender + line gap).
|
|
6647
7987
|
* @returns {number | undefined}
|
|
6648
7988
|
*/
|
|
6649
7989
|
get lineHeight() {
|
|
6650
7990
|
const ret = wasm.__wbg_get_textmaterial_lineHeight(this.__wbg_ptr);
|
|
6651
7991
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6652
7992
|
}
|
|
7993
|
+
/**
|
|
7994
|
+
* Offset perpendicular to the line, in the same units as the font size:
|
|
7995
|
+
* pixels when `sizeInMeters` is false, metres when it is true. Positive is
|
|
7996
|
+
* to the left of the direction of travel, which puts the name above the
|
|
7997
|
+
* line. Defaults to `0.0`.
|
|
7998
|
+
* @returns {number | undefined}
|
|
7999
|
+
*/
|
|
8000
|
+
get lineOffset() {
|
|
8001
|
+
const ret = wasm.__wbg_get_textmaterial_lineOffset(this.__wbg_ptr);
|
|
8002
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
8003
|
+
}
|
|
8004
|
+
/**
|
|
8005
|
+
* Largest turn, in degrees, the line may make under a label within a
|
|
8006
|
+
* window of about one and a half ems before the label is dropped as
|
|
8007
|
+
* unreadable. The window slides along the label, so a long gentle curve
|
|
8008
|
+
* is accepted however far it turns in total. Defaults to `45.0`.
|
|
8009
|
+
* @returns {number | undefined}
|
|
8010
|
+
*/
|
|
8011
|
+
get maxAngle() {
|
|
8012
|
+
const ret = wasm.__wbg_get_textmaterial_maxAngle(this.__wbg_ptr);
|
|
8013
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
8014
|
+
}
|
|
6653
8015
|
/**
|
|
6654
8016
|
* Maximum line width in ems (multiples of `size`) before text wraps at
|
|
6655
8017
|
* word boundaries. `0.0` (the default) disables wrapping; explicit `\n`
|
|
@@ -6668,6 +8030,16 @@ export class TextMaterial {
|
|
|
6668
8030
|
const ret = wasm.__wbg_get_textmaterial_offsetDepth(this.__wbg_ptr);
|
|
6669
8031
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6670
8032
|
}
|
|
8033
|
+
/**
|
|
8034
|
+
* Shift from the anchor point, x right and y down, in ems (multiples of
|
|
8035
|
+
* `size`), as MapLibre's `text-offset`. Lies in the label's own plane, so
|
|
8036
|
+
* it turns with `rotation`. Defaults to `(0, 0)`.
|
|
8037
|
+
* @returns {Vec2 | undefined}
|
|
8038
|
+
*/
|
|
8039
|
+
get offset() {
|
|
8040
|
+
const ret = wasm.__wbg_get_textmaterial_offset(this.__wbg_ptr);
|
|
8041
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
8042
|
+
}
|
|
6671
8043
|
/**
|
|
6672
8044
|
* Opacity of the text
|
|
6673
8045
|
* @returns {number | undefined}
|
|
@@ -6677,7 +8049,15 @@ export class TextMaterial {
|
|
|
6677
8049
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6678
8050
|
}
|
|
6679
8051
|
/**
|
|
6680
|
-
*
|
|
8052
|
+
* Width over which the outline's outer edge fades out, centered on that
|
|
8053
|
+
* edge, in the unit of `outlineWidth`. Defaults to `0.0`.
|
|
8054
|
+
* @returns {number | undefined}
|
|
8055
|
+
*/
|
|
8056
|
+
get outlineBlur() {
|
|
8057
|
+
const ret = wasm.__wbg_get_textmaterial_outlineBlur(this.__wbg_ptr);
|
|
8058
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
8059
|
+
}
|
|
8060
|
+
/**
|
|
6681
8061
|
* @returns {number | undefined}
|
|
6682
8062
|
*/
|
|
6683
8063
|
get outlineColor() {
|
|
@@ -6693,7 +8073,9 @@ export class TextMaterial {
|
|
|
6693
8073
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6694
8074
|
}
|
|
6695
8075
|
/**
|
|
6696
|
-
* Outline thickness
|
|
8076
|
+
* Outline thickness in 1/64 em: pixels of text drawn 64 pixels tall, so
|
|
8077
|
+
* the outline keeps its proportion to the glyphs at any size. Defaults
|
|
8078
|
+
* to `0.0`.
|
|
6697
8079
|
* @returns {number | undefined}
|
|
6698
8080
|
*/
|
|
6699
8081
|
get outlineWidth() {
|
|
@@ -6701,11 +8083,49 @@ export class TextMaterial {
|
|
|
6701
8083
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6702
8084
|
}
|
|
6703
8085
|
/**
|
|
6704
|
-
* Whether the label
|
|
6705
|
-
*
|
|
6706
|
-
*
|
|
6707
|
-
*
|
|
6708
|
-
*
|
|
8086
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
8087
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
8088
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
8089
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
8090
|
+
* @returns {string | undefined}
|
|
8091
|
+
*/
|
|
8092
|
+
get overlap() {
|
|
8093
|
+
const ret = wasm.__wbg_get_textmaterial_overlap(this.__wbg_ptr);
|
|
8094
|
+
let v1;
|
|
8095
|
+
if (ret[0] !== 0) {
|
|
8096
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
8097
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
8098
|
+
}
|
|
8099
|
+
return v1;
|
|
8100
|
+
}
|
|
8101
|
+
/**
|
|
8102
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
8103
|
+
* default) puts a label per line string, at its first vertex, and one
|
|
8104
|
+
* per polygon, `"line"` repeats labels along the line every `spacing`
|
|
8105
|
+
* with the glyphs bending to follow it, `"line-center"` places a single
|
|
8106
|
+
* label at the line's midpoint. Polygon rings are walked like lines.
|
|
8107
|
+
* Requires `geometryTypes` to include `"line"` or `"polygon"`.
|
|
8108
|
+
* @returns {string | undefined}
|
|
8109
|
+
*/
|
|
8110
|
+
get placement() {
|
|
8111
|
+
const ret = wasm.__wbg_get_textmaterial_placement(this.__wbg_ptr);
|
|
8112
|
+
let v1;
|
|
8113
|
+
if (ret[0] !== 0) {
|
|
8114
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
8115
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
8116
|
+
}
|
|
8117
|
+
return v1;
|
|
8118
|
+
}
|
|
8119
|
+
/**
|
|
8120
|
+
* Whether the label turns with the camera or with the map, as MapLibre's
|
|
8121
|
+
* `text-rotation-alignment` `viewport` and `map`. `true` keeps it reading
|
|
8122
|
+
* left to right (a screen-aligned billboard, or a flat label yawed to the
|
|
8123
|
+
* camera). `false` aligns it with the map: upright, it stays on screen but
|
|
8124
|
+
* turns with the camera heading so its x-axis points east; flat, it lies
|
|
8125
|
+
* north-up. Along a line, `false` makes the label follow the line, and
|
|
8126
|
+
* `true` draws it straight at its anchor unless `spreadGlyphs` is set.
|
|
8127
|
+
* Left unset, it is `true` for `placement: "point"` and `false` along a
|
|
8128
|
+
* line, as MapLibre resolves `auto`.
|
|
6709
8129
|
* @returns {boolean | undefined}
|
|
6710
8130
|
*/
|
|
6711
8131
|
get rotateWithCamera() {
|
|
@@ -6717,8 +8137,10 @@ export class TextMaterial {
|
|
|
6717
8137
|
* degrees, clockwise seen from the front. Applied on top of whatever
|
|
6718
8138
|
* orientation `textFacing` and `rotateWithCamera` resolve to: it spins a
|
|
6719
8139
|
* billboard on screen and turns a surface label like a compass bearing.
|
|
6720
|
-
* `
|
|
6721
|
-
*
|
|
8140
|
+
* `anchor` decides where inside the text the pivot sits. Along a line
|
|
8141
|
+
* each glyph spins about its own point on the line, as MapLibre's
|
|
8142
|
+
* `text-rotate` does, except for a straight label (`rotateWithCamera`
|
|
8143
|
+
* without `spreadGlyphs`), which turns as a whole. Defaults to `0.0`.
|
|
6722
8144
|
* @returns {number | undefined}
|
|
6723
8145
|
*/
|
|
6724
8146
|
get rotation() {
|
|
@@ -6748,9 +8170,52 @@ export class TextMaterial {
|
|
|
6748
8170
|
const ret = wasm.__wbg_get_textmaterial_size(this.__wbg_ptr);
|
|
6749
8171
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6750
8172
|
}
|
|
8173
|
+
/**
|
|
8174
|
+
* Distance between repeated labels along a line, in screen pixels, for
|
|
8175
|
+
* `vector-tile` and `geojson` sources alike. Resolved per label as the
|
|
8176
|
+
* camera moves: labels thin out as it pulls back and fill in as it
|
|
8177
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
8178
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
8179
|
+
* `symbol-spacing`, a label longer than three quarters of the spacing
|
|
8180
|
+
* spreads its repeats to its own length plus a quarter of the spacing, a
|
|
8181
|
+
* label within half the spacing of an earlier one with the same text is
|
|
8182
|
+
* dropped, and a vector tile places labels only inside its own bounds.
|
|
8183
|
+
* Defaults to `250.0`.
|
|
8184
|
+
* @returns {number | undefined}
|
|
8185
|
+
*/
|
|
8186
|
+
get spacing() {
|
|
8187
|
+
const ret = wasm.__wbg_get_textmaterial_spacing(this.__wbg_ptr);
|
|
8188
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
8189
|
+
}
|
|
8190
|
+
/**
|
|
8191
|
+
* Place each glyph of an along-line label on its own instead of each
|
|
8192
|
+
* word. With `rotateWithCamera: false` each glyph turns with the line
|
|
8193
|
+
* under it (MapLibre's `symbol-placement: "line"`); with `true`, each
|
|
8194
|
+
* glyph turns to the camera like a point label and is spaced on the
|
|
8195
|
+
* screen (MapLibre's `viewport-glyph`). Can be overridden per feature
|
|
8196
|
+
* from a feature evaluator. Defaults to `false`.
|
|
8197
|
+
* @returns {boolean | undefined}
|
|
8198
|
+
*/
|
|
8199
|
+
get spreadGlyphs() {
|
|
8200
|
+
const ret = wasm.__wbg_get_textmaterial_spreadGlyphs(this.__wbg_ptr);
|
|
8201
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
8202
|
+
}
|
|
8203
|
+
/**
|
|
8204
|
+
* Whether this may show while its partner at the same anchor (the
|
|
8205
|
+
* layer's label for a billboard, its billboard for a label) is hidden.
|
|
8206
|
+
* With `false` on both, the two are placed together: both show or
|
|
8207
|
+
* neither does. Only meaningful when `declutter` is enabled. Defaults to
|
|
8208
|
+
* `true`.
|
|
8209
|
+
* @returns {boolean | undefined}
|
|
8210
|
+
*/
|
|
8211
|
+
get standalone() {
|
|
8212
|
+
const ret = wasm.__wbg_get_textmaterial_standalone(this.__wbg_ptr);
|
|
8213
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
8214
|
+
}
|
|
6751
8215
|
/**
|
|
6752
8216
|
* Horizontal alignment of lines within a multi-line block:
|
|
6753
|
-
* `"left"`, `"center"` (default), or `"
|
|
8217
|
+
* `"left"`, `"center"` (default), `"right"`, or `"auto"`, which aligns
|
|
8218
|
+
* towards the horizontal side of `anchor` (MapLibre's `text-justify`).
|
|
6754
8219
|
* @returns {string | undefined}
|
|
6755
8220
|
*/
|
|
6756
8221
|
get textAlign() {
|
|
@@ -6763,9 +8228,13 @@ export class TextMaterial {
|
|
|
6763
8228
|
return v1;
|
|
6764
8229
|
}
|
|
6765
8230
|
/**
|
|
6766
|
-
*
|
|
6767
|
-
* globe surface around its anchor (`"flat"`), following its
|
|
6768
|
-
* it reads as painted on the surface.
|
|
8231
|
+
* Plane the label lies in: the screen (`"upright"`, never foreshortened)
|
|
8232
|
+
* or the globe surface around its anchor (`"flat"`), following its
|
|
8233
|
+
* curvature so it reads as painted on the surface. MapLibre's
|
|
8234
|
+
* `text-pitch-alignment` `viewport` and `map`. Pair with
|
|
8235
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
8236
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
8237
|
+
* `auto`.
|
|
6769
8238
|
* @returns {string | undefined}
|
|
6770
8239
|
*/
|
|
6771
8240
|
get textFacing() {
|
|
@@ -6789,6 +8258,31 @@ export class TextMaterial {
|
|
|
6789
8258
|
}
|
|
6790
8259
|
return v1;
|
|
6791
8260
|
}
|
|
8261
|
+
/**
|
|
8262
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
8263
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
8264
|
+
* the screen axes. MapLibre's `text-translate-anchor`.
|
|
8265
|
+
* @returns {string | undefined}
|
|
8266
|
+
*/
|
|
8267
|
+
get translateAnchor() {
|
|
8268
|
+
const ret = wasm.__wbg_get_textmaterial_translateAnchor(this.__wbg_ptr);
|
|
8269
|
+
let v1;
|
|
8270
|
+
if (ret[0] !== 0) {
|
|
8271
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
8272
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
8273
|
+
}
|
|
8274
|
+
return v1;
|
|
8275
|
+
}
|
|
8276
|
+
/**
|
|
8277
|
+
* Screen-pixel shift of the drawn label, x right and y down, applied after
|
|
8278
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
8279
|
+
* MapLibre's `text-translate`. Defaults to `(0, 0)`.
|
|
8280
|
+
* @returns {Vec2 | undefined}
|
|
8281
|
+
*/
|
|
8282
|
+
get translate() {
|
|
8283
|
+
const ret = wasm.__wbg_get_textmaterial_translate(this.__wbg_ptr);
|
|
8284
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
8285
|
+
}
|
|
6792
8286
|
/**
|
|
6793
8287
|
* Enable transparency and alpha blending
|
|
6794
8288
|
* @returns {boolean | undefined}
|
|
@@ -6798,10 +8292,40 @@ export class TextMaterial {
|
|
|
6798
8292
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6799
8293
|
}
|
|
6800
8294
|
/**
|
|
6801
|
-
*
|
|
6802
|
-
*
|
|
6803
|
-
*
|
|
6804
|
-
*
|
|
8295
|
+
* Placements the declutter pass tries in order, keeping the first whose
|
|
8296
|
+
* box is free, as MapLibre's `text-variable-anchor-offset`. The one in
|
|
8297
|
+
* use is tried first, so a label only moves when it must. Overrides
|
|
8298
|
+
* `anchor` and `offset` when not empty, except along a line. Without
|
|
8299
|
+
* declutter the first is used.
|
|
8300
|
+
* @returns {VariableAnchor[] | undefined}
|
|
8301
|
+
*/
|
|
8302
|
+
get variableAnchors() {
|
|
8303
|
+
const ret = wasm.__wbg_get_textmaterial_variableAnchors(this.__wbg_ptr);
|
|
8304
|
+
let v1;
|
|
8305
|
+
if (ret[0] !== 0) {
|
|
8306
|
+
v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
8307
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
8308
|
+
}
|
|
8309
|
+
return v1;
|
|
8310
|
+
}
|
|
8311
|
+
/**
|
|
8312
|
+
* Part of the text block placed at the anchor point: `"center"`
|
|
8313
|
+
* (default), `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`,
|
|
8314
|
+
* `"top-right"`, `"bottom-left"` or `"bottom-right"`, as MapLibre's
|
|
8315
|
+
* `text-anchor`. The block is as wide as its widest line and one line
|
|
8316
|
+
* height tall per line.
|
|
8317
|
+
* @param {string | null} [arg0]
|
|
8318
|
+
*/
|
|
8319
|
+
set anchor(arg0) {
|
|
8320
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8321
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8322
|
+
wasm.__wbg_set_textmaterial_anchor(this.__wbg_ptr, ptr0, len0);
|
|
8323
|
+
}
|
|
8324
|
+
/**
|
|
8325
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
8326
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
8327
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
8328
|
+
* camera.
|
|
6805
8329
|
* @param {boolean | null} [arg0]
|
|
6806
8330
|
*/
|
|
6807
8331
|
set backfaceCulling(arg0) {
|
|
@@ -6825,17 +8349,6 @@ export class TextMaterial {
|
|
|
6825
8349
|
set borderWidth(arg0) {
|
|
6826
8350
|
wasm.__wbg_set_textmaterial_borderWidth(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6827
8351
|
}
|
|
6828
|
-
/**
|
|
6829
|
-
* @param {Vec2 | null} [arg0]
|
|
6830
|
-
*/
|
|
6831
|
-
set center(arg0) {
|
|
6832
|
-
let ptr0 = 0;
|
|
6833
|
-
if (!isLikeNone(arg0)) {
|
|
6834
|
-
_assertClass(arg0, Vec2);
|
|
6835
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
6836
|
-
}
|
|
6837
|
-
wasm.__wbg_set_textmaterial_center(this.__wbg_ptr, ptr0);
|
|
6838
|
-
}
|
|
6839
8352
|
/**
|
|
6840
8353
|
* @param {boolean | null} [arg0]
|
|
6841
8354
|
*/
|
|
@@ -6848,6 +8361,17 @@ export class TextMaterial {
|
|
|
6848
8361
|
set color(arg0) {
|
|
6849
8362
|
wasm.__wbg_set_textmaterial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
6850
8363
|
}
|
|
8364
|
+
/**
|
|
8365
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
8366
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
8367
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
8368
|
+
* @param {Float32Array | null} [arg0]
|
|
8369
|
+
*/
|
|
8370
|
+
set declutterPadding(arg0) {
|
|
8371
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
8372
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8373
|
+
wasm.__wbg_set_textmaterial_declutterPadding(this.__wbg_ptr, ptr0, len0);
|
|
8374
|
+
}
|
|
6851
8375
|
/**
|
|
6852
8376
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
6853
8377
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -6856,6 +8380,16 @@ export class TextMaterial {
|
|
|
6856
8380
|
set declutterPriority(arg0) {
|
|
6857
8381
|
wasm.__wbg_set_textmaterial_declutterPriority(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6858
8382
|
}
|
|
8383
|
+
/**
|
|
8384
|
+
* Coarse placement order for decluttering, compared before
|
|
8385
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
8386
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
8387
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
8388
|
+
* @param {number | null} [arg0]
|
|
8389
|
+
*/
|
|
8390
|
+
set declutterRank(arg0) {
|
|
8391
|
+
wasm.__wbg_set_textmaterial_declutterRank(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8392
|
+
}
|
|
6859
8393
|
/**
|
|
6860
8394
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
6861
8395
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -6917,8 +8451,9 @@ export class TextMaterial {
|
|
|
6917
8451
|
}
|
|
6918
8452
|
/**
|
|
6919
8453
|
* Source geometry types this appearance consumes: `"point"`, `"line"`,
|
|
6920
|
-
* `"polygon"`. Defaults to `["point"]`; adding `"line"
|
|
6921
|
-
*
|
|
8454
|
+
* `"polygon"`. Defaults to `["point"]`; adding `"line"` also emits a
|
|
8455
|
+
* label per line string, at its first vertex, and `"polygon"` one per
|
|
8456
|
+
* polygon.
|
|
6922
8457
|
* @param {string[] | null} [arg0]
|
|
6923
8458
|
*/
|
|
6924
8459
|
set geometryTypes(arg0) {
|
|
@@ -6943,6 +8478,23 @@ export class TextMaterial {
|
|
|
6943
8478
|
set highQuality(arg0) {
|
|
6944
8479
|
wasm.__wbg_set_textmaterial_highQuality(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6945
8480
|
}
|
|
8481
|
+
/**
|
|
8482
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
8483
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
8484
|
+
* Defaults to `false`.
|
|
8485
|
+
* @param {boolean | null} [arg0]
|
|
8486
|
+
*/
|
|
8487
|
+
set ignorePlacement(arg0) {
|
|
8488
|
+
wasm.__wbg_set_textmaterial_ignorePlacement(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
8489
|
+
}
|
|
8490
|
+
/**
|
|
8491
|
+
* Flip a label that would otherwise read right-to-left, so names stay
|
|
8492
|
+
* legible whichever way the underlying line runs. Defaults to `true`.
|
|
8493
|
+
* @param {boolean | null} [arg0]
|
|
8494
|
+
*/
|
|
8495
|
+
set keepUpright(arg0) {
|
|
8496
|
+
wasm.__wbg_set_textmaterial_keepUpright(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
8497
|
+
}
|
|
6946
8498
|
/**
|
|
6947
8499
|
* Language code for text shaping (e.g., "en", "ja", "ar"). Used for proper text rendering.
|
|
6948
8500
|
* @param {string | null} [arg0]
|
|
@@ -6953,13 +8505,43 @@ export class TextMaterial {
|
|
|
6953
8505
|
wasm.__wbg_set_textmaterial_lang(this.__wbg_ptr, ptr0, len0);
|
|
6954
8506
|
}
|
|
6955
8507
|
/**
|
|
6956
|
-
*
|
|
6957
|
-
*
|
|
8508
|
+
* Extra space between characters, in ems (multiples of `size`). Not
|
|
8509
|
+
* added after the last character; ignored for Arabic-script text.
|
|
8510
|
+
* Negative values tighten. Defaults to `0.0`.
|
|
8511
|
+
* @param {number | null} [arg0]
|
|
8512
|
+
*/
|
|
8513
|
+
set letterSpacing(arg0) {
|
|
8514
|
+
wasm.__wbg_set_textmaterial_letterSpacing(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8515
|
+
}
|
|
8516
|
+
/**
|
|
8517
|
+
* Distance between the baselines of a multi-line label, in ems
|
|
8518
|
+
* (multiples of `size`). Defaults to the font's natural line height
|
|
8519
|
+
* (ascender − descender + line gap).
|
|
6958
8520
|
* @param {number | null} [arg0]
|
|
6959
8521
|
*/
|
|
6960
8522
|
set lineHeight(arg0) {
|
|
6961
8523
|
wasm.__wbg_set_textmaterial_lineHeight(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6962
8524
|
}
|
|
8525
|
+
/**
|
|
8526
|
+
* Offset perpendicular to the line, in the same units as the font size:
|
|
8527
|
+
* pixels when `sizeInMeters` is false, metres when it is true. Positive is
|
|
8528
|
+
* to the left of the direction of travel, which puts the name above the
|
|
8529
|
+
* line. Defaults to `0.0`.
|
|
8530
|
+
* @param {number | null} [arg0]
|
|
8531
|
+
*/
|
|
8532
|
+
set lineOffset(arg0) {
|
|
8533
|
+
wasm.__wbg_set_textmaterial_lineOffset(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8534
|
+
}
|
|
8535
|
+
/**
|
|
8536
|
+
* Largest turn, in degrees, the line may make under a label within a
|
|
8537
|
+
* window of about one and a half ems before the label is dropped as
|
|
8538
|
+
* unreadable. The window slides along the label, so a long gentle curve
|
|
8539
|
+
* is accepted however far it turns in total. Defaults to `45.0`.
|
|
8540
|
+
* @param {number | null} [arg0]
|
|
8541
|
+
*/
|
|
8542
|
+
set maxAngle(arg0) {
|
|
8543
|
+
wasm.__wbg_set_textmaterial_maxAngle(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8544
|
+
}
|
|
6963
8545
|
/**
|
|
6964
8546
|
* Maximum line width in ems (multiples of `size`) before text wraps at
|
|
6965
8547
|
* word boundaries. `0.0` (the default) disables wrapping; explicit `\n`
|
|
@@ -6976,6 +8558,20 @@ export class TextMaterial {
|
|
|
6976
8558
|
set offsetDepth(arg0) {
|
|
6977
8559
|
wasm.__wbg_set_textmaterial_offsetDepth(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6978
8560
|
}
|
|
8561
|
+
/**
|
|
8562
|
+
* Shift from the anchor point, x right and y down, in ems (multiples of
|
|
8563
|
+
* `size`), as MapLibre's `text-offset`. Lies in the label's own plane, so
|
|
8564
|
+
* it turns with `rotation`. Defaults to `(0, 0)`.
|
|
8565
|
+
* @param {Vec2 | null} [arg0]
|
|
8566
|
+
*/
|
|
8567
|
+
set offset(arg0) {
|
|
8568
|
+
let ptr0 = 0;
|
|
8569
|
+
if (!isLikeNone(arg0)) {
|
|
8570
|
+
_assertClass(arg0, Vec2);
|
|
8571
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
8572
|
+
}
|
|
8573
|
+
wasm.__wbg_set_textmaterial_offset(this.__wbg_ptr, ptr0);
|
|
8574
|
+
}
|
|
6979
8575
|
/**
|
|
6980
8576
|
* Opacity of the text
|
|
6981
8577
|
* @param {number | null} [arg0]
|
|
@@ -6984,7 +8580,14 @@ export class TextMaterial {
|
|
|
6984
8580
|
wasm.__wbg_set_textmaterial_opacity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6985
8581
|
}
|
|
6986
8582
|
/**
|
|
6987
|
-
*
|
|
8583
|
+
* Width over which the outline's outer edge fades out, centered on that
|
|
8584
|
+
* edge, in the unit of `outlineWidth`. Defaults to `0.0`.
|
|
8585
|
+
* @param {number | null} [arg0]
|
|
8586
|
+
*/
|
|
8587
|
+
set outlineBlur(arg0) {
|
|
8588
|
+
wasm.__wbg_set_textmaterial_outlineBlur(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8589
|
+
}
|
|
8590
|
+
/**
|
|
6988
8591
|
* @param {number | null} [arg0]
|
|
6989
8592
|
*/
|
|
6990
8593
|
set outlineColor(arg0) {
|
|
@@ -6998,18 +8601,50 @@ export class TextMaterial {
|
|
|
6998
8601
|
wasm.__wbg_set_textmaterial_outlineOpacity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6999
8602
|
}
|
|
7000
8603
|
/**
|
|
7001
|
-
* Outline thickness
|
|
8604
|
+
* Outline thickness in 1/64 em: pixels of text drawn 64 pixels tall, so
|
|
8605
|
+
* the outline keeps its proportion to the glyphs at any size. Defaults
|
|
8606
|
+
* to `0.0`.
|
|
7002
8607
|
* @param {number | null} [arg0]
|
|
7003
8608
|
*/
|
|
7004
8609
|
set outlineWidth(arg0) {
|
|
7005
8610
|
wasm.__wbg_set_textmaterial_outlineWidth(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7006
8611
|
}
|
|
7007
8612
|
/**
|
|
7008
|
-
* Whether the label
|
|
7009
|
-
*
|
|
7010
|
-
*
|
|
7011
|
-
*
|
|
7012
|
-
*
|
|
8613
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
8614
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
8615
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
8616
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
8617
|
+
* @param {string | null} [arg0]
|
|
8618
|
+
*/
|
|
8619
|
+
set overlap(arg0) {
|
|
8620
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8621
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8622
|
+
wasm.__wbg_set_textmaterial_overlap(this.__wbg_ptr, ptr0, len0);
|
|
8623
|
+
}
|
|
8624
|
+
/**
|
|
8625
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
8626
|
+
* default) puts a label per line string, at its first vertex, and one
|
|
8627
|
+
* per polygon, `"line"` repeats labels along the line every `spacing`
|
|
8628
|
+
* with the glyphs bending to follow it, `"line-center"` places a single
|
|
8629
|
+
* label at the line's midpoint. Polygon rings are walked like lines.
|
|
8630
|
+
* Requires `geometryTypes` to include `"line"` or `"polygon"`.
|
|
8631
|
+
* @param {string | null} [arg0]
|
|
8632
|
+
*/
|
|
8633
|
+
set placement(arg0) {
|
|
8634
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8635
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8636
|
+
wasm.__wbg_set_textmaterial_placement(this.__wbg_ptr, ptr0, len0);
|
|
8637
|
+
}
|
|
8638
|
+
/**
|
|
8639
|
+
* Whether the label turns with the camera or with the map, as MapLibre's
|
|
8640
|
+
* `text-rotation-alignment` `viewport` and `map`. `true` keeps it reading
|
|
8641
|
+
* left to right (a screen-aligned billboard, or a flat label yawed to the
|
|
8642
|
+
* camera). `false` aligns it with the map: upright, it stays on screen but
|
|
8643
|
+
* turns with the camera heading so its x-axis points east; flat, it lies
|
|
8644
|
+
* north-up. Along a line, `false` makes the label follow the line, and
|
|
8645
|
+
* `true` draws it straight at its anchor unless `spreadGlyphs` is set.
|
|
8646
|
+
* Left unset, it is `true` for `placement: "point"` and `false` along a
|
|
8647
|
+
* line, as MapLibre resolves `auto`.
|
|
7013
8648
|
* @param {boolean | null} [arg0]
|
|
7014
8649
|
*/
|
|
7015
8650
|
set rotateWithCamera(arg0) {
|
|
@@ -7020,8 +8655,10 @@ export class TextMaterial {
|
|
|
7020
8655
|
* degrees, clockwise seen from the front. Applied on top of whatever
|
|
7021
8656
|
* orientation `textFacing` and `rotateWithCamera` resolve to: it spins a
|
|
7022
8657
|
* billboard on screen and turns a surface label like a compass bearing.
|
|
7023
|
-
* `
|
|
7024
|
-
*
|
|
8658
|
+
* `anchor` decides where inside the text the pivot sits. Along a line
|
|
8659
|
+
* each glyph spins about its own point on the line, as MapLibre's
|
|
8660
|
+
* `text-rotate` does, except for a straight label (`rotateWithCamera`
|
|
8661
|
+
* without `spreadGlyphs`), which turns as a whole. Defaults to `0.0`.
|
|
7025
8662
|
* @param {number | null} [arg0]
|
|
7026
8663
|
*/
|
|
7027
8664
|
set rotation(arg0) {
|
|
@@ -7047,9 +8684,49 @@ export class TextMaterial {
|
|
|
7047
8684
|
set size(arg0) {
|
|
7048
8685
|
wasm.__wbg_set_textmaterial_size(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7049
8686
|
}
|
|
8687
|
+
/**
|
|
8688
|
+
* Distance between repeated labels along a line, in screen pixels, for
|
|
8689
|
+
* `vector-tile` and `geojson` sources alike. Resolved per label as the
|
|
8690
|
+
* camera moves: labels thin out as it pulls back and fill in as it
|
|
8691
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
8692
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
8693
|
+
* `symbol-spacing`, a label longer than three quarters of the spacing
|
|
8694
|
+
* spreads its repeats to its own length plus a quarter of the spacing, a
|
|
8695
|
+
* label within half the spacing of an earlier one with the same text is
|
|
8696
|
+
* dropped, and a vector tile places labels only inside its own bounds.
|
|
8697
|
+
* Defaults to `250.0`.
|
|
8698
|
+
* @param {number | null} [arg0]
|
|
8699
|
+
*/
|
|
8700
|
+
set spacing(arg0) {
|
|
8701
|
+
wasm.__wbg_set_textmaterial_spacing(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8702
|
+
}
|
|
8703
|
+
/**
|
|
8704
|
+
* Place each glyph of an along-line label on its own instead of each
|
|
8705
|
+
* word. With `rotateWithCamera: false` each glyph turns with the line
|
|
8706
|
+
* under it (MapLibre's `symbol-placement: "line"`); with `true`, each
|
|
8707
|
+
* glyph turns to the camera like a point label and is spaced on the
|
|
8708
|
+
* screen (MapLibre's `viewport-glyph`). Can be overridden per feature
|
|
8709
|
+
* from a feature evaluator. Defaults to `false`.
|
|
8710
|
+
* @param {boolean | null} [arg0]
|
|
8711
|
+
*/
|
|
8712
|
+
set spreadGlyphs(arg0) {
|
|
8713
|
+
wasm.__wbg_set_textmaterial_spreadGlyphs(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
8714
|
+
}
|
|
8715
|
+
/**
|
|
8716
|
+
* Whether this may show while its partner at the same anchor (the
|
|
8717
|
+
* layer's label for a billboard, its billboard for a label) is hidden.
|
|
8718
|
+
* With `false` on both, the two are placed together: both show or
|
|
8719
|
+
* neither does. Only meaningful when `declutter` is enabled. Defaults to
|
|
8720
|
+
* `true`.
|
|
8721
|
+
* @param {boolean | null} [arg0]
|
|
8722
|
+
*/
|
|
8723
|
+
set standalone(arg0) {
|
|
8724
|
+
wasm.__wbg_set_textmaterial_standalone(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
8725
|
+
}
|
|
7050
8726
|
/**
|
|
7051
8727
|
* Horizontal alignment of lines within a multi-line block:
|
|
7052
|
-
* `"left"`, `"center"` (default), or `"
|
|
8728
|
+
* `"left"`, `"center"` (default), `"right"`, or `"auto"`, which aligns
|
|
8729
|
+
* towards the horizontal side of `anchor` (MapLibre's `text-justify`).
|
|
7053
8730
|
* @param {string | null} [arg0]
|
|
7054
8731
|
*/
|
|
7055
8732
|
set textAlign(arg0) {
|
|
@@ -7058,9 +8735,13 @@ export class TextMaterial {
|
|
|
7058
8735
|
wasm.__wbg_set_textmaterial_textAlign(this.__wbg_ptr, ptr0, len0);
|
|
7059
8736
|
}
|
|
7060
8737
|
/**
|
|
7061
|
-
*
|
|
7062
|
-
* globe surface around its anchor (`"flat"`), following its
|
|
7063
|
-
* it reads as painted on the surface.
|
|
8738
|
+
* Plane the label lies in: the screen (`"upright"`, never foreshortened)
|
|
8739
|
+
* or the globe surface around its anchor (`"flat"`), following its
|
|
8740
|
+
* curvature so it reads as painted on the surface. MapLibre's
|
|
8741
|
+
* `text-pitch-alignment` `viewport` and `map`. Pair with
|
|
8742
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
8743
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
8744
|
+
* `auto`.
|
|
7064
8745
|
* @param {string | null} [arg0]
|
|
7065
8746
|
*/
|
|
7066
8747
|
set textFacing(arg0) {
|
|
@@ -7076,6 +8757,31 @@ export class TextMaterial {
|
|
|
7076
8757
|
var len0 = WASM_VECTOR_LEN;
|
|
7077
8758
|
wasm.__wbg_set_textmaterial_text(this.__wbg_ptr, ptr0, len0);
|
|
7078
8759
|
}
|
|
8760
|
+
/**
|
|
8761
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
8762
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
8763
|
+
* the screen axes. MapLibre's `text-translate-anchor`.
|
|
8764
|
+
* @param {string | null} [arg0]
|
|
8765
|
+
*/
|
|
8766
|
+
set translateAnchor(arg0) {
|
|
8767
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8768
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8769
|
+
wasm.__wbg_set_textmaterial_translateAnchor(this.__wbg_ptr, ptr0, len0);
|
|
8770
|
+
}
|
|
8771
|
+
/**
|
|
8772
|
+
* Screen-pixel shift of the drawn label, x right and y down, applied after
|
|
8773
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
8774
|
+
* MapLibre's `text-translate`. Defaults to `(0, 0)`.
|
|
8775
|
+
* @param {Vec2 | null} [arg0]
|
|
8776
|
+
*/
|
|
8777
|
+
set translate(arg0) {
|
|
8778
|
+
let ptr0 = 0;
|
|
8779
|
+
if (!isLikeNone(arg0)) {
|
|
8780
|
+
_assertClass(arg0, Vec2);
|
|
8781
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
8782
|
+
}
|
|
8783
|
+
wasm.__wbg_set_textmaterial_translate(this.__wbg_ptr, ptr0);
|
|
8784
|
+
}
|
|
7079
8785
|
/**
|
|
7080
8786
|
* Enable transparency and alpha blending
|
|
7081
8787
|
* @param {boolean | null} [arg0]
|
|
@@ -7083,6 +8789,19 @@ export class TextMaterial {
|
|
|
7083
8789
|
set transparent(arg0) {
|
|
7084
8790
|
wasm.__wbg_set_textmaterial_transparent(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
7085
8791
|
}
|
|
8792
|
+
/**
|
|
8793
|
+
* Placements the declutter pass tries in order, keeping the first whose
|
|
8794
|
+
* box is free, as MapLibre's `text-variable-anchor-offset`. The one in
|
|
8795
|
+
* use is tried first, so a label only moves when it must. Overrides
|
|
8796
|
+
* `anchor` and `offset` when not empty, except along a line. Without
|
|
8797
|
+
* declutter the first is used.
|
|
8798
|
+
* @param {VariableAnchor[] | null} [arg0]
|
|
8799
|
+
*/
|
|
8800
|
+
set variableAnchors(arg0) {
|
|
8801
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
8802
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8803
|
+
wasm.__wbg_set_textmaterial_variableAnchors(this.__wbg_ptr, ptr0, len0);
|
|
8804
|
+
}
|
|
7086
8805
|
}
|
|
7087
8806
|
if (Symbol.dispose) TextMaterial.prototype[Symbol.dispose] = TextMaterial.prototype.free;
|
|
7088
8807
|
|
|
@@ -7897,6 +9616,83 @@ export class UpsamplableTerrainGeometry {
|
|
|
7897
9616
|
}
|
|
7898
9617
|
if (Symbol.dispose) UpsamplableTerrainGeometry.prototype[Symbol.dispose] = UpsamplableTerrainGeometry.prototype.free;
|
|
7899
9618
|
|
|
9619
|
+
/**
|
|
9620
|
+
* One placement a label may take, as an entry of MapLibre's
|
|
9621
|
+
* `text-variable-anchor-offset`.
|
|
9622
|
+
*/
|
|
9623
|
+
export class VariableAnchor {
|
|
9624
|
+
static __wrap(ptr) {
|
|
9625
|
+
const obj = Object.create(VariableAnchor.prototype);
|
|
9626
|
+
obj.__wbg_ptr = ptr;
|
|
9627
|
+
VariableAnchorFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
9628
|
+
return obj;
|
|
9629
|
+
}
|
|
9630
|
+
static __unwrap(jsValue) {
|
|
9631
|
+
if (!(jsValue instanceof VariableAnchor)) {
|
|
9632
|
+
return 0;
|
|
9633
|
+
}
|
|
9634
|
+
return jsValue.__destroy_into_raw();
|
|
9635
|
+
}
|
|
9636
|
+
__destroy_into_raw() {
|
|
9637
|
+
const ptr = this.__wbg_ptr;
|
|
9638
|
+
this.__wbg_ptr = 0;
|
|
9639
|
+
VariableAnchorFinalization.unregister(this);
|
|
9640
|
+
return ptr;
|
|
9641
|
+
}
|
|
9642
|
+
free() {
|
|
9643
|
+
const ptr = this.__destroy_into_raw();
|
|
9644
|
+
wasm.__wbg_variableanchor_free(ptr, 0);
|
|
9645
|
+
}
|
|
9646
|
+
/**
|
|
9647
|
+
* Part of the text block placed at the anchor point, as `anchor`.
|
|
9648
|
+
* @returns {string}
|
|
9649
|
+
*/
|
|
9650
|
+
get anchor() {
|
|
9651
|
+
let deferred1_0;
|
|
9652
|
+
let deferred1_1;
|
|
9653
|
+
try {
|
|
9654
|
+
const ret = wasm.__wbg_get_variableanchor_anchor(this.__wbg_ptr);
|
|
9655
|
+
deferred1_0 = ret[0];
|
|
9656
|
+
deferred1_1 = ret[1];
|
|
9657
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
9658
|
+
} finally {
|
|
9659
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
9660
|
+
}
|
|
9661
|
+
}
|
|
9662
|
+
/**
|
|
9663
|
+
* Shift from the anchor point, x right and y down, in ems. Defaults to
|
|
9664
|
+
* `(0, 0)`.
|
|
9665
|
+
* @returns {Vec2 | undefined}
|
|
9666
|
+
*/
|
|
9667
|
+
get offset() {
|
|
9668
|
+
const ret = wasm.__wbg_get_variableanchor_offset(this.__wbg_ptr);
|
|
9669
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
9670
|
+
}
|
|
9671
|
+
/**
|
|
9672
|
+
* Part of the text block placed at the anchor point, as `anchor`.
|
|
9673
|
+
* @param {string} arg0
|
|
9674
|
+
*/
|
|
9675
|
+
set anchor(arg0) {
|
|
9676
|
+
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
9677
|
+
const len0 = WASM_VECTOR_LEN;
|
|
9678
|
+
wasm.__wbg_set_variableanchor_anchor(this.__wbg_ptr, ptr0, len0);
|
|
9679
|
+
}
|
|
9680
|
+
/**
|
|
9681
|
+
* Shift from the anchor point, x right and y down, in ems. Defaults to
|
|
9682
|
+
* `(0, 0)`.
|
|
9683
|
+
* @param {Vec2 | null} [arg0]
|
|
9684
|
+
*/
|
|
9685
|
+
set offset(arg0) {
|
|
9686
|
+
let ptr0 = 0;
|
|
9687
|
+
if (!isLikeNone(arg0)) {
|
|
9688
|
+
_assertClass(arg0, Vec2);
|
|
9689
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
9690
|
+
}
|
|
9691
|
+
wasm.__wbg_set_variableanchor_offset(this.__wbg_ptr, ptr0);
|
|
9692
|
+
}
|
|
9693
|
+
}
|
|
9694
|
+
if (Symbol.dispose) VariableAnchor.prototype[Symbol.dispose] = VariableAnchor.prototype.free;
|
|
9695
|
+
|
|
7900
9696
|
export class Vec2 {
|
|
7901
9697
|
static __wrap(ptr) {
|
|
7902
9698
|
const obj = Object.create(Vec2.prototype);
|
|
@@ -8186,17 +9982,20 @@ export function buildPolylineGeometry(coordinates, geocentric, ring, material) {
|
|
|
8186
9982
|
|
|
8187
9983
|
/**
|
|
8188
9984
|
* Run one placement pass. Returns a `hidden` flag (0 or 1) per candidate, in the
|
|
8189
|
-
* same order as the input slice.
|
|
9985
|
+
* same order as the input slice. Of a group of variable-anchor rows, at most
|
|
9986
|
+
* one is shown: the first that fits.
|
|
8190
9987
|
*
|
|
8191
9988
|
* `candidates` is a packed `f64` slice of `n * CANDIDATE_STRIDE` values (see the
|
|
8192
9989
|
* module docs); `view` and `proj` are column-major 4×4 matrices (16 values each).
|
|
8193
|
-
* `
|
|
8194
|
-
*
|
|
9990
|
+
* `horizon_min_height` is the renderer's `nvrHorizonMinHeight`, which the
|
|
9991
|
+
* horizon test shrinks the ellipsoid by. `hysteresis_px` is the
|
|
9992
|
+
* collision-test shrink applied only to currently-shown labels.
|
|
8195
9993
|
*
|
|
8196
9994
|
* The result is *hidden-by-default*: only a label that claimed space inside the
|
|
8197
9995
|
* tracked area (viewport + grid margin) comes back shown. Off-screen and
|
|
8198
9996
|
* GPU-culled labels stay hidden so they cannot fade in unseen and then pan into
|
|
8199
|
-
* view at full opacity.
|
|
9997
|
+
* view at full opacity. An [`Overlap::Always`] label is the exception: it can
|
|
9998
|
+
* never lose, so it is always shown and has no fade-in to wait for.
|
|
8200
9999
|
* @param {Float64Array} candidates
|
|
8201
10000
|
* @param {Float64Array} view
|
|
8202
10001
|
* @param {Float64Array} proj
|
|
@@ -8207,18 +10006,18 @@ export function buildPolylineGeometry(coordinates, geocentric, ring, material) {
|
|
|
8207
10006
|
* @param {number} width_px
|
|
8208
10007
|
* @param {number} height_px
|
|
8209
10008
|
* @param {number} fov_rad
|
|
8210
|
-
* @param {number}
|
|
10009
|
+
* @param {number} horizon_min_height
|
|
8211
10010
|
* @param {number} hysteresis_px
|
|
8212
10011
|
* @returns {Uint8Array}
|
|
8213
10012
|
*/
|
|
8214
|
-
export function declutterPlace(candidates, view, proj, camera_x, camera_y, camera_z, near, width_px, height_px, fov_rad,
|
|
10013
|
+
export function declutterPlace(candidates, view, proj, camera_x, camera_y, camera_z, near, width_px, height_px, fov_rad, horizon_min_height, hysteresis_px) {
|
|
8215
10014
|
const ptr0 = passArrayF64ToWasm0(candidates, wasm.__wbindgen_malloc);
|
|
8216
10015
|
const len0 = WASM_VECTOR_LEN;
|
|
8217
10016
|
const ptr1 = passArrayF64ToWasm0(view, wasm.__wbindgen_malloc);
|
|
8218
10017
|
const len1 = WASM_VECTOR_LEN;
|
|
8219
10018
|
const ptr2 = passArrayF64ToWasm0(proj, wasm.__wbindgen_malloc);
|
|
8220
10019
|
const len2 = WASM_VECTOR_LEN;
|
|
8221
|
-
const ret = wasm.declutterPlace(ptr0, len0, ptr1, len1, ptr2, len2, camera_x, camera_y, camera_z, near, width_px, height_px, fov_rad,
|
|
10020
|
+
const ret = wasm.declutterPlace(ptr0, len0, ptr1, len1, ptr2, len2, camera_x, camera_y, camera_z, near, width_px, height_px, fov_rad, horizon_min_height, hysteresis_px);
|
|
8222
10021
|
var v4 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
8223
10022
|
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
8224
10023
|
return v4;
|
|
@@ -8386,6 +10185,96 @@ export function getWGS84SemiMinorAxis() {
|
|
|
8386
10185
|
return ret;
|
|
8387
10186
|
}
|
|
8388
10187
|
|
|
10188
|
+
/**
|
|
10189
|
+
* Place along-line anchors for meshes that lay no label along the line — a
|
|
10190
|
+
* sprite is one quad at its anchor: whether each one's level is the one on
|
|
10191
|
+
* screen, and the box its quad covers there for the declutter pass.
|
|
10192
|
+
*
|
|
10193
|
+
* The level is chosen by the quad's extent *along its line*, measured in the
|
|
10194
|
+
* quad's own frame as MapLibre measures an icon: its local +y is turned
|
|
10195
|
+
* `rotation` from north and the line runs at `bearing`, so a quad turned to
|
|
10196
|
+
* follow its line is measured by its height, whatever its image's aspect.
|
|
10197
|
+
*
|
|
10198
|
+
* The box mirrors `nvr_quadBasis`, so a quad turned by its line, its style or
|
|
10199
|
+
* its facing claims the space it is drawn over rather than its unrotated
|
|
10200
|
+
* rectangle.
|
|
10201
|
+
*
|
|
10202
|
+
* `anchors` is packed [`LINE_ANCHOR_STRIDE`] values per anchor. Returns
|
|
10203
|
+
* [`LINE_ANCHOR_RESULT_STRIDE`] values per anchor, in input order.
|
|
10204
|
+
* @param {Float64Array} anchors
|
|
10205
|
+
* @param {Float64Array} view
|
|
10206
|
+
* @param {number} height_px
|
|
10207
|
+
* @param {number} fov_rad
|
|
10208
|
+
* @param {number} spacing_px
|
|
10209
|
+
* @returns {Float64Array}
|
|
10210
|
+
*/
|
|
10211
|
+
export function lineAnchorPlace(anchors, view, height_px, fov_rad, spacing_px) {
|
|
10212
|
+
const ptr0 = passArrayF64ToWasm0(anchors, wasm.__wbindgen_malloc);
|
|
10213
|
+
const len0 = WASM_VECTOR_LEN;
|
|
10214
|
+
const ptr1 = passArrayF64ToWasm0(view, wasm.__wbindgen_malloc);
|
|
10215
|
+
const len1 = WASM_VECTOR_LEN;
|
|
10216
|
+
const ret = wasm.lineAnchorPlace(ptr0, len0, ptr1, len1, height_px, fov_rad, spacing_px);
|
|
10217
|
+
var v3 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
10218
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
10219
|
+
return v3;
|
|
10220
|
+
}
|
|
10221
|
+
|
|
10222
|
+
/**
|
|
10223
|
+
* Whether a label is short enough to sit on its line, using nothing but the
|
|
10224
|
+
* anchor, the label's width and the line's extent.
|
|
10225
|
+
*
|
|
10226
|
+
* Returns one byte per label: `1` fits, `0` does not. See the module docs for
|
|
10227
|
+
* why this is worth a phase of its own.
|
|
10228
|
+
* @param {Float64Array} labels
|
|
10229
|
+
* @param {Float64Array} view
|
|
10230
|
+
* @param {number} height_px
|
|
10231
|
+
* @param {number} fov_rad
|
|
10232
|
+
* @param {number} spacing_px
|
|
10233
|
+
* @returns {Uint8Array}
|
|
10234
|
+
*/
|
|
10235
|
+
export function lineLabelFit(labels, view, height_px, fov_rad, spacing_px) {
|
|
10236
|
+
const ptr0 = passArrayF64ToWasm0(labels, wasm.__wbindgen_malloc);
|
|
10237
|
+
const len0 = WASM_VECTOR_LEN;
|
|
10238
|
+
const ptr1 = passArrayF64ToWasm0(view, wasm.__wbindgen_malloc);
|
|
10239
|
+
const len1 = WASM_VECTOR_LEN;
|
|
10240
|
+
const ret = wasm.lineLabelFit(ptr0, len0, ptr1, len1, height_px, fov_rad, spacing_px);
|
|
10241
|
+
var v3 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
10242
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
10243
|
+
return v3;
|
|
10244
|
+
}
|
|
10245
|
+
|
|
10246
|
+
/**
|
|
10247
|
+
* Place text labels along their lines.
|
|
10248
|
+
*
|
|
10249
|
+
* `labels` is a packed `f64` slice of `n * LINE_LABEL_STRIDE` values (see the
|
|
10250
|
+
* module docs); `paths` holds each label's samples as `2 * samples` `f32`
|
|
10251
|
+
* values, east then north metres relative to its anchor. `view` is a
|
|
10252
|
+
* column-major 4x4 matrix.
|
|
10253
|
+
*
|
|
10254
|
+
* Returns [`LINE_LABEL_RESULT_STRIDE`] values per label, in input order; see
|
|
10255
|
+
* the module docs for the layout. `spacing_px` is the layer's `spacing`.
|
|
10256
|
+
* @param {Float64Array} labels
|
|
10257
|
+
* @param {Float32Array} paths
|
|
10258
|
+
* @param {number} samples_per_label
|
|
10259
|
+
* @param {Float64Array} view
|
|
10260
|
+
* @param {number} height_px
|
|
10261
|
+
* @param {number} fov_rad
|
|
10262
|
+
* @param {number} spacing_px
|
|
10263
|
+
* @returns {Float64Array}
|
|
10264
|
+
*/
|
|
10265
|
+
export function lineLabelPlace(labels, paths, samples_per_label, view, height_px, fov_rad, spacing_px) {
|
|
10266
|
+
const ptr0 = passArrayF64ToWasm0(labels, wasm.__wbindgen_malloc);
|
|
10267
|
+
const len0 = WASM_VECTOR_LEN;
|
|
10268
|
+
const ptr1 = passArrayF32ToWasm0(paths, wasm.__wbindgen_malloc);
|
|
10269
|
+
const len1 = WASM_VECTOR_LEN;
|
|
10270
|
+
const ptr2 = passArrayF64ToWasm0(view, wasm.__wbindgen_malloc);
|
|
10271
|
+
const len2 = WASM_VECTOR_LEN;
|
|
10272
|
+
const ret = wasm.lineLabelPlace(ptr0, len0, ptr1, len1, samples_per_label, ptr2, len2, height_px, fov_rad, spacing_px);
|
|
10273
|
+
var v4 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
10274
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
10275
|
+
return v4;
|
|
10276
|
+
}
|
|
10277
|
+
|
|
8389
10278
|
/**
|
|
8390
10279
|
* @param {Vec3} origin
|
|
8391
10280
|
* @returns {Float64Array}
|
|
@@ -8856,8 +10745,8 @@ function __wbg_get_imports() {
|
|
|
8856
10745
|
const ret = LLE.__wrap(arg0);
|
|
8857
10746
|
return ret;
|
|
8858
10747
|
},
|
|
8859
|
-
|
|
8860
|
-
console.log(
|
|
10748
|
+
__wbg_log_e6372b4fbfc9f81e: function(arg0) {
|
|
10749
|
+
console.log(arg0);
|
|
8861
10750
|
},
|
|
8862
10751
|
__wbg_new_078f4f4b1eaabdec: function(arg0) {
|
|
8863
10752
|
const ret = new Float32Array(arg0);
|
|
@@ -8887,6 +10776,10 @@ function __wbg_get_imports() {
|
|
|
8887
10776
|
const ret = new Uint32Array(arg0, arg1 >>> 0, arg2 >>> 0);
|
|
8888
10777
|
return ret;
|
|
8889
10778
|
},
|
|
10779
|
+
__wbg_new_with_byte_offset_and_length_1aca16330a3ebb0a: function(arg0, arg1, arg2) {
|
|
10780
|
+
const ret = new Float32Array(arg0, arg1 >>> 0, arg2 >>> 0);
|
|
10781
|
+
return ret;
|
|
10782
|
+
},
|
|
8890
10783
|
__wbg_new_with_byte_offset_and_length_8a19fd6506a908ea: function(arg0, arg1, arg2) {
|
|
8891
10784
|
const ret = new Float64Array(arg0, arg1 >>> 0, arg2 >>> 0);
|
|
8892
10785
|
return ret;
|
|
@@ -8944,6 +10837,17 @@ function __wbg_get_imports() {
|
|
|
8944
10837
|
const ret = arg0.value;
|
|
8945
10838
|
return ret;
|
|
8946
10839
|
},
|
|
10840
|
+
__wbg_variableanchor_new: function(arg0) {
|
|
10841
|
+
const ret = VariableAnchor.__wrap(arg0);
|
|
10842
|
+
return ret;
|
|
10843
|
+
},
|
|
10844
|
+
__wbg_variableanchor_unwrap: function(arg0) {
|
|
10845
|
+
const ret = VariableAnchor.__unwrap(arg0);
|
|
10846
|
+
return ret;
|
|
10847
|
+
},
|
|
10848
|
+
__wbg_warn_917d7f727ab78481: function(arg0) {
|
|
10849
|
+
console.warn(arg0);
|
|
10850
|
+
},
|
|
8947
10851
|
__wbindgen_cast_0000000000000001: function(arg0) {
|
|
8948
10852
|
// Cast intrinsic for `F64 -> Externref`.
|
|
8949
10853
|
const ret = arg0;
|
|
@@ -9058,6 +10962,9 @@ const HillshadeMaterialFinalization = (typeof FinalizationRegistry === 'undefine
|
|
|
9058
10962
|
const LLEFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
9059
10963
|
? { register: () => {}, unregister: () => {} }
|
|
9060
10964
|
: new FinalizationRegistry(ptr => wasm.__wbg_lle_free(ptr, 1));
|
|
10965
|
+
const LineDashAtlasFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
10966
|
+
? { register: () => {}, unregister: () => {} }
|
|
10967
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_linedashatlas_free(ptr, 1));
|
|
9061
10968
|
const ModelInternalMaterialFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
9062
10969
|
? { register: () => {}, unregister: () => {} }
|
|
9063
10970
|
: new FinalizationRegistry(ptr => wasm.__wbg_modelinternalmaterial_free(ptr, 1));
|
|
@@ -9151,6 +11058,9 @@ const UintAttributeFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
|
9151
11058
|
const UpsamplableTerrainGeometryFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
9152
11059
|
? { register: () => {}, unregister: () => {} }
|
|
9153
11060
|
: new FinalizationRegistry(ptr => wasm.__wbg_upsamplableterraingeometry_free(ptr, 1));
|
|
11061
|
+
const VariableAnchorFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
11062
|
+
? { register: () => {}, unregister: () => {} }
|
|
11063
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_variableanchor_free(ptr, 1));
|
|
9154
11064
|
const Vec2Finalization = (typeof FinalizationRegistry === 'undefined')
|
|
9155
11065
|
? { register: () => {}, unregister: () => {} }
|
|
9156
11066
|
: new FinalizationRegistry(ptr => wasm.__wbg_vec2_free(ptr, 1));
|