@navaramap/engine-worker 0.2.1 → 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_worker.d.ts +1521 -441
- package/navara_wasm_worker.js +2106 -378
- package/navara_wasm_worker_bg.wasm +0 -0
- package/package.json +1 -1
package/navara_wasm_worker.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
|
*/
|
|
@@ -1226,6 +1538,7 @@ export class CompiledExpression {
|
|
|
1226
1538
|
* * `properties_json` - Feature properties as JSON object
|
|
1227
1539
|
* * `zoom` - Current zoom level
|
|
1228
1540
|
* * `geometry_type` - Optional geometry type string (e.g., "Point", "Polygon")
|
|
1541
|
+
* * `elevation` - Optional terrain elevation in meters for `["elevation"]`
|
|
1229
1542
|
*
|
|
1230
1543
|
* # Returns
|
|
1231
1544
|
* Evaluated value as JsValue. Supported types:
|
|
@@ -1238,12 +1551,13 @@ export class CompiledExpression {
|
|
|
1238
1551
|
* @param {any} properties_json
|
|
1239
1552
|
* @param {number} zoom
|
|
1240
1553
|
* @param {string | null} [geometry_type]
|
|
1554
|
+
* @param {number | null} [elevation]
|
|
1241
1555
|
* @returns {any}
|
|
1242
1556
|
*/
|
|
1243
|
-
evaluate(properties_json, zoom, geometry_type) {
|
|
1557
|
+
evaluate(properties_json, zoom, geometry_type, elevation) {
|
|
1244
1558
|
var ptr0 = isLikeNone(geometry_type) ? 0 : passStringToWasm0(geometry_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1245
1559
|
var len0 = WASM_VECTOR_LEN;
|
|
1246
|
-
const ret = wasm.compiledexpression_evaluate(this.__wbg_ptr, properties_json, zoom, ptr0, len0);
|
|
1560
|
+
const ret = wasm.compiledexpression_evaluate(this.__wbg_ptr, properties_json, zoom, ptr0, len0, !isLikeNone(elevation), isLikeNone(elevation) ? 0 : elevation);
|
|
1247
1561
|
if (ret[2]) {
|
|
1248
1562
|
throw takeFromExternrefTable0(ret[1]);
|
|
1249
1563
|
}
|
|
@@ -1681,15 +1995,15 @@ export class ConstructedPolylineGeometry {
|
|
|
1681
1995
|
/**
|
|
1682
1996
|
* @returns {Float32Array | undefined}
|
|
1683
1997
|
*/
|
|
1684
|
-
|
|
1685
|
-
const ret = wasm.
|
|
1998
|
+
end_normal_and_segment_length() {
|
|
1999
|
+
const ret = wasm.constructedpolylinegeometry_end_normal_and_segment_length(this.__wbg_ptr);
|
|
1686
2000
|
return ret;
|
|
1687
2001
|
}
|
|
1688
2002
|
/**
|
|
1689
2003
|
* @returns {number | undefined}
|
|
1690
2004
|
*/
|
|
1691
|
-
|
|
1692
|
-
const ret = wasm.
|
|
2005
|
+
end_normal_and_segment_length_size() {
|
|
2006
|
+
const ret = wasm.constructedpolylinegeometry_end_normal_and_segment_length_size(this.__wbg_ptr);
|
|
1693
2007
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
1694
2008
|
}
|
|
1695
2009
|
/**
|
|
@@ -1720,6 +2034,20 @@ export class ConstructedPolylineGeometry {
|
|
|
1720
2034
|
const ret = wasm.constructedpolylinegeometry_indices(this.__wbg_ptr);
|
|
1721
2035
|
return ret;
|
|
1722
2036
|
}
|
|
2037
|
+
/**
|
|
2038
|
+
* @returns {Float32Array | undefined}
|
|
2039
|
+
*/
|
|
2040
|
+
line_distance_and_ends() {
|
|
2041
|
+
const ret = wasm.constructedpolylinegeometry_line_distance_and_ends(this.__wbg_ptr);
|
|
2042
|
+
return ret;
|
|
2043
|
+
}
|
|
2044
|
+
/**
|
|
2045
|
+
* @returns {Float32Array | undefined}
|
|
2046
|
+
*/
|
|
2047
|
+
line_segments() {
|
|
2048
|
+
const ret = wasm.constructedpolylinegeometry_line_segments(this.__wbg_ptr);
|
|
2049
|
+
return ret;
|
|
2050
|
+
}
|
|
1723
2051
|
/**
|
|
1724
2052
|
* @returns {Float32Array}
|
|
1725
2053
|
*/
|
|
@@ -1765,15 +2093,15 @@ export class ConstructedPolylineGeometry {
|
|
|
1765
2093
|
/**
|
|
1766
2094
|
* @returns {Float32Array}
|
|
1767
2095
|
*/
|
|
1768
|
-
|
|
1769
|
-
const ret = wasm.
|
|
2096
|
+
right_normal_and_line_length() {
|
|
2097
|
+
const ret = wasm.constructedpolylinegeometry_right_normal_and_line_length(this.__wbg_ptr);
|
|
1770
2098
|
return ret;
|
|
1771
2099
|
}
|
|
1772
2100
|
/**
|
|
1773
2101
|
* @returns {number}
|
|
1774
2102
|
*/
|
|
1775
|
-
|
|
1776
|
-
const ret = wasm.
|
|
2103
|
+
right_normal_and_line_length_size() {
|
|
2104
|
+
const ret = wasm.constructedpolylinegeometry_right_normal_and_line_length_size(this.__wbg_ptr);
|
|
1777
2105
|
return ret;
|
|
1778
2106
|
}
|
|
1779
2107
|
/**
|
|
@@ -1814,15 +2142,15 @@ export class ConstructedPolylineGeometry {
|
|
|
1814
2142
|
/**
|
|
1815
2143
|
* @returns {Float32Array | undefined}
|
|
1816
2144
|
*/
|
|
1817
|
-
|
|
1818
|
-
const ret = wasm.
|
|
2145
|
+
start_normal_and_length_high() {
|
|
2146
|
+
const ret = wasm.constructedpolylinegeometry_start_normal_and_length_high(this.__wbg_ptr);
|
|
1819
2147
|
return ret;
|
|
1820
2148
|
}
|
|
1821
2149
|
/**
|
|
1822
2150
|
* @returns {number | undefined}
|
|
1823
2151
|
*/
|
|
1824
|
-
|
|
1825
|
-
const ret = wasm.
|
|
2152
|
+
start_normal_and_length_high_size() {
|
|
2153
|
+
const ret = wasm.constructedpolylinegeometry_start_normal_and_length_high_size(this.__wbg_ptr);
|
|
1826
2154
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
1827
2155
|
}
|
|
1828
2156
|
/**
|
|
@@ -2077,6 +2405,52 @@ export class ElevationHeatmapMaterial {
|
|
|
2077
2405
|
const ptr = this.__destroy_into_raw();
|
|
2078
2406
|
wasm.__wbg_elevationheatmapmaterial_free(ptr, 0);
|
|
2079
2407
|
}
|
|
2408
|
+
/**
|
|
2409
|
+
* Color map lookup table for this layer's elevation heatmap rendering.
|
|
2410
|
+
* Flattened RGBA array: [r0,g0,b0,a0, r1,g1,b1,a1, ...], evenly spaced over
|
|
2411
|
+
* [minHeight, maxHeight]. When None, the elevation renders as grayscale.
|
|
2412
|
+
* Managed on the web side (ColorMapAtlas); Rust only hashes it to detect
|
|
2413
|
+
* changes.
|
|
2414
|
+
* @returns {Float32Array | undefined}
|
|
2415
|
+
*/
|
|
2416
|
+
get colorMap() {
|
|
2417
|
+
const ret = wasm.__wbg_get_elevationheatmapmaterial_colorMap(this.__wbg_ptr);
|
|
2418
|
+
let v1;
|
|
2419
|
+
if (ret[0] !== 0) {
|
|
2420
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
2421
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2422
|
+
}
|
|
2423
|
+
return v1;
|
|
2424
|
+
}
|
|
2425
|
+
/**
|
|
2426
|
+
* Optional ascending stop elevations in meters, one per colorMap entry.
|
|
2427
|
+
* When set, colorMap entry i is placed at elevation colorStops[i] instead
|
|
2428
|
+
* of being evenly spaced over [minHeight, maxHeight].
|
|
2429
|
+
* Managed on the web side (ColorMapAtlas); Rust only hashes it to detect
|
|
2430
|
+
* changes.
|
|
2431
|
+
* @returns {Float32Array | undefined}
|
|
2432
|
+
*/
|
|
2433
|
+
get colorStops() {
|
|
2434
|
+
const ret = wasm.__wbg_get_elevationheatmapmaterial_colorStops(this.__wbg_ptr);
|
|
2435
|
+
let v1;
|
|
2436
|
+
if (ret[0] !== 0) {
|
|
2437
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
2438
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2439
|
+
}
|
|
2440
|
+
return v1;
|
|
2441
|
+
}
|
|
2442
|
+
/**
|
|
2443
|
+
* @returns {string | undefined}
|
|
2444
|
+
*/
|
|
2445
|
+
get filter() {
|
|
2446
|
+
const ret = wasm.__wbg_get_elevationheatmapmaterial_filter(this.__wbg_ptr);
|
|
2447
|
+
let v1;
|
|
2448
|
+
if (ret[0] !== 0) {
|
|
2449
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
2450
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
2451
|
+
}
|
|
2452
|
+
return v1;
|
|
2453
|
+
}
|
|
2080
2454
|
/**
|
|
2081
2455
|
* @returns {number | undefined}
|
|
2082
2456
|
*/
|
|
@@ -2105,6 +2479,40 @@ export class ElevationHeatmapMaterial {
|
|
|
2105
2479
|
const ret = wasm.__wbg_get_elevationheatmapmaterial_minHeight(this.__wbg_ptr);
|
|
2106
2480
|
return ret[0] === 0 ? undefined : ret[1];
|
|
2107
2481
|
}
|
|
2482
|
+
/**
|
|
2483
|
+
* Color map lookup table for this layer's elevation heatmap rendering.
|
|
2484
|
+
* Flattened RGBA array: [r0,g0,b0,a0, r1,g1,b1,a1, ...], evenly spaced over
|
|
2485
|
+
* [minHeight, maxHeight]. When None, the elevation renders as grayscale.
|
|
2486
|
+
* Managed on the web side (ColorMapAtlas); Rust only hashes it to detect
|
|
2487
|
+
* changes.
|
|
2488
|
+
* @param {Float32Array | null} [arg0]
|
|
2489
|
+
*/
|
|
2490
|
+
set colorMap(arg0) {
|
|
2491
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2492
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2493
|
+
wasm.__wbg_set_elevationheatmapmaterial_colorMap(this.__wbg_ptr, ptr0, len0);
|
|
2494
|
+
}
|
|
2495
|
+
/**
|
|
2496
|
+
* Optional ascending stop elevations in meters, one per colorMap entry.
|
|
2497
|
+
* When set, colorMap entry i is placed at elevation colorStops[i] instead
|
|
2498
|
+
* of being evenly spaced over [minHeight, maxHeight].
|
|
2499
|
+
* Managed on the web side (ColorMapAtlas); Rust only hashes it to detect
|
|
2500
|
+
* changes.
|
|
2501
|
+
* @param {Float32Array | null} [arg0]
|
|
2502
|
+
*/
|
|
2503
|
+
set colorStops(arg0) {
|
|
2504
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2505
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2506
|
+
wasm.__wbg_set_elevationheatmapmaterial_colorStops(this.__wbg_ptr, ptr0, len0);
|
|
2507
|
+
}
|
|
2508
|
+
/**
|
|
2509
|
+
* @param {string | null} [arg0]
|
|
2510
|
+
*/
|
|
2511
|
+
set filter(arg0) {
|
|
2512
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2513
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2514
|
+
wasm.__wbg_set_elevationheatmapmaterial_filter(this.__wbg_ptr, ptr0, len0);
|
|
2515
|
+
}
|
|
2108
2516
|
/**
|
|
2109
2517
|
* @param {number | null} [arg0]
|
|
2110
2518
|
*/
|
|
@@ -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
|
|
@@ -2973,19 +3364,12 @@ export class ModelMaterial {
|
|
|
2973
3364
|
/**
|
|
2974
3365
|
* @returns {boolean | undefined}
|
|
2975
3366
|
*/
|
|
2976
|
-
get
|
|
2977
|
-
const ret = wasm.
|
|
3367
|
+
get castShadow() {
|
|
3368
|
+
const ret = wasm.__wbg_get_modelmaterial_castShadow(this.__wbg_ptr);
|
|
2978
3369
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
2979
3370
|
}
|
|
2980
3371
|
/**
|
|
2981
|
-
* @returns {
|
|
2982
|
-
*/
|
|
2983
|
-
get castShadow() {
|
|
2984
|
-
const ret = wasm.__wbg_get_modelmaterial_castShadow(this.__wbg_ptr);
|
|
2985
|
-
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
2986
|
-
}
|
|
2987
|
-
/**
|
|
2988
|
-
* @returns {number | undefined}
|
|
3372
|
+
* @returns {number | undefined}
|
|
2989
3373
|
*/
|
|
2990
3374
|
get color() {
|
|
2991
3375
|
const ret = wasm.__wbg_get_modelmaterial_color(this.__wbg_ptr);
|
|
@@ -3037,6 +3421,15 @@ export class ModelMaterial {
|
|
|
3037
3421
|
const ret = wasm.__wbg_get_modelmaterial_emissiveIntensity(this.__wbg_ptr);
|
|
3038
3422
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3039
3423
|
}
|
|
3424
|
+
/**
|
|
3425
|
+
* Speed in m/s of the current carrying the water's waves
|
|
3426
|
+
* along `waveDirection`. Default: 0.
|
|
3427
|
+
* @returns {number | undefined}
|
|
3428
|
+
*/
|
|
3429
|
+
get flowSpeed() {
|
|
3430
|
+
const ret = wasm.__wbg_get_modelmaterial_flowSpeed(this.__wbg_ptr);
|
|
3431
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3432
|
+
}
|
|
3040
3433
|
/**
|
|
3041
3434
|
* @returns {number | undefined}
|
|
3042
3435
|
*/
|
|
@@ -3124,6 +3517,7 @@ export class ModelMaterial {
|
|
|
3124
3517
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3125
3518
|
}
|
|
3126
3519
|
/**
|
|
3520
|
+
* Phong shininess of the non-water `specular` highlight.
|
|
3127
3521
|
* @returns {number | undefined}
|
|
3128
3522
|
*/
|
|
3129
3523
|
get shininess() {
|
|
@@ -3167,6 +3561,7 @@ export class ModelMaterial {
|
|
|
3167
3561
|
}
|
|
3168
3562
|
/**
|
|
3169
3563
|
* Enabling this value allows using `shininess` and `specular_strength`.
|
|
3564
|
+
* Has no effect on water.
|
|
3170
3565
|
* @returns {boolean | undefined}
|
|
3171
3566
|
*/
|
|
3172
3567
|
get specular() {
|
|
@@ -3194,28 +3589,54 @@ export class ModelMaterial {
|
|
|
3194
3589
|
return v1;
|
|
3195
3590
|
}
|
|
3196
3591
|
/**
|
|
3197
|
-
*
|
|
3592
|
+
* Extent of the water body, which bounds how far the wind blows over it
|
|
3593
|
+
* and so how large its waves grow: `"ocean"` (the default; open sea),
|
|
3594
|
+
* `"large"` (a bay or a large lake, about 20 km), `"medium"` (a lake or a
|
|
3595
|
+
* wide river, about 2 km) or `"small"` (a river or a pond, about 200 m).
|
|
3596
|
+
* @returns {string | undefined}
|
|
3597
|
+
*/
|
|
3598
|
+
get waterScale() {
|
|
3599
|
+
const ret = wasm.__wbg_get_modelmaterial_waterScale(this.__wbg_ptr);
|
|
3600
|
+
let v1;
|
|
3601
|
+
if (ret[0] !== 0) {
|
|
3602
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
3603
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
3604
|
+
}
|
|
3605
|
+
return v1;
|
|
3606
|
+
}
|
|
3607
|
+
/**
|
|
3608
|
+
* Apply a water material on the polygon. It might slow down the loading of the mesh.
|
|
3609
|
+
* @returns {boolean | undefined}
|
|
3610
|
+
*/
|
|
3611
|
+
get water() {
|
|
3612
|
+
const ret = wasm.__wbg_get_modelmaterial_water(this.__wbg_ptr);
|
|
3613
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3614
|
+
}
|
|
3615
|
+
/**
|
|
3616
|
+
* Where the water's waves travel, in degrees clockwise from north.
|
|
3617
|
+
* Default: 0.
|
|
3198
3618
|
* @returns {number | undefined}
|
|
3199
3619
|
*/
|
|
3200
|
-
get
|
|
3201
|
-
const ret = wasm.
|
|
3620
|
+
get waveDirection() {
|
|
3621
|
+
const ret = wasm.__wbg_get_modelmaterial_waveDirection(this.__wbg_ptr);
|
|
3202
3622
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3203
3623
|
}
|
|
3204
3624
|
/**
|
|
3205
|
-
*
|
|
3625
|
+
* Scales the water's wave slopes; 0 is a flat mirror.
|
|
3206
3626
|
* @returns {number | undefined}
|
|
3207
3627
|
*/
|
|
3208
|
-
get
|
|
3209
|
-
const ret = wasm.
|
|
3628
|
+
get waveExaggeration() {
|
|
3629
|
+
const ret = wasm.__wbg_get_modelmaterial_waveExaggeration(this.__wbg_ptr);
|
|
3210
3630
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3211
3631
|
}
|
|
3212
3632
|
/**
|
|
3213
|
-
*
|
|
3214
|
-
*
|
|
3633
|
+
* Sets the size, steepness and speed of the water's waves: about 1 is a
|
|
3634
|
+
* calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
3635
|
+
* @returns {number | undefined}
|
|
3215
3636
|
*/
|
|
3216
|
-
get
|
|
3217
|
-
const ret = wasm.
|
|
3218
|
-
return ret ===
|
|
3637
|
+
get waveStrength() {
|
|
3638
|
+
const ret = wasm.__wbg_get_modelmaterial_waveStrength(this.__wbg_ptr);
|
|
3639
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3219
3640
|
}
|
|
3220
3641
|
/**
|
|
3221
3642
|
* @param {ModelInternalMaterial | null} [arg0]
|
|
@@ -3242,12 +3663,6 @@ export class ModelMaterial {
|
|
|
3242
3663
|
set animationSpeed(arg0) {
|
|
3243
3664
|
wasm.__wbg_set_modelmaterial_animationSpeed(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3244
3665
|
}
|
|
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
3666
|
/**
|
|
3252
3667
|
* @param {boolean | null} [arg0]
|
|
3253
3668
|
*/
|
|
@@ -3298,6 +3713,14 @@ export class ModelMaterial {
|
|
|
3298
3713
|
set emissiveIntensity(arg0) {
|
|
3299
3714
|
wasm.__wbg_set_modelmaterial_emissiveIntensity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3300
3715
|
}
|
|
3716
|
+
/**
|
|
3717
|
+
* Speed in m/s of the current carrying the water's waves
|
|
3718
|
+
* along `waveDirection`. Default: 0.
|
|
3719
|
+
* @param {number | null} [arg0]
|
|
3720
|
+
*/
|
|
3721
|
+
set flowSpeed(arg0) {
|
|
3722
|
+
wasm.__wbg_set_modelmaterial_flowSpeed(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3723
|
+
}
|
|
3301
3724
|
/**
|
|
3302
3725
|
* @param {number | null} [arg0]
|
|
3303
3726
|
*/
|
|
@@ -3374,6 +3797,7 @@ export class ModelMaterial {
|
|
|
3374
3797
|
wasm.__wbg_set_modelmaterial_roughness(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3375
3798
|
}
|
|
3376
3799
|
/**
|
|
3800
|
+
* Phong shininess of the non-water `specular` highlight.
|
|
3377
3801
|
* @param {number | null} [arg0]
|
|
3378
3802
|
*/
|
|
3379
3803
|
set shininess(arg0) {
|
|
@@ -3411,6 +3835,7 @@ export class ModelMaterial {
|
|
|
3411
3835
|
}
|
|
3412
3836
|
/**
|
|
3413
3837
|
* Enabling this value allows using `shininess` and `specular_strength`.
|
|
3838
|
+
* Has no effect on water.
|
|
3414
3839
|
* @param {boolean | null} [arg0]
|
|
3415
3840
|
*/
|
|
3416
3841
|
set specular(arg0) {
|
|
@@ -3432,25 +3857,46 @@ export class ModelMaterial {
|
|
|
3432
3857
|
wasm.__wbg_set_modelmaterial_url(this.__wbg_ptr, ptr0, len0);
|
|
3433
3858
|
}
|
|
3434
3859
|
/**
|
|
3435
|
-
*
|
|
3860
|
+
* Extent of the water body, which bounds how far the wind blows over it
|
|
3861
|
+
* and so how large its waves grow: `"ocean"` (the default; open sea),
|
|
3862
|
+
* `"large"` (a bay or a large lake, about 20 km), `"medium"` (a lake or a
|
|
3863
|
+
* wide river, about 2 km) or `"small"` (a river or a pond, about 200 m).
|
|
3864
|
+
* @param {string | null} [arg0]
|
|
3865
|
+
*/
|
|
3866
|
+
set waterScale(arg0) {
|
|
3867
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3868
|
+
var len0 = WASM_VECTOR_LEN;
|
|
3869
|
+
wasm.__wbg_set_modelmaterial_waterScale(this.__wbg_ptr, ptr0, len0);
|
|
3870
|
+
}
|
|
3871
|
+
/**
|
|
3872
|
+
* Apply a water material on the polygon. It might slow down the loading of the mesh.
|
|
3873
|
+
* @param {boolean | null} [arg0]
|
|
3874
|
+
*/
|
|
3875
|
+
set water(arg0) {
|
|
3876
|
+
wasm.__wbg_set_modelmaterial_water(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
3877
|
+
}
|
|
3878
|
+
/**
|
|
3879
|
+
* Where the water's waves travel, in degrees clockwise from north.
|
|
3880
|
+
* Default: 0.
|
|
3436
3881
|
* @param {number | null} [arg0]
|
|
3437
3882
|
*/
|
|
3438
|
-
set
|
|
3439
|
-
wasm.
|
|
3883
|
+
set waveDirection(arg0) {
|
|
3884
|
+
wasm.__wbg_set_modelmaterial_waveDirection(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3440
3885
|
}
|
|
3441
3886
|
/**
|
|
3442
|
-
*
|
|
3887
|
+
* Scales the water's wave slopes; 0 is a flat mirror.
|
|
3443
3888
|
* @param {number | null} [arg0]
|
|
3444
3889
|
*/
|
|
3445
|
-
set
|
|
3446
|
-
wasm.
|
|
3890
|
+
set waveExaggeration(arg0) {
|
|
3891
|
+
wasm.__wbg_set_modelmaterial_waveExaggeration(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3447
3892
|
}
|
|
3448
3893
|
/**
|
|
3449
|
-
*
|
|
3450
|
-
*
|
|
3894
|
+
* Sets the size, steepness and speed of the water's waves: about 1 is a
|
|
3895
|
+
* calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
3896
|
+
* @param {number | null} [arg0]
|
|
3451
3897
|
*/
|
|
3452
|
-
set
|
|
3453
|
-
wasm.
|
|
3898
|
+
set waveStrength(arg0) {
|
|
3899
|
+
wasm.__wbg_set_modelmaterial_waveStrength(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3454
3900
|
}
|
|
3455
3901
|
}
|
|
3456
3902
|
if (Symbol.dispose) ModelMaterial.prototype[Symbol.dispose] = ModelMaterial.prototype.free;
|
|
@@ -3576,25 +4022,31 @@ export class PointMaterial {
|
|
|
3576
4022
|
wasm.__wbg_pointmaterial_free(ptr, 0);
|
|
3577
4023
|
}
|
|
3578
4024
|
/**
|
|
3579
|
-
*
|
|
3580
|
-
*
|
|
3581
|
-
*
|
|
3582
|
-
*
|
|
4025
|
+
* Part of the quad placed at the anchor point: `"center"` (default),
|
|
4026
|
+
* `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`, `"top-right"`,
|
|
4027
|
+
* `"bottom-left"` or `"bottom-right"`, as MapLibre's `icon-anchor`.
|
|
4028
|
+
* @returns {string | undefined}
|
|
4029
|
+
*/
|
|
4030
|
+
get anchor() {
|
|
4031
|
+
const ret = wasm.__wbg_get_pointmaterial_anchor(this.__wbg_ptr);
|
|
4032
|
+
let v1;
|
|
4033
|
+
if (ret[0] !== 0) {
|
|
4034
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
4035
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
4036
|
+
}
|
|
4037
|
+
return v1;
|
|
4038
|
+
}
|
|
4039
|
+
/**
|
|
4040
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
4041
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
4042
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
4043
|
+
* camera.
|
|
3583
4044
|
* @returns {boolean | undefined}
|
|
3584
4045
|
*/
|
|
3585
4046
|
get backfaceCulling() {
|
|
3586
4047
|
const ret = wasm.__wbg_get_pointmaterial_backfaceCulling(this.__wbg_ptr);
|
|
3587
4048
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3588
4049
|
}
|
|
3589
|
-
/**
|
|
3590
|
-
* anchor point of the sprite, range is (-0.5, -0.5) to (0.5, 0.5).
|
|
3591
|
-
* Default is (0.0, 0.0) which means the center of the sprite.
|
|
3592
|
-
* @returns {Vec2 | undefined}
|
|
3593
|
-
*/
|
|
3594
|
-
get center() {
|
|
3595
|
-
const ret = wasm.__wbg_get_pointmaterial_center(this.__wbg_ptr);
|
|
3596
|
-
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
3597
|
-
}
|
|
3598
4050
|
/**
|
|
3599
4051
|
* @returns {boolean | undefined}
|
|
3600
4052
|
*/
|
|
@@ -3609,6 +4061,21 @@ export class PointMaterial {
|
|
|
3609
4061
|
const ret = wasm.__wbg_get_pointmaterial_color(this.__wbg_ptr);
|
|
3610
4062
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3611
4063
|
}
|
|
4064
|
+
/**
|
|
4065
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
4066
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
4067
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
4068
|
+
* @returns {Float32Array | undefined}
|
|
4069
|
+
*/
|
|
4070
|
+
get declutterPadding() {
|
|
4071
|
+
const ret = wasm.__wbg_get_pointmaterial_declutterPadding(this.__wbg_ptr);
|
|
4072
|
+
let v1;
|
|
4073
|
+
if (ret[0] !== 0) {
|
|
4074
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
4075
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
4076
|
+
}
|
|
4077
|
+
return v1;
|
|
4078
|
+
}
|
|
3612
4079
|
/**
|
|
3613
4080
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
3614
4081
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -3618,6 +4085,17 @@ export class PointMaterial {
|
|
|
3618
4085
|
const ret = wasm.__wbg_get_pointmaterial_declutterPriority(this.__wbg_ptr);
|
|
3619
4086
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3620
4087
|
}
|
|
4088
|
+
/**
|
|
4089
|
+
* Coarse placement order for decluttering, compared before
|
|
4090
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
4091
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
4092
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
4093
|
+
* @returns {number | undefined}
|
|
4094
|
+
*/
|
|
4095
|
+
get declutterRank() {
|
|
4096
|
+
const ret = wasm.__wbg_get_pointmaterial_declutterRank(this.__wbg_ptr);
|
|
4097
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4098
|
+
}
|
|
3621
4099
|
/**
|
|
3622
4100
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
3623
4101
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -3686,6 +4164,16 @@ export class PointMaterial {
|
|
|
3686
4164
|
const ret = wasm.__wbg_get_pointmaterial_height(this.__wbg_ptr);
|
|
3687
4165
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3688
4166
|
}
|
|
4167
|
+
/**
|
|
4168
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
4169
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
4170
|
+
* Defaults to `false`.
|
|
4171
|
+
* @returns {boolean | undefined}
|
|
4172
|
+
*/
|
|
4173
|
+
get ignorePlacement() {
|
|
4174
|
+
const ret = wasm.__wbg_get_pointmaterial_ignorePlacement(this.__wbg_ptr);
|
|
4175
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4176
|
+
}
|
|
3689
4177
|
/**
|
|
3690
4178
|
* Avoid overlapping with the globe surface.
|
|
3691
4179
|
* @returns {boolean | undefined}
|
|
@@ -3694,6 +4182,16 @@ export class PointMaterial {
|
|
|
3694
4182
|
const ret = wasm.__wbg_get_pointmaterial_offsetDepth(this.__wbg_ptr);
|
|
3695
4183
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3696
4184
|
}
|
|
4185
|
+
/**
|
|
4186
|
+
* Shift from the anchor point, x right and y down, in the unit of `size`
|
|
4187
|
+
* (meters when `sizeInMeters`, pixels otherwise). Lies in the quad's own
|
|
4188
|
+
* plane, so it turns with `rotation`. Defaults to `(0, 0)`.
|
|
4189
|
+
* @returns {Vec2 | undefined}
|
|
4190
|
+
*/
|
|
4191
|
+
get offset() {
|
|
4192
|
+
const ret = wasm.__wbg_get_pointmaterial_offset(this.__wbg_ptr);
|
|
4193
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
4194
|
+
}
|
|
3697
4195
|
/**
|
|
3698
4196
|
* @returns {number | undefined}
|
|
3699
4197
|
*/
|
|
@@ -3702,9 +4200,45 @@ export class PointMaterial {
|
|
|
3702
4200
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3703
4201
|
}
|
|
3704
4202
|
/**
|
|
3705
|
-
* Whether the
|
|
3706
|
-
*
|
|
3707
|
-
* `
|
|
4203
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
4204
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
4205
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
4206
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
4207
|
+
* @returns {string | undefined}
|
|
4208
|
+
*/
|
|
4209
|
+
get overlap() {
|
|
4210
|
+
const ret = wasm.__wbg_get_pointmaterial_overlap(this.__wbg_ptr);
|
|
4211
|
+
let v1;
|
|
4212
|
+
if (ret[0] !== 0) {
|
|
4213
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
4214
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
4215
|
+
}
|
|
4216
|
+
return v1;
|
|
4217
|
+
}
|
|
4218
|
+
/**
|
|
4219
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
4220
|
+
* default) puts one at every line and polygon-ring vertex, `"line"`
|
|
4221
|
+
* repeats them along the line every `spacing`, `"line-center"` places a
|
|
4222
|
+
* single one at the line's midpoint. Polygon rings are walked like lines. Requires `geometryTypes`
|
|
4223
|
+
* to include `"line"` or `"polygon"`.
|
|
4224
|
+
* @returns {string | undefined}
|
|
4225
|
+
*/
|
|
4226
|
+
get placement() {
|
|
4227
|
+
const ret = wasm.__wbg_get_pointmaterial_placement(this.__wbg_ptr);
|
|
4228
|
+
let v1;
|
|
4229
|
+
if (ret[0] !== 0) {
|
|
4230
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
4231
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
4232
|
+
}
|
|
4233
|
+
return v1;
|
|
4234
|
+
}
|
|
4235
|
+
/**
|
|
4236
|
+
* Plane the point lies in: the screen (`"upright"`, never foreshortened)
|
|
4237
|
+
* or the globe surface around its anchor (`"flat"`), as MapLibre's
|
|
4238
|
+
* `icon-pitch-alignment` `viewport` and `map`. Pair with
|
|
4239
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
4240
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
4241
|
+
* `auto`.
|
|
3708
4242
|
* @returns {string | undefined}
|
|
3709
4243
|
*/
|
|
3710
4244
|
get pointFacing() {
|
|
@@ -3717,9 +4251,22 @@ export class PointMaterial {
|
|
|
3717
4251
|
return v1;
|
|
3718
4252
|
}
|
|
3719
4253
|
/**
|
|
3720
|
-
*
|
|
3721
|
-
*
|
|
3722
|
-
*
|
|
4254
|
+
* Add the line's tangent bearing at the anchor to `rotation`, so the
|
|
4255
|
+
* sprite turns with the line it sits on. Defaults to `true`.
|
|
4256
|
+
* @returns {boolean | undefined}
|
|
4257
|
+
*/
|
|
4258
|
+
get rotateToLine() {
|
|
4259
|
+
const ret = wasm.__wbg_get_pointmaterial_rotateToLine(this.__wbg_ptr);
|
|
4260
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4261
|
+
}
|
|
4262
|
+
/**
|
|
4263
|
+
* Whether the point turns with the camera or with the map, as MapLibre's
|
|
4264
|
+
* `icon-rotation-alignment` `viewport` and `map`. `true` keeps it reading left to right
|
|
4265
|
+
* (a screen-aligned billboard, or a flat quad yawed to the camera).
|
|
4266
|
+
* `false` aligns it with the map: upright, it stays on screen but turns
|
|
4267
|
+
* with the camera heading so its x-axis points east; flat, it lies
|
|
4268
|
+
* north-up. Left unset, it is `true` for `placement: "point"` and `false`
|
|
4269
|
+
* along a line, as MapLibre resolves `auto`.
|
|
3723
4270
|
* @returns {boolean | undefined}
|
|
3724
4271
|
*/
|
|
3725
4272
|
get rotateWithCamera() {
|
|
@@ -3728,7 +4275,7 @@ export class PointMaterial {
|
|
|
3728
4275
|
}
|
|
3729
4276
|
/**
|
|
3730
4277
|
* Rotation of the point within its own plane, about its anchor point, in
|
|
3731
|
-
* degrees, clockwise seen from the front. `
|
|
4278
|
+
* degrees, clockwise seen from the front. `anchor` decides where inside
|
|
3732
4279
|
* the quad the pivot sits. Defaults to `0.0`.
|
|
3733
4280
|
* @returns {number | undefined}
|
|
3734
4281
|
*/
|
|
@@ -3759,6 +4306,47 @@ export class PointMaterial {
|
|
|
3759
4306
|
const ret = wasm.__wbg_get_pointmaterial_size(this.__wbg_ptr);
|
|
3760
4307
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
3761
4308
|
}
|
|
4309
|
+
/**
|
|
4310
|
+
* Distance between repeated anchors along a line, in screen pixels, for
|
|
4311
|
+
* `vector-tile` and `geojson` sources alike. Resolved per anchor as the
|
|
4312
|
+
* camera moves: anchors thin out as it pulls back and fill in as it
|
|
4313
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
4314
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
4315
|
+
* `symbol-spacing`, a sprite wider than three quarters of the spacing
|
|
4316
|
+
* spreads its repeats to its width plus a quarter of the spacing, and a
|
|
4317
|
+
* vector tile places anchors only inside its own bounds. Only used by
|
|
4318
|
+
* `placement: "line"`. Defaults to `250.0`.
|
|
4319
|
+
* @returns {number | undefined}
|
|
4320
|
+
*/
|
|
4321
|
+
get spacing() {
|
|
4322
|
+
const ret = wasm.__wbg_get_pointmaterial_spacing(this.__wbg_ptr);
|
|
4323
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4324
|
+
}
|
|
4325
|
+
/**
|
|
4326
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
4327
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
4328
|
+
* the screen axes. MapLibre's `icon-translate-anchor`.
|
|
4329
|
+
* @returns {string | undefined}
|
|
4330
|
+
*/
|
|
4331
|
+
get translateAnchor() {
|
|
4332
|
+
const ret = wasm.__wbg_get_pointmaterial_translateAnchor(this.__wbg_ptr);
|
|
4333
|
+
let v1;
|
|
4334
|
+
if (ret[0] !== 0) {
|
|
4335
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
4336
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
4337
|
+
}
|
|
4338
|
+
return v1;
|
|
4339
|
+
}
|
|
4340
|
+
/**
|
|
4341
|
+
* Screen-pixel shift of the drawn quad, x right and y down, applied after
|
|
4342
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
4343
|
+
* MapLibre's `icon-translate`. Defaults to `(0, 0)`.
|
|
4344
|
+
* @returns {Vec2 | undefined}
|
|
4345
|
+
*/
|
|
4346
|
+
get translate() {
|
|
4347
|
+
const ret = wasm.__wbg_get_pointmaterial_translate(this.__wbg_ptr);
|
|
4348
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
4349
|
+
}
|
|
3762
4350
|
/**
|
|
3763
4351
|
* @returns {boolean | undefined}
|
|
3764
4352
|
*/
|
|
@@ -3767,27 +4355,25 @@ export class PointMaterial {
|
|
|
3767
4355
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3768
4356
|
}
|
|
3769
4357
|
/**
|
|
3770
|
-
*
|
|
3771
|
-
*
|
|
3772
|
-
*
|
|
3773
|
-
*
|
|
3774
|
-
* @param {boolean | null} [arg0]
|
|
4358
|
+
* Part of the quad placed at the anchor point: `"center"` (default),
|
|
4359
|
+
* `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`, `"top-right"`,
|
|
4360
|
+
* `"bottom-left"` or `"bottom-right"`, as MapLibre's `icon-anchor`.
|
|
4361
|
+
* @param {string | null} [arg0]
|
|
3775
4362
|
*/
|
|
3776
|
-
set
|
|
3777
|
-
|
|
4363
|
+
set anchor(arg0) {
|
|
4364
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4365
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4366
|
+
wasm.__wbg_set_pointmaterial_anchor(this.__wbg_ptr, ptr0, len0);
|
|
3778
4367
|
}
|
|
3779
4368
|
/**
|
|
3780
|
-
*
|
|
3781
|
-
*
|
|
3782
|
-
*
|
|
4369
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
4370
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
4371
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
4372
|
+
* camera.
|
|
4373
|
+
* @param {boolean | null} [arg0]
|
|
3783
4374
|
*/
|
|
3784
|
-
set
|
|
3785
|
-
|
|
3786
|
-
if (!isLikeNone(arg0)) {
|
|
3787
|
-
_assertClass(arg0, Vec2);
|
|
3788
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
3789
|
-
}
|
|
3790
|
-
wasm.__wbg_set_pointmaterial_center(this.__wbg_ptr, ptr0);
|
|
4375
|
+
set backfaceCulling(arg0) {
|
|
4376
|
+
wasm.__wbg_set_pointmaterial_backfaceCulling(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
3791
4377
|
}
|
|
3792
4378
|
/**
|
|
3793
4379
|
* @param {boolean | null} [arg0]
|
|
@@ -3801,6 +4387,17 @@ export class PointMaterial {
|
|
|
3801
4387
|
set color(arg0) {
|
|
3802
4388
|
wasm.__wbg_set_pointmaterial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
3803
4389
|
}
|
|
4390
|
+
/**
|
|
4391
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
4392
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
4393
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
4394
|
+
* @param {Float32Array | null} [arg0]
|
|
4395
|
+
*/
|
|
4396
|
+
set declutterPadding(arg0) {
|
|
4397
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
4398
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4399
|
+
wasm.__wbg_set_pointmaterial_declutterPadding(this.__wbg_ptr, ptr0, len0);
|
|
4400
|
+
}
|
|
3804
4401
|
/**
|
|
3805
4402
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
3806
4403
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -3809,6 +4406,16 @@ export class PointMaterial {
|
|
|
3809
4406
|
set declutterPriority(arg0) {
|
|
3810
4407
|
wasm.__wbg_set_pointmaterial_declutterPriority(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3811
4408
|
}
|
|
4409
|
+
/**
|
|
4410
|
+
* Coarse placement order for decluttering, compared before
|
|
4411
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
4412
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
4413
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
4414
|
+
* @param {number | null} [arg0]
|
|
4415
|
+
*/
|
|
4416
|
+
set declutterRank(arg0) {
|
|
4417
|
+
wasm.__wbg_set_pointmaterial_declutterRank(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4418
|
+
}
|
|
3812
4419
|
/**
|
|
3813
4420
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
3814
4421
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -3864,6 +4471,15 @@ export class PointMaterial {
|
|
|
3864
4471
|
set height(arg0) {
|
|
3865
4472
|
wasm.__wbg_set_pointmaterial_height(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3866
4473
|
}
|
|
4474
|
+
/**
|
|
4475
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
4476
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
4477
|
+
* Defaults to `false`.
|
|
4478
|
+
* @param {boolean | null} [arg0]
|
|
4479
|
+
*/
|
|
4480
|
+
set ignorePlacement(arg0) {
|
|
4481
|
+
wasm.__wbg_set_pointmaterial_ignorePlacement(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4482
|
+
}
|
|
3867
4483
|
/**
|
|
3868
4484
|
* Avoid overlapping with the globe surface.
|
|
3869
4485
|
* @param {boolean | null} [arg0]
|
|
@@ -3871,6 +4487,20 @@ export class PointMaterial {
|
|
|
3871
4487
|
set offsetDepth(arg0) {
|
|
3872
4488
|
wasm.__wbg_set_pointmaterial_offsetDepth(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
3873
4489
|
}
|
|
4490
|
+
/**
|
|
4491
|
+
* Shift from the anchor point, x right and y down, in the unit of `size`
|
|
4492
|
+
* (meters when `sizeInMeters`, pixels otherwise). Lies in the quad's own
|
|
4493
|
+
* plane, so it turns with `rotation`. Defaults to `(0, 0)`.
|
|
4494
|
+
* @param {Vec2 | null} [arg0]
|
|
4495
|
+
*/
|
|
4496
|
+
set offset(arg0) {
|
|
4497
|
+
let ptr0 = 0;
|
|
4498
|
+
if (!isLikeNone(arg0)) {
|
|
4499
|
+
_assertClass(arg0, Vec2);
|
|
4500
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
4501
|
+
}
|
|
4502
|
+
wasm.__wbg_set_pointmaterial_offset(this.__wbg_ptr, ptr0);
|
|
4503
|
+
}
|
|
3874
4504
|
/**
|
|
3875
4505
|
* @param {number | null} [arg0]
|
|
3876
4506
|
*/
|
|
@@ -3878,9 +4508,37 @@ export class PointMaterial {
|
|
|
3878
4508
|
wasm.__wbg_set_pointmaterial_opacity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3879
4509
|
}
|
|
3880
4510
|
/**
|
|
3881
|
-
* Whether the
|
|
3882
|
-
*
|
|
3883
|
-
* `
|
|
4511
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
4512
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
4513
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
4514
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
4515
|
+
* @param {string | null} [arg0]
|
|
4516
|
+
*/
|
|
4517
|
+
set overlap(arg0) {
|
|
4518
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4519
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4520
|
+
wasm.__wbg_set_pointmaterial_overlap(this.__wbg_ptr, ptr0, len0);
|
|
4521
|
+
}
|
|
4522
|
+
/**
|
|
4523
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
4524
|
+
* default) puts one at every line and polygon-ring vertex, `"line"`
|
|
4525
|
+
* repeats them along the line every `spacing`, `"line-center"` places a
|
|
4526
|
+
* single one at the line's midpoint. Polygon rings are walked like lines. Requires `geometryTypes`
|
|
4527
|
+
* to include `"line"` or `"polygon"`.
|
|
4528
|
+
* @param {string | null} [arg0]
|
|
4529
|
+
*/
|
|
4530
|
+
set placement(arg0) {
|
|
4531
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4532
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4533
|
+
wasm.__wbg_set_pointmaterial_placement(this.__wbg_ptr, ptr0, len0);
|
|
4534
|
+
}
|
|
4535
|
+
/**
|
|
4536
|
+
* Plane the point lies in: the screen (`"upright"`, never foreshortened)
|
|
4537
|
+
* or the globe surface around its anchor (`"flat"`), as MapLibre's
|
|
4538
|
+
* `icon-pitch-alignment` `viewport` and `map`. Pair with
|
|
4539
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
4540
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
4541
|
+
* `auto`.
|
|
3884
4542
|
* @param {string | null} [arg0]
|
|
3885
4543
|
*/
|
|
3886
4544
|
set pointFacing(arg0) {
|
|
@@ -3889,9 +4547,21 @@ export class PointMaterial {
|
|
|
3889
4547
|
wasm.__wbg_set_pointmaterial_pointFacing(this.__wbg_ptr, ptr0, len0);
|
|
3890
4548
|
}
|
|
3891
4549
|
/**
|
|
3892
|
-
*
|
|
3893
|
-
*
|
|
3894
|
-
*
|
|
4550
|
+
* Add the line's tangent bearing at the anchor to `rotation`, so the
|
|
4551
|
+
* sprite turns with the line it sits on. Defaults to `true`.
|
|
4552
|
+
* @param {boolean | null} [arg0]
|
|
4553
|
+
*/
|
|
4554
|
+
set rotateToLine(arg0) {
|
|
4555
|
+
wasm.__wbg_set_pointmaterial_rotateToLine(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4556
|
+
}
|
|
4557
|
+
/**
|
|
4558
|
+
* Whether the point turns with the camera or with the map, as MapLibre's
|
|
4559
|
+
* `icon-rotation-alignment` `viewport` and `map`. `true` keeps it reading left to right
|
|
4560
|
+
* (a screen-aligned billboard, or a flat quad yawed to the camera).
|
|
4561
|
+
* `false` aligns it with the map: upright, it stays on screen but turns
|
|
4562
|
+
* with the camera heading so its x-axis points east; flat, it lies
|
|
4563
|
+
* north-up. Left unset, it is `true` for `placement: "point"` and `false`
|
|
4564
|
+
* along a line, as MapLibre resolves `auto`.
|
|
3895
4565
|
* @param {boolean | null} [arg0]
|
|
3896
4566
|
*/
|
|
3897
4567
|
set rotateWithCamera(arg0) {
|
|
@@ -3899,7 +4569,7 @@ export class PointMaterial {
|
|
|
3899
4569
|
}
|
|
3900
4570
|
/**
|
|
3901
4571
|
* Rotation of the point within its own plane, about its anchor point, in
|
|
3902
|
-
* degrees, clockwise seen from the front. `
|
|
4572
|
+
* degrees, clockwise seen from the front. `anchor` decides where inside
|
|
3903
4573
|
* the quad the pivot sits. Defaults to `0.0`.
|
|
3904
4574
|
* @param {number | null} [arg0]
|
|
3905
4575
|
*/
|
|
@@ -3926,6 +4596,46 @@ export class PointMaterial {
|
|
|
3926
4596
|
set size(arg0) {
|
|
3927
4597
|
wasm.__wbg_set_pointmaterial_size(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
3928
4598
|
}
|
|
4599
|
+
/**
|
|
4600
|
+
* Distance between repeated anchors along a line, in screen pixels, for
|
|
4601
|
+
* `vector-tile` and `geojson` sources alike. Resolved per anchor as the
|
|
4602
|
+
* camera moves: anchors thin out as it pulls back and fill in as it
|
|
4603
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
4604
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
4605
|
+
* `symbol-spacing`, a sprite wider than three quarters of the spacing
|
|
4606
|
+
* spreads its repeats to its width plus a quarter of the spacing, and a
|
|
4607
|
+
* vector tile places anchors only inside its own bounds. Only used by
|
|
4608
|
+
* `placement: "line"`. Defaults to `250.0`.
|
|
4609
|
+
* @param {number | null} [arg0]
|
|
4610
|
+
*/
|
|
4611
|
+
set spacing(arg0) {
|
|
4612
|
+
wasm.__wbg_set_pointmaterial_spacing(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4613
|
+
}
|
|
4614
|
+
/**
|
|
4615
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
4616
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
4617
|
+
* the screen axes. MapLibre's `icon-translate-anchor`.
|
|
4618
|
+
* @param {string | null} [arg0]
|
|
4619
|
+
*/
|
|
4620
|
+
set translateAnchor(arg0) {
|
|
4621
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4622
|
+
var len0 = WASM_VECTOR_LEN;
|
|
4623
|
+
wasm.__wbg_set_pointmaterial_translateAnchor(this.__wbg_ptr, ptr0, len0);
|
|
4624
|
+
}
|
|
4625
|
+
/**
|
|
4626
|
+
* Screen-pixel shift of the drawn quad, x right and y down, applied after
|
|
4627
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
4628
|
+
* MapLibre's `icon-translate`. Defaults to `(0, 0)`.
|
|
4629
|
+
* @param {Vec2 | null} [arg0]
|
|
4630
|
+
*/
|
|
4631
|
+
set translate(arg0) {
|
|
4632
|
+
let ptr0 = 0;
|
|
4633
|
+
if (!isLikeNone(arg0)) {
|
|
4634
|
+
_assertClass(arg0, Vec2);
|
|
4635
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
4636
|
+
}
|
|
4637
|
+
wasm.__wbg_set_pointmaterial_translate(this.__wbg_ptr, ptr0);
|
|
4638
|
+
}
|
|
3929
4639
|
/**
|
|
3930
4640
|
* @param {boolean | null} [arg0]
|
|
3931
4641
|
*/
|
|
@@ -4221,13 +4931,6 @@ export class PolygonMaterial {
|
|
|
4221
4931
|
const ret = wasm.__wbg_get_polygonmaterial___internal__(this.__wbg_ptr);
|
|
4222
4932
|
return ret === 0 ? undefined : PolygonInternalMaterial.__wrap(ret);
|
|
4223
4933
|
}
|
|
4224
|
-
/**
|
|
4225
|
-
* @returns {boolean | undefined}
|
|
4226
|
-
*/
|
|
4227
|
-
get applyWaterNormal() {
|
|
4228
|
-
const ret = wasm.__wbg_get_polygonmaterial_applyWaterNormal(this.__wbg_ptr);
|
|
4229
|
-
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4230
|
-
}
|
|
4231
4934
|
/**
|
|
4232
4935
|
* @returns {boolean | undefined}
|
|
4233
4936
|
*/
|
|
@@ -4249,6 +4952,14 @@ export class PolygonMaterial {
|
|
|
4249
4952
|
const ret = wasm.__wbg_get_polygonmaterial_color(this.__wbg_ptr);
|
|
4250
4953
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4251
4954
|
}
|
|
4955
|
+
/**
|
|
4956
|
+
* Write depth before blending so a transparent layer blends only its nearest surface.
|
|
4957
|
+
* @returns {boolean | undefined}
|
|
4958
|
+
*/
|
|
4959
|
+
get depthPrePass() {
|
|
4960
|
+
const ret = wasm.__wbg_get_polygonmaterial_depthPrePass(this.__wbg_ptr);
|
|
4961
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4962
|
+
}
|
|
4252
4963
|
/**
|
|
4253
4964
|
* IDs of selective effects to apply (e.g., "bloom", "outline")
|
|
4254
4965
|
* @returns {string[] | undefined}
|
|
@@ -4285,6 +4996,15 @@ export class PolygonMaterial {
|
|
|
4285
4996
|
const ret = wasm.__wbg_get_polygonmaterial_extrudedHeight(this.__wbg_ptr);
|
|
4286
4997
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4287
4998
|
}
|
|
4999
|
+
/**
|
|
5000
|
+
* Speed in m/s of the current carrying the water's waves
|
|
5001
|
+
* along `waveDirection`. Default: 0.
|
|
5002
|
+
* @returns {number | undefined}
|
|
5003
|
+
*/
|
|
5004
|
+
get flowSpeed() {
|
|
5005
|
+
const ret = wasm.__wbg_get_polygonmaterial_flowSpeed(this.__wbg_ptr);
|
|
5006
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
5007
|
+
}
|
|
4288
5008
|
/**
|
|
4289
5009
|
* @returns {number | undefined}
|
|
4290
5010
|
*/
|
|
@@ -4382,6 +5102,15 @@ export class PolygonMaterial {
|
|
|
4382
5102
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4383
5103
|
}
|
|
4384
5104
|
/**
|
|
5105
|
+
* Shade the extruded sides with the surface normal instead of their own.
|
|
5106
|
+
* @returns {boolean | undefined}
|
|
5107
|
+
*/
|
|
5108
|
+
get shadeSidesAsSurface() {
|
|
5109
|
+
const ret = wasm.__wbg_get_polygonmaterial_shadeSidesAsSurface(this.__wbg_ptr);
|
|
5110
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5111
|
+
}
|
|
5112
|
+
/**
|
|
5113
|
+
* Phong shininess of the non-water `specular` highlight.
|
|
4385
5114
|
* @returns {number | undefined}
|
|
4386
5115
|
*/
|
|
4387
5116
|
get shininess() {
|
|
@@ -4404,6 +5133,7 @@ export class PolygonMaterial {
|
|
|
4404
5133
|
}
|
|
4405
5134
|
/**
|
|
4406
5135
|
* Enabling this value allows using `shininess` and `specular_strength`.
|
|
5136
|
+
* Has no effect on water.
|
|
4407
5137
|
* @returns {boolean | undefined}
|
|
4408
5138
|
*/
|
|
4409
5139
|
get specular() {
|
|
@@ -4440,28 +5170,54 @@ export class PolygonMaterial {
|
|
|
4440
5170
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
4441
5171
|
}
|
|
4442
5172
|
/**
|
|
4443
|
-
*
|
|
4444
|
-
*
|
|
5173
|
+
* Extent of the water body, which bounds how far the wind blows over it
|
|
5174
|
+
* and so how large its waves grow: `"ocean"` (the default; open sea),
|
|
5175
|
+
* `"large"` (a bay or a large lake, about 20 km), `"medium"` (a lake or a
|
|
5176
|
+
* wide river, about 2 km) or `"small"` (a river or a pond, about 200 m).
|
|
5177
|
+
* @returns {string | undefined}
|
|
4445
5178
|
*/
|
|
4446
|
-
get
|
|
4447
|
-
const ret = wasm.
|
|
4448
|
-
|
|
5179
|
+
get waterScale() {
|
|
5180
|
+
const ret = wasm.__wbg_get_polygonmaterial_waterScale(this.__wbg_ptr);
|
|
5181
|
+
let v1;
|
|
5182
|
+
if (ret[0] !== 0) {
|
|
5183
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
5184
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
5185
|
+
}
|
|
5186
|
+
return v1;
|
|
4449
5187
|
}
|
|
4450
5188
|
/**
|
|
4451
|
-
*
|
|
4452
|
-
* @returns {
|
|
5189
|
+
* Apply a water material on the polygon. It might slow down the loading of the mesh.
|
|
5190
|
+
* @returns {boolean | undefined}
|
|
4453
5191
|
*/
|
|
4454
|
-
get
|
|
4455
|
-
const ret = wasm.
|
|
5192
|
+
get water() {
|
|
5193
|
+
const ret = wasm.__wbg_get_polygonmaterial_water(this.__wbg_ptr);
|
|
5194
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5195
|
+
}
|
|
5196
|
+
/**
|
|
5197
|
+
* Where the water's waves travel, in degrees clockwise from north.
|
|
5198
|
+
* Default: 0.
|
|
5199
|
+
* @returns {number | undefined}
|
|
5200
|
+
*/
|
|
5201
|
+
get waveDirection() {
|
|
5202
|
+
const ret = wasm.__wbg_get_polygonmaterial_waveDirection(this.__wbg_ptr);
|
|
4456
5203
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4457
5204
|
}
|
|
4458
5205
|
/**
|
|
4459
|
-
*
|
|
4460
|
-
* @returns {
|
|
5206
|
+
* Scales the water's wave slopes; 0 is a flat mirror.
|
|
5207
|
+
* @returns {number | undefined}
|
|
4461
5208
|
*/
|
|
4462
|
-
get
|
|
4463
|
-
const ret = wasm.
|
|
4464
|
-
return ret ===
|
|
5209
|
+
get waveExaggeration() {
|
|
5210
|
+
const ret = wasm.__wbg_get_polygonmaterial_waveExaggeration(this.__wbg_ptr);
|
|
5211
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
5212
|
+
}
|
|
5213
|
+
/**
|
|
5214
|
+
* Sets the size, steepness and speed of the water's waves: about 1 is a
|
|
5215
|
+
* calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
5216
|
+
* @returns {number | undefined}
|
|
5217
|
+
*/
|
|
5218
|
+
get waveStrength() {
|
|
5219
|
+
const ret = wasm.__wbg_get_polygonmaterial_waveStrength(this.__wbg_ptr);
|
|
5220
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
4465
5221
|
}
|
|
4466
5222
|
/**
|
|
4467
5223
|
* @returns {boolean | undefined}
|
|
@@ -4506,12 +5262,6 @@ export class PolygonMaterial {
|
|
|
4506
5262
|
}
|
|
4507
5263
|
wasm.__wbg_set_polygonmaterial___internal__(this.__wbg_ptr, ptr0);
|
|
4508
5264
|
}
|
|
4509
|
-
/**
|
|
4510
|
-
* @param {boolean | null} [arg0]
|
|
4511
|
-
*/
|
|
4512
|
-
set applyWaterNormal(arg0) {
|
|
4513
|
-
wasm.__wbg_set_polygonmaterial_applyWaterNormal(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4514
|
-
}
|
|
4515
5265
|
/**
|
|
4516
5266
|
* @param {boolean | null} [arg0]
|
|
4517
5267
|
*/
|
|
@@ -4530,6 +5280,13 @@ export class PolygonMaterial {
|
|
|
4530
5280
|
set color(arg0) {
|
|
4531
5281
|
wasm.__wbg_set_polygonmaterial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
4532
5282
|
}
|
|
5283
|
+
/**
|
|
5284
|
+
* Write depth before blending so a transparent layer blends only its nearest surface.
|
|
5285
|
+
* @param {boolean | null} [arg0]
|
|
5286
|
+
*/
|
|
5287
|
+
set depthPrePass(arg0) {
|
|
5288
|
+
wasm.__wbg_set_polygonmaterial_depthPrePass(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
5289
|
+
}
|
|
4533
5290
|
/**
|
|
4534
5291
|
* IDs of selective effects to apply (e.g., "bloom", "outline")
|
|
4535
5292
|
* @param {string[] | null} [arg0]
|
|
@@ -4559,6 +5316,14 @@ export class PolygonMaterial {
|
|
|
4559
5316
|
set extrudedHeight(arg0) {
|
|
4560
5317
|
wasm.__wbg_set_polygonmaterial_extrudedHeight(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4561
5318
|
}
|
|
5319
|
+
/**
|
|
5320
|
+
* Speed in m/s of the current carrying the water's waves
|
|
5321
|
+
* along `waveDirection`. Default: 0.
|
|
5322
|
+
* @param {number | null} [arg0]
|
|
5323
|
+
*/
|
|
5324
|
+
set flowSpeed(arg0) {
|
|
5325
|
+
wasm.__wbg_set_polygonmaterial_flowSpeed(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
5326
|
+
}
|
|
4562
5327
|
/**
|
|
4563
5328
|
* @param {number | null} [arg0]
|
|
4564
5329
|
*/
|
|
@@ -4644,6 +5409,14 @@ export class PolygonMaterial {
|
|
|
4644
5409
|
wasm.__wbg_set_polygonmaterial_roughness(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4645
5410
|
}
|
|
4646
5411
|
/**
|
|
5412
|
+
* Shade the extruded sides with the surface normal instead of their own.
|
|
5413
|
+
* @param {boolean | null} [arg0]
|
|
5414
|
+
*/
|
|
5415
|
+
set shadeSidesAsSurface(arg0) {
|
|
5416
|
+
wasm.__wbg_set_polygonmaterial_shadeSidesAsSurface(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
5417
|
+
}
|
|
5418
|
+
/**
|
|
5419
|
+
* Phong shininess of the non-water `specular` highlight.
|
|
4647
5420
|
* @param {number | null} [arg0]
|
|
4648
5421
|
*/
|
|
4649
5422
|
set shininess(arg0) {
|
|
@@ -4663,6 +5436,7 @@ export class PolygonMaterial {
|
|
|
4663
5436
|
}
|
|
4664
5437
|
/**
|
|
4665
5438
|
* Enabling this value allows using `shininess` and `specular_strength`.
|
|
5439
|
+
* Has no effect on water.
|
|
4666
5440
|
* @param {boolean | null} [arg0]
|
|
4667
5441
|
*/
|
|
4668
5442
|
set specular(arg0) {
|
|
@@ -4695,25 +5469,46 @@ export class PolygonMaterial {
|
|
|
4695
5469
|
wasm.__wbg_set_polygonmaterial_transparent(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
4696
5470
|
}
|
|
4697
5471
|
/**
|
|
4698
|
-
*
|
|
5472
|
+
* Extent of the water body, which bounds how far the wind blows over it
|
|
5473
|
+
* and so how large its waves grow: `"ocean"` (the default; open sea),
|
|
5474
|
+
* `"large"` (a bay or a large lake, about 20 km), `"medium"` (a lake or a
|
|
5475
|
+
* wide river, about 2 km) or `"small"` (a river or a pond, about 200 m).
|
|
5476
|
+
* @param {string | null} [arg0]
|
|
5477
|
+
*/
|
|
5478
|
+
set waterScale(arg0) {
|
|
5479
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
5480
|
+
var len0 = WASM_VECTOR_LEN;
|
|
5481
|
+
wasm.__wbg_set_polygonmaterial_waterScale(this.__wbg_ptr, ptr0, len0);
|
|
5482
|
+
}
|
|
5483
|
+
/**
|
|
5484
|
+
* Apply a water material on the polygon. It might slow down the loading of the mesh.
|
|
5485
|
+
* @param {boolean | null} [arg0]
|
|
5486
|
+
*/
|
|
5487
|
+
set water(arg0) {
|
|
5488
|
+
wasm.__wbg_set_polygonmaterial_water(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
5489
|
+
}
|
|
5490
|
+
/**
|
|
5491
|
+
* Where the water's waves travel, in degrees clockwise from north.
|
|
5492
|
+
* Default: 0.
|
|
4699
5493
|
* @param {number | null} [arg0]
|
|
4700
5494
|
*/
|
|
4701
|
-
set
|
|
4702
|
-
wasm.
|
|
5495
|
+
set waveDirection(arg0) {
|
|
5496
|
+
wasm.__wbg_set_polygonmaterial_waveDirection(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4703
5497
|
}
|
|
4704
5498
|
/**
|
|
4705
|
-
*
|
|
5499
|
+
* Scales the water's wave slopes; 0 is a flat mirror.
|
|
4706
5500
|
* @param {number | null} [arg0]
|
|
4707
5501
|
*/
|
|
4708
|
-
set
|
|
4709
|
-
wasm.
|
|
5502
|
+
set waveExaggeration(arg0) {
|
|
5503
|
+
wasm.__wbg_set_polygonmaterial_waveExaggeration(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4710
5504
|
}
|
|
4711
5505
|
/**
|
|
4712
|
-
*
|
|
4713
|
-
*
|
|
5506
|
+
* Sets the size, steepness and speed of the water's waves: about 1 is a
|
|
5507
|
+
* calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
5508
|
+
* @param {number | null} [arg0]
|
|
4714
5509
|
*/
|
|
4715
|
-
set
|
|
4716
|
-
wasm.
|
|
5510
|
+
set waveStrength(arg0) {
|
|
5511
|
+
wasm.__wbg_set_polygonmaterial_waveStrength(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
4717
5512
|
}
|
|
4718
5513
|
/**
|
|
4719
5514
|
* @param {boolean | null} [arg0]
|
|
@@ -4794,15 +5589,15 @@ export class PolylineGeometry {
|
|
|
4794
5589
|
/**
|
|
4795
5590
|
* @returns {Float32Array | undefined}
|
|
4796
5591
|
*/
|
|
4797
|
-
|
|
4798
|
-
const ret = wasm.
|
|
5592
|
+
end_normal_and_segment_length() {
|
|
5593
|
+
const ret = wasm.polylinegeometry_end_normal_and_segment_length(this.__wbg_ptr);
|
|
4799
5594
|
return ret;
|
|
4800
5595
|
}
|
|
4801
5596
|
/**
|
|
4802
5597
|
* @returns {number | undefined}
|
|
4803
5598
|
*/
|
|
4804
|
-
|
|
4805
|
-
const ret = wasm.
|
|
5599
|
+
end_normal_and_segment_length_size() {
|
|
5600
|
+
const ret = wasm.polylinegeometry_end_normal_and_segment_length_size(this.__wbg_ptr);
|
|
4806
5601
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
4807
5602
|
}
|
|
4808
5603
|
/**
|
|
@@ -4826,6 +5621,20 @@ export class PolylineGeometry {
|
|
|
4826
5621
|
const ret = wasm.polylinegeometry_indices(this.__wbg_ptr);
|
|
4827
5622
|
return ret;
|
|
4828
5623
|
}
|
|
5624
|
+
/**
|
|
5625
|
+
* @returns {Float32Array | undefined}
|
|
5626
|
+
*/
|
|
5627
|
+
line_distance_and_ends() {
|
|
5628
|
+
const ret = wasm.polylinegeometry_line_distance_and_ends(this.__wbg_ptr);
|
|
5629
|
+
return ret;
|
|
5630
|
+
}
|
|
5631
|
+
/**
|
|
5632
|
+
* @returns {Float32Array | undefined}
|
|
5633
|
+
*/
|
|
5634
|
+
line_segments() {
|
|
5635
|
+
const ret = wasm.polylinegeometry_line_segments(this.__wbg_ptr);
|
|
5636
|
+
return ret;
|
|
5637
|
+
}
|
|
4829
5638
|
/**
|
|
4830
5639
|
* @returns {Float32Array}
|
|
4831
5640
|
*/
|
|
@@ -4871,15 +5680,15 @@ export class PolylineGeometry {
|
|
|
4871
5680
|
/**
|
|
4872
5681
|
* @returns {Float32Array}
|
|
4873
5682
|
*/
|
|
4874
|
-
|
|
4875
|
-
const ret = wasm.
|
|
5683
|
+
right_normal_and_line_length() {
|
|
5684
|
+
const ret = wasm.polylinegeometry_right_normal_and_line_length(this.__wbg_ptr);
|
|
4876
5685
|
return ret;
|
|
4877
5686
|
}
|
|
4878
5687
|
/**
|
|
4879
5688
|
* @returns {number}
|
|
4880
5689
|
*/
|
|
4881
|
-
|
|
4882
|
-
const ret = wasm.
|
|
5690
|
+
right_normal_and_line_length_size() {
|
|
5691
|
+
const ret = wasm.polylinegeometry_right_normal_and_line_length_size(this.__wbg_ptr);
|
|
4883
5692
|
return ret;
|
|
4884
5693
|
}
|
|
4885
5694
|
/**
|
|
@@ -4920,15 +5729,15 @@ export class PolylineGeometry {
|
|
|
4920
5729
|
/**
|
|
4921
5730
|
* @returns {Float32Array | undefined}
|
|
4922
5731
|
*/
|
|
4923
|
-
|
|
4924
|
-
const ret = wasm.
|
|
5732
|
+
start_normal_and_length_high() {
|
|
5733
|
+
const ret = wasm.polylinegeometry_start_normal_and_length_high(this.__wbg_ptr);
|
|
4925
5734
|
return ret;
|
|
4926
5735
|
}
|
|
4927
5736
|
/**
|
|
4928
5737
|
* @returns {number | undefined}
|
|
4929
5738
|
*/
|
|
4930
|
-
|
|
4931
|
-
const ret = wasm.
|
|
5739
|
+
start_normal_and_length_high_size() {
|
|
5740
|
+
const ret = wasm.polylinegeometry_start_normal_and_length_high_size(this.__wbg_ptr);
|
|
4932
5741
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
4933
5742
|
}
|
|
4934
5743
|
/**
|
|
@@ -5011,15 +5820,15 @@ export class PolylineGeometryAttributes {
|
|
|
5011
5820
|
/**
|
|
5012
5821
|
* @returns {Float32Array | undefined}
|
|
5013
5822
|
*/
|
|
5014
|
-
|
|
5015
|
-
const ret = wasm.
|
|
5823
|
+
transfer_end_normal_and_segment_length() {
|
|
5824
|
+
const ret = wasm.polylinegeometryattributes_transfer_end_normal_and_segment_length(this.__wbg_ptr);
|
|
5016
5825
|
return ret;
|
|
5017
5826
|
}
|
|
5018
5827
|
/**
|
|
5019
5828
|
* @returns {number | undefined}
|
|
5020
5829
|
*/
|
|
5021
|
-
|
|
5022
|
-
const ret = wasm.
|
|
5830
|
+
transfer_end_normal_and_segment_length_size() {
|
|
5831
|
+
const ret = wasm.polylinegeometryattributes_transfer_end_normal_and_segment_length_size(this.__wbg_ptr);
|
|
5023
5832
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
5024
5833
|
}
|
|
5025
5834
|
/**
|
|
@@ -5036,6 +5845,20 @@ export class PolylineGeometryAttributes {
|
|
|
5036
5845
|
const ret = wasm.polylinegeometryattributes_transfer_forward_offset_size(this.__wbg_ptr);
|
|
5037
5846
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
5038
5847
|
}
|
|
5848
|
+
/**
|
|
5849
|
+
* @returns {Float32Array | undefined}
|
|
5850
|
+
*/
|
|
5851
|
+
transfer_line_distance_and_ends() {
|
|
5852
|
+
const ret = wasm.polylinegeometryattributes_transfer_line_distance_and_ends(this.__wbg_ptr);
|
|
5853
|
+
return ret;
|
|
5854
|
+
}
|
|
5855
|
+
/**
|
|
5856
|
+
* @returns {Float32Array | undefined}
|
|
5857
|
+
*/
|
|
5858
|
+
transfer_line_segments() {
|
|
5859
|
+
const ret = wasm.polylinegeometryattributes_transfer_line_segments(this.__wbg_ptr);
|
|
5860
|
+
return ret;
|
|
5861
|
+
}
|
|
5039
5862
|
/**
|
|
5040
5863
|
* @returns {Float32Array}
|
|
5041
5864
|
*/
|
|
@@ -5081,15 +5904,15 @@ export class PolylineGeometryAttributes {
|
|
|
5081
5904
|
/**
|
|
5082
5905
|
* @returns {Float32Array}
|
|
5083
5906
|
*/
|
|
5084
|
-
|
|
5085
|
-
const ret = wasm.
|
|
5907
|
+
transfer_right_normal_and_line_length() {
|
|
5908
|
+
const ret = wasm.polylinegeometryattributes_transfer_right_normal_and_line_length(this.__wbg_ptr);
|
|
5086
5909
|
return ret;
|
|
5087
5910
|
}
|
|
5088
5911
|
/**
|
|
5089
5912
|
* @returns {number}
|
|
5090
5913
|
*/
|
|
5091
|
-
|
|
5092
|
-
const ret = wasm.
|
|
5914
|
+
transfer_right_normal_and_line_length_size() {
|
|
5915
|
+
const ret = wasm.polylinegeometryattributes_transfer_right_normal_and_line_length_size(this.__wbg_ptr);
|
|
5093
5916
|
return ret;
|
|
5094
5917
|
}
|
|
5095
5918
|
/**
|
|
@@ -5130,15 +5953,15 @@ export class PolylineGeometryAttributes {
|
|
|
5130
5953
|
/**
|
|
5131
5954
|
* @returns {Float32Array | undefined}
|
|
5132
5955
|
*/
|
|
5133
|
-
|
|
5134
|
-
const ret = wasm.
|
|
5956
|
+
transfer_start_normal_and_length_high() {
|
|
5957
|
+
const ret = wasm.polylinegeometryattributes_transfer_start_normal_and_length_high(this.__wbg_ptr);
|
|
5135
5958
|
return ret;
|
|
5136
5959
|
}
|
|
5137
5960
|
/**
|
|
5138
5961
|
* @returns {number | undefined}
|
|
5139
5962
|
*/
|
|
5140
|
-
|
|
5141
|
-
const ret = wasm.
|
|
5963
|
+
transfer_start_normal_and_length_high_size() {
|
|
5964
|
+
const ret = wasm.polylinegeometryattributes_transfer_start_normal_and_length_high_size(this.__wbg_ptr);
|
|
5142
5965
|
return ret === 0xFFFFFF ? undefined : ret;
|
|
5143
5966
|
}
|
|
5144
5967
|
/**
|
|
@@ -5206,6 +6029,23 @@ export class PolylineMaterial {
|
|
|
5206
6029
|
const ret = wasm.__wbg_get_polylinematerial___internal__(this.__wbg_ptr);
|
|
5207
6030
|
return ret === 0 ? undefined : PolylineInternalMaterial.__wrap(ret);
|
|
5208
6031
|
}
|
|
6032
|
+
/**
|
|
6033
|
+
* Shape of the ends of the line and of its dashes: `"butt"` (the
|
|
6034
|
+
* default), `"round"` or `"square"`. `"round"` adds a half circle one
|
|
6035
|
+
* half line width in radius beyond both ends of the line and of every
|
|
6036
|
+
* dash, so a zero-length dash becomes a dot. `"square"` extends the ends
|
|
6037
|
+
* of the line by half a line width and leaves the dashes' ends square.
|
|
6038
|
+
* @returns {string | undefined}
|
|
6039
|
+
*/
|
|
6040
|
+
get cap() {
|
|
6041
|
+
const ret = wasm.__wbg_get_polylinematerial_cap(this.__wbg_ptr);
|
|
6042
|
+
let v1;
|
|
6043
|
+
if (ret[0] !== 0) {
|
|
6044
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
6045
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
6046
|
+
}
|
|
6047
|
+
return v1;
|
|
6048
|
+
}
|
|
5209
6049
|
/**
|
|
5210
6050
|
* @returns {boolean | undefined}
|
|
5211
6051
|
*/
|
|
@@ -5227,6 +6067,22 @@ export class PolylineMaterial {
|
|
|
5227
6067
|
const ret = wasm.__wbg_get_polylinematerial_color(this.__wbg_ptr);
|
|
5228
6068
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
5229
6069
|
}
|
|
6070
|
+
/**
|
|
6071
|
+
* Alternating dash and gap lengths, in multiples of the line width,
|
|
6072
|
+
* repeated along the line. The pattern's period is the sum of the
|
|
6073
|
+
* entries, so an odd-length array ends in a dash that runs into the first
|
|
6074
|
+
* one. An empty array draws a solid line, which is the default.
|
|
6075
|
+
* @returns {Float32Array | undefined}
|
|
6076
|
+
*/
|
|
6077
|
+
get dashArray() {
|
|
6078
|
+
const ret = wasm.__wbg_get_polylinematerial_dashArray(this.__wbg_ptr);
|
|
6079
|
+
let v1;
|
|
6080
|
+
if (ret[0] !== 0) {
|
|
6081
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
6082
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
6083
|
+
}
|
|
6084
|
+
return v1;
|
|
6085
|
+
}
|
|
5230
6086
|
/**
|
|
5231
6087
|
* Enable writing to depth buffer
|
|
5232
6088
|
* @returns {boolean | undefined}
|
|
@@ -5390,6 +6246,19 @@ export class PolylineMaterial {
|
|
|
5390
6246
|
}
|
|
5391
6247
|
wasm.__wbg_set_polylinematerial___internal__(this.__wbg_ptr, ptr0);
|
|
5392
6248
|
}
|
|
6249
|
+
/**
|
|
6250
|
+
* Shape of the ends of the line and of its dashes: `"butt"` (the
|
|
6251
|
+
* default), `"round"` or `"square"`. `"round"` adds a half circle one
|
|
6252
|
+
* half line width in radius beyond both ends of the line and of every
|
|
6253
|
+
* dash, so a zero-length dash becomes a dot. `"square"` extends the ends
|
|
6254
|
+
* of the line by half a line width and leaves the dashes' ends square.
|
|
6255
|
+
* @param {string | null} [arg0]
|
|
6256
|
+
*/
|
|
6257
|
+
set cap(arg0) {
|
|
6258
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
6259
|
+
var len0 = WASM_VECTOR_LEN;
|
|
6260
|
+
wasm.__wbg_set_polylinematerial_cap(this.__wbg_ptr, ptr0, len0);
|
|
6261
|
+
}
|
|
5393
6262
|
/**
|
|
5394
6263
|
* @param {boolean | null} [arg0]
|
|
5395
6264
|
*/
|
|
@@ -5408,6 +6277,18 @@ export class PolylineMaterial {
|
|
|
5408
6277
|
set color(arg0) {
|
|
5409
6278
|
wasm.__wbg_set_polylinematerial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
5410
6279
|
}
|
|
6280
|
+
/**
|
|
6281
|
+
* Alternating dash and gap lengths, in multiples of the line width,
|
|
6282
|
+
* repeated along the line. The pattern's period is the sum of the
|
|
6283
|
+
* entries, so an odd-length array ends in a dash that runs into the first
|
|
6284
|
+
* one. An empty array draws a solid line, which is the default.
|
|
6285
|
+
* @param {Float32Array | null} [arg0]
|
|
6286
|
+
*/
|
|
6287
|
+
set dashArray(arg0) {
|
|
6288
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6289
|
+
var len0 = WASM_VECTOR_LEN;
|
|
6290
|
+
wasm.__wbg_set_polylinematerial_dashArray(this.__wbg_ptr, ptr0, len0);
|
|
6291
|
+
}
|
|
5411
6292
|
/**
|
|
5412
6293
|
* Enable writing to depth buffer
|
|
5413
6294
|
* @param {boolean | null} [arg0]
|
|
@@ -5609,6 +6490,17 @@ export class RasterTileInternalMaterial {
|
|
|
5609
6490
|
const ret = wasm.__wbg_get_rastertileinternalmaterial_castShadow(this.__wbg_ptr);
|
|
5610
6491
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5611
6492
|
}
|
|
6493
|
+
/**
|
|
6494
|
+
* Per-slot layer IDs used to look up each layer's colorMap atlas row; an
|
|
6495
|
+
* empty string for slots without an elevation heatmap.
|
|
6496
|
+
* @returns {string[]}
|
|
6497
|
+
*/
|
|
6498
|
+
get colorMapLayerIds() {
|
|
6499
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_colorMapLayerIds(this.__wbg_ptr);
|
|
6500
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
6501
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
6502
|
+
return v1;
|
|
6503
|
+
}
|
|
5612
6504
|
/**
|
|
5613
6505
|
* @returns {Uint32Array}
|
|
5614
6506
|
*/
|
|
@@ -5619,73 +6511,115 @@ export class RasterTileInternalMaterial {
|
|
|
5619
6511
|
return v1;
|
|
5620
6512
|
}
|
|
5621
6513
|
/**
|
|
5622
|
-
* @returns {
|
|
6514
|
+
* @returns {Float64Array}
|
|
5623
6515
|
*/
|
|
5624
|
-
get
|
|
5625
|
-
const ret = wasm.
|
|
5626
|
-
|
|
6516
|
+
get elevationBScalers() {
|
|
6517
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationBScalers(this.__wbg_ptr);
|
|
6518
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6519
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6520
|
+
return v1;
|
|
5627
6521
|
}
|
|
5628
6522
|
/**
|
|
5629
|
-
* @returns {
|
|
6523
|
+
* @returns {Float64Array}
|
|
5630
6524
|
*/
|
|
5631
|
-
get
|
|
5632
|
-
const ret = wasm.
|
|
5633
|
-
|
|
6525
|
+
get elevationBoundaries() {
|
|
6526
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationBoundaries(this.__wbg_ptr);
|
|
6527
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6528
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6529
|
+
return v1;
|
|
5634
6530
|
}
|
|
5635
6531
|
/**
|
|
5636
|
-
* @returns {
|
|
6532
|
+
* @returns {Float64Array}
|
|
5637
6533
|
*/
|
|
5638
|
-
get
|
|
5639
|
-
const ret = wasm.
|
|
5640
|
-
|
|
6534
|
+
get elevationEpsilons() {
|
|
6535
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationEpsilons(this.__wbg_ptr);
|
|
6536
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6537
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6538
|
+
return v1;
|
|
5641
6539
|
}
|
|
5642
6540
|
/**
|
|
5643
|
-
* @returns {
|
|
6541
|
+
* @returns {Float64Array}
|
|
5644
6542
|
*/
|
|
5645
|
-
get
|
|
5646
|
-
const ret = wasm.
|
|
5647
|
-
|
|
6543
|
+
get elevationGScalers() {
|
|
6544
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationGScalers(this.__wbg_ptr);
|
|
6545
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6546
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6547
|
+
return v1;
|
|
5648
6548
|
}
|
|
5649
6549
|
/**
|
|
5650
|
-
*
|
|
6550
|
+
* Per-layer filter modes: "linear" or "nearest"
|
|
6551
|
+
* @returns {string[]}
|
|
5651
6552
|
*/
|
|
5652
|
-
get
|
|
5653
|
-
const ret = wasm.
|
|
5654
|
-
|
|
6553
|
+
get elevationHeatmapFilters() {
|
|
6554
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationHeatmapFilters(this.__wbg_ptr);
|
|
6555
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
6556
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
6557
|
+
return v1;
|
|
5655
6558
|
}
|
|
5656
6559
|
/**
|
|
5657
|
-
*
|
|
6560
|
+
* Per-layer maximum heights for elevation normalization
|
|
6561
|
+
* @returns {Float64Array}
|
|
5658
6562
|
*/
|
|
5659
|
-
get
|
|
5660
|
-
const ret = wasm.
|
|
5661
|
-
|
|
6563
|
+
get elevationMaxHeights() {
|
|
6564
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationMaxHeights(this.__wbg_ptr);
|
|
6565
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6566
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6567
|
+
return v1;
|
|
5662
6568
|
}
|
|
5663
6569
|
/**
|
|
5664
|
-
* @returns {
|
|
6570
|
+
* @returns {Float64Array}
|
|
5665
6571
|
*/
|
|
5666
|
-
get
|
|
5667
|
-
const ret = wasm.
|
|
5668
|
-
|
|
6572
|
+
get elevationMaxOffsets() {
|
|
6573
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationMaxOffsets(this.__wbg_ptr);
|
|
6574
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6575
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6576
|
+
return v1;
|
|
5669
6577
|
}
|
|
5670
6578
|
/**
|
|
5671
|
-
*
|
|
6579
|
+
* Per-layer minimum heights for elevation normalization
|
|
6580
|
+
* @returns {Float64Array}
|
|
5672
6581
|
*/
|
|
5673
|
-
get
|
|
5674
|
-
const ret = wasm.
|
|
5675
|
-
|
|
6582
|
+
get elevationMinHeights() {
|
|
6583
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationMinHeights(this.__wbg_ptr);
|
|
6584
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6585
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6586
|
+
return v1;
|
|
5676
6587
|
}
|
|
5677
6588
|
/**
|
|
5678
|
-
* @returns {
|
|
6589
|
+
* @returns {Float64Array}
|
|
5679
6590
|
*/
|
|
5680
|
-
get
|
|
5681
|
-
const ret = wasm.
|
|
5682
|
-
|
|
6591
|
+
get elevationMinOffsets() {
|
|
6592
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationMinOffsets(this.__wbg_ptr);
|
|
6593
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6594
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6595
|
+
return v1;
|
|
5683
6596
|
}
|
|
5684
6597
|
/**
|
|
6598
|
+
* @returns {Float64Array}
|
|
6599
|
+
*/
|
|
6600
|
+
get elevationOffsets() {
|
|
6601
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationOffsets(this.__wbg_ptr);
|
|
6602
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6603
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6604
|
+
return v1;
|
|
6605
|
+
}
|
|
6606
|
+
/**
|
|
6607
|
+
* Per-layer DEM decoder parameters
|
|
6608
|
+
* @returns {Float64Array}
|
|
6609
|
+
*/
|
|
6610
|
+
get elevationRScalers() {
|
|
6611
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_elevationRScalers(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;
|
|
6615
|
+
}
|
|
6616
|
+
/**
|
|
6617
|
+
* Speed in m/s of the current carrying the waves on the watermask's water
|
|
6618
|
+
* along `waveDirection`.
|
|
5685
6619
|
* @returns {number}
|
|
5686
6620
|
*/
|
|
5687
|
-
get
|
|
5688
|
-
const ret = wasm.
|
|
6621
|
+
get flowSpeed() {
|
|
6622
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_flowSpeed(this.__wbg_ptr);
|
|
5689
6623
|
return ret;
|
|
5690
6624
|
}
|
|
5691
6625
|
/**
|
|
@@ -5789,18 +6723,24 @@ export class RasterTileInternalMaterial {
|
|
|
5789
6723
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
5790
6724
|
}
|
|
5791
6725
|
/**
|
|
5792
|
-
*
|
|
6726
|
+
* Per-layer logarithmic boundaries
|
|
6727
|
+
* @returns {Float64Array}
|
|
5793
6728
|
*/
|
|
5794
|
-
get
|
|
5795
|
-
const ret = wasm.
|
|
5796
|
-
|
|
6729
|
+
get logBoundaries() {
|
|
6730
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_logBoundaries(this.__wbg_ptr);
|
|
6731
|
+
var v1 = getArrayF64FromWasm0(ret[0], ret[1]).slice();
|
|
6732
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 8, 8);
|
|
6733
|
+
return v1;
|
|
5797
6734
|
}
|
|
5798
6735
|
/**
|
|
5799
|
-
*
|
|
6736
|
+
* Per-layer logarithmic scaling flags
|
|
6737
|
+
* @returns {Uint8Array}
|
|
5800
6738
|
*/
|
|
5801
|
-
get
|
|
5802
|
-
const ret = wasm.
|
|
5803
|
-
|
|
6739
|
+
get logarithmics() {
|
|
6740
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_logarithmics(this.__wbg_ptr);
|
|
6741
|
+
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
6742
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
6743
|
+
return v1;
|
|
5804
6744
|
}
|
|
5805
6745
|
/**
|
|
5806
6746
|
* @returns {Float32Array}
|
|
@@ -5843,6 +6783,41 @@ export class RasterTileInternalMaterial {
|
|
|
5843
6783
|
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
5844
6784
|
return v1;
|
|
5845
6785
|
}
|
|
6786
|
+
/**
|
|
6787
|
+
* Body color of the watermask's water from the terrain layer; `None`
|
|
6788
|
+
* keeps the imagery or globe color.
|
|
6789
|
+
* @returns {number | undefined}
|
|
6790
|
+
*/
|
|
6791
|
+
get waterMaskColor() {
|
|
6792
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_waterMaskColor(this.__wbg_ptr);
|
|
6793
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6794
|
+
}
|
|
6795
|
+
/**
|
|
6796
|
+
* Where the waves on the watermask's water travel, in degrees clockwise
|
|
6797
|
+
* from north.
|
|
6798
|
+
* @returns {number}
|
|
6799
|
+
*/
|
|
6800
|
+
get waveDirection() {
|
|
6801
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_waveDirection(this.__wbg_ptr);
|
|
6802
|
+
return ret;
|
|
6803
|
+
}
|
|
6804
|
+
/**
|
|
6805
|
+
* Scales the wave slopes on the watermask's water; 0 is a flat mirror.
|
|
6806
|
+
* @returns {number}
|
|
6807
|
+
*/
|
|
6808
|
+
get waveExaggeration() {
|
|
6809
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_waveExaggeration(this.__wbg_ptr);
|
|
6810
|
+
return ret;
|
|
6811
|
+
}
|
|
6812
|
+
/**
|
|
6813
|
+
* Sets the size, slope and speed of the waves on the watermask's water, in
|
|
6814
|
+
* m/s.
|
|
6815
|
+
* @returns {number}
|
|
6816
|
+
*/
|
|
6817
|
+
get waveStrength() {
|
|
6818
|
+
const ret = wasm.__wbg_get_rastertileinternalmaterial_waveStrength(this.__wbg_ptr);
|
|
6819
|
+
return ret;
|
|
6820
|
+
}
|
|
5846
6821
|
/**
|
|
5847
6822
|
* @returns {any[]}
|
|
5848
6823
|
*/
|
|
@@ -5870,6 +6845,16 @@ export class RasterTileInternalMaterial {
|
|
|
5870
6845
|
set castShadow(arg0) {
|
|
5871
6846
|
wasm.__wbg_set_rastertileinternalmaterial_castShadow(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
5872
6847
|
}
|
|
6848
|
+
/**
|
|
6849
|
+
* Per-slot layer IDs used to look up each layer's colorMap atlas row; an
|
|
6850
|
+
* empty string for slots without an elevation heatmap.
|
|
6851
|
+
* @param {string[]} arg0
|
|
6852
|
+
*/
|
|
6853
|
+
set colorMapLayerIds(arg0) {
|
|
6854
|
+
const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6855
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6856
|
+
wasm.__wbg_set_rastertileinternalmaterial_colorMapLayerIds(this.__wbg_ptr, ptr0, len0);
|
|
6857
|
+
}
|
|
5873
6858
|
/**
|
|
5874
6859
|
* @param {Uint32Array} arg0
|
|
5875
6860
|
*/
|
|
@@ -5879,64 +6864,104 @@ export class RasterTileInternalMaterial {
|
|
|
5879
6864
|
wasm.__wbg_set_rastertileinternalmaterial_colors(this.__wbg_ptr, ptr0, len0);
|
|
5880
6865
|
}
|
|
5881
6866
|
/**
|
|
5882
|
-
* @param {
|
|
6867
|
+
* @param {Float64Array} arg0
|
|
5883
6868
|
*/
|
|
5884
|
-
set
|
|
5885
|
-
|
|
6869
|
+
set elevationBScalers(arg0) {
|
|
6870
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6871
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6872
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationBScalers(this.__wbg_ptr, ptr0, len0);
|
|
5886
6873
|
}
|
|
5887
6874
|
/**
|
|
5888
|
-
* @param {
|
|
6875
|
+
* @param {Float64Array} arg0
|
|
5889
6876
|
*/
|
|
5890
|
-
set
|
|
5891
|
-
|
|
6877
|
+
set elevationBoundaries(arg0) {
|
|
6878
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6879
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6880
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationBoundaries(this.__wbg_ptr, ptr0, len0);
|
|
5892
6881
|
}
|
|
5893
6882
|
/**
|
|
5894
|
-
* @param {
|
|
6883
|
+
* @param {Float64Array} arg0
|
|
5895
6884
|
*/
|
|
5896
|
-
set
|
|
5897
|
-
|
|
6885
|
+
set elevationEpsilons(arg0) {
|
|
6886
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6887
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6888
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationEpsilons(this.__wbg_ptr, ptr0, len0);
|
|
5898
6889
|
}
|
|
5899
6890
|
/**
|
|
5900
|
-
* @param {
|
|
6891
|
+
* @param {Float64Array} arg0
|
|
5901
6892
|
*/
|
|
5902
|
-
set
|
|
5903
|
-
|
|
6893
|
+
set elevationGScalers(arg0) {
|
|
6894
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6895
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6896
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationGScalers(this.__wbg_ptr, ptr0, len0);
|
|
5904
6897
|
}
|
|
5905
6898
|
/**
|
|
5906
|
-
*
|
|
6899
|
+
* Per-layer filter modes: "linear" or "nearest"
|
|
6900
|
+
* @param {string[]} arg0
|
|
5907
6901
|
*/
|
|
5908
|
-
set
|
|
5909
|
-
|
|
6902
|
+
set elevationHeatmapFilters(arg0) {
|
|
6903
|
+
const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6904
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6905
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationHeatmapFilters(this.__wbg_ptr, ptr0, len0);
|
|
5910
6906
|
}
|
|
5911
6907
|
/**
|
|
5912
|
-
*
|
|
6908
|
+
* Per-layer maximum heights for elevation normalization
|
|
6909
|
+
* @param {Float64Array} arg0
|
|
5913
6910
|
*/
|
|
5914
|
-
set
|
|
5915
|
-
|
|
6911
|
+
set elevationMaxHeights(arg0) {
|
|
6912
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6913
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6914
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationMaxHeights(this.__wbg_ptr, ptr0, len0);
|
|
5916
6915
|
}
|
|
5917
6916
|
/**
|
|
5918
|
-
* @param {
|
|
6917
|
+
* @param {Float64Array} arg0
|
|
5919
6918
|
*/
|
|
5920
|
-
set
|
|
5921
|
-
|
|
6919
|
+
set elevationMaxOffsets(arg0) {
|
|
6920
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6921
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6922
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationMaxOffsets(this.__wbg_ptr, ptr0, len0);
|
|
5922
6923
|
}
|
|
5923
6924
|
/**
|
|
5924
|
-
*
|
|
6925
|
+
* Per-layer minimum heights for elevation normalization
|
|
6926
|
+
* @param {Float64Array} arg0
|
|
5925
6927
|
*/
|
|
5926
|
-
set
|
|
5927
|
-
|
|
6928
|
+
set elevationMinHeights(arg0) {
|
|
6929
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6930
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6931
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationMinHeights(this.__wbg_ptr, ptr0, len0);
|
|
5928
6932
|
}
|
|
5929
6933
|
/**
|
|
5930
|
-
* @param {
|
|
6934
|
+
* @param {Float64Array} arg0
|
|
5931
6935
|
*/
|
|
5932
|
-
set
|
|
5933
|
-
|
|
6936
|
+
set elevationMinOffsets(arg0) {
|
|
6937
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6938
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6939
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationMinOffsets(this.__wbg_ptr, ptr0, len0);
|
|
5934
6940
|
}
|
|
5935
6941
|
/**
|
|
6942
|
+
* @param {Float64Array} arg0
|
|
6943
|
+
*/
|
|
6944
|
+
set elevationOffsets(arg0) {
|
|
6945
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6946
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6947
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationOffsets(this.__wbg_ptr, ptr0, len0);
|
|
6948
|
+
}
|
|
6949
|
+
/**
|
|
6950
|
+
* Per-layer DEM decoder parameters
|
|
6951
|
+
* @param {Float64Array} arg0
|
|
6952
|
+
*/
|
|
6953
|
+
set elevationRScalers(arg0) {
|
|
6954
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
6955
|
+
const len0 = WASM_VECTOR_LEN;
|
|
6956
|
+
wasm.__wbg_set_rastertileinternalmaterial_elevationRScalers(this.__wbg_ptr, ptr0, len0);
|
|
6957
|
+
}
|
|
6958
|
+
/**
|
|
6959
|
+
* Speed in m/s of the current carrying the waves on the watermask's water
|
|
6960
|
+
* along `waveDirection`.
|
|
5936
6961
|
* @param {number} arg0
|
|
5937
6962
|
*/
|
|
5938
|
-
set
|
|
5939
|
-
wasm.
|
|
6963
|
+
set flowSpeed(arg0) {
|
|
6964
|
+
wasm.__wbg_set_rastertileinternalmaterial_flowSpeed(this.__wbg_ptr, arg0);
|
|
5940
6965
|
}
|
|
5941
6966
|
/**
|
|
5942
6967
|
* @param {number} arg0
|
|
@@ -6026,16 +7051,22 @@ export class RasterTileInternalMaterial {
|
|
|
6026
7051
|
wasm.__wbg_set_rastertileinternalmaterial_lit(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6027
7052
|
}
|
|
6028
7053
|
/**
|
|
6029
|
-
*
|
|
7054
|
+
* Per-layer logarithmic boundaries
|
|
7055
|
+
* @param {Float64Array} arg0
|
|
6030
7056
|
*/
|
|
6031
|
-
set
|
|
6032
|
-
|
|
7057
|
+
set logBoundaries(arg0) {
|
|
7058
|
+
const ptr0 = passArrayF64ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7059
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7060
|
+
wasm.__wbg_set_rastertileinternalmaterial_logBoundaries(this.__wbg_ptr, ptr0, len0);
|
|
6033
7061
|
}
|
|
6034
7062
|
/**
|
|
6035
|
-
*
|
|
7063
|
+
* Per-layer logarithmic scaling flags
|
|
7064
|
+
* @param {Uint8Array} arg0
|
|
6036
7065
|
*/
|
|
6037
|
-
set
|
|
6038
|
-
|
|
7066
|
+
set logarithmics(arg0) {
|
|
7067
|
+
const ptr0 = passArray8ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
7068
|
+
const len0 = WASM_VECTOR_LEN;
|
|
7069
|
+
wasm.__wbg_set_rastertileinternalmaterial_logarithmics(this.__wbg_ptr, ptr0, len0);
|
|
6039
7070
|
}
|
|
6040
7071
|
/**
|
|
6041
7072
|
* @param {Float32Array} arg0
|
|
@@ -6073,6 +7104,37 @@ export class RasterTileInternalMaterial {
|
|
|
6073
7104
|
const len0 = WASM_VECTOR_LEN;
|
|
6074
7105
|
wasm.__wbg_set_rastertileinternalmaterial_terrainLatRange(this.__wbg_ptr, ptr0, len0);
|
|
6075
7106
|
}
|
|
7107
|
+
/**
|
|
7108
|
+
* Body color of the watermask's water from the terrain layer; `None`
|
|
7109
|
+
* keeps the imagery or globe color.
|
|
7110
|
+
* @param {number | null} [arg0]
|
|
7111
|
+
*/
|
|
7112
|
+
set waterMaskColor(arg0) {
|
|
7113
|
+
wasm.__wbg_set_rastertileinternalmaterial_waterMaskColor(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
7114
|
+
}
|
|
7115
|
+
/**
|
|
7116
|
+
* Where the waves on the watermask's water travel, in degrees clockwise
|
|
7117
|
+
* from north.
|
|
7118
|
+
* @param {number} arg0
|
|
7119
|
+
*/
|
|
7120
|
+
set waveDirection(arg0) {
|
|
7121
|
+
wasm.__wbg_set_rastertileinternalmaterial_waveDirection(this.__wbg_ptr, arg0);
|
|
7122
|
+
}
|
|
7123
|
+
/**
|
|
7124
|
+
* Scales the wave slopes on the watermask's water; 0 is a flat mirror.
|
|
7125
|
+
* @param {number} arg0
|
|
7126
|
+
*/
|
|
7127
|
+
set waveExaggeration(arg0) {
|
|
7128
|
+
wasm.__wbg_set_rastertileinternalmaterial_waveExaggeration(this.__wbg_ptr, arg0);
|
|
7129
|
+
}
|
|
7130
|
+
/**
|
|
7131
|
+
* Sets the size, slope and speed of the waves on the watermask's water, in
|
|
7132
|
+
* m/s.
|
|
7133
|
+
* @param {number} arg0
|
|
7134
|
+
*/
|
|
7135
|
+
set waveStrength(arg0) {
|
|
7136
|
+
wasm.__wbg_set_rastertileinternalmaterial_waveStrength(this.__wbg_ptr, arg0);
|
|
7137
|
+
}
|
|
6076
7138
|
}
|
|
6077
7139
|
if (Symbol.dispose) RasterTileInternalMaterial.prototype[Symbol.dispose] = RasterTileInternalMaterial.prototype.free;
|
|
6078
7140
|
|
|
@@ -6244,6 +7306,13 @@ export class ReturnedConstructedTerrainMesh {
|
|
|
6244
7306
|
const ret = wasm.returnedconstructedterrainmesh_transferNormals(this.__wbg_ptr);
|
|
6245
7307
|
return ret;
|
|
6246
7308
|
}
|
|
7309
|
+
/**
|
|
7310
|
+
* @returns {Float32Array | undefined}
|
|
7311
|
+
*/
|
|
7312
|
+
transferSkirtHeights() {
|
|
7313
|
+
const ret = wasm.returnedconstructedterrainmesh_transferSkirtHeights(this.__wbg_ptr);
|
|
7314
|
+
return ret;
|
|
7315
|
+
}
|
|
6247
7316
|
/**
|
|
6248
7317
|
* @returns {Uint32Array | undefined}
|
|
6249
7318
|
*/
|
|
@@ -6343,6 +7412,36 @@ export class TerrainMaterial {
|
|
|
6343
7412
|
const ret = wasm.__wbg_get_terrainmaterial_castShadow(this.__wbg_ptr);
|
|
6344
7413
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6345
7414
|
}
|
|
7415
|
+
/**
|
|
7416
|
+
* Height in meters that stays in place while the terrain is exaggerated:
|
|
7417
|
+
* a terrain height `h` is rendered at
|
|
7418
|
+
* `(h - exaggerationRelativeHeight) * exaggeration + exaggerationRelativeHeight`.
|
|
7419
|
+
* Default: 0.
|
|
7420
|
+
* @returns {number | undefined}
|
|
7421
|
+
*/
|
|
7422
|
+
get exaggerationRelativeHeight() {
|
|
7423
|
+
const ret = wasm.__wbg_get_terrainmaterial_exaggerationRelativeHeight(this.__wbg_ptr);
|
|
7424
|
+
return ret[0] === 0 ? undefined : ret[1];
|
|
7425
|
+
}
|
|
7426
|
+
/**
|
|
7427
|
+
* Vertical exaggeration of the terrain. Terrain heights are scaled by this
|
|
7428
|
+
* factor around `exaggerationRelativeHeight`. A negative value is treated
|
|
7429
|
+
* as 0, which flattens the terrain. Default: 1.
|
|
7430
|
+
* @returns {number | undefined}
|
|
7431
|
+
*/
|
|
7432
|
+
get exaggeration() {
|
|
7433
|
+
const ret = wasm.__wbg_get_terrainmaterial_exaggeration(this.__wbg_ptr);
|
|
7434
|
+
return ret[0] === 0 ? undefined : ret[1];
|
|
7435
|
+
}
|
|
7436
|
+
/**
|
|
7437
|
+
* Speed in m/s of the current carrying the waves on the watermask's water
|
|
7438
|
+
* along `waveDirection`. Default: 0.
|
|
7439
|
+
* @returns {number | undefined}
|
|
7440
|
+
*/
|
|
7441
|
+
get flowSpeed() {
|
|
7442
|
+
const ret = wasm.__wbg_get_terrainmaterial_flowSpeed(this.__wbg_ptr);
|
|
7443
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7444
|
+
}
|
|
6346
7445
|
/**
|
|
6347
7446
|
* Applies the lighting equation to the color output. When `false` the
|
|
6348
7447
|
* material outputs plain albedo (for deferred lighting) while normals and
|
|
@@ -6392,12 +7491,66 @@ export class TerrainMaterial {
|
|
|
6392
7491
|
const ret = wasm.__wbg_get_terrainmaterial_skirt(this.__wbg_ptr);
|
|
6393
7492
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6394
7493
|
}
|
|
7494
|
+
/**
|
|
7495
|
+
* Where the waves on the watermask's water travel, in degrees clockwise
|
|
7496
|
+
* from north. Default: 0.
|
|
7497
|
+
* @returns {number | undefined}
|
|
7498
|
+
*/
|
|
7499
|
+
get waveDirection() {
|
|
7500
|
+
const ret = wasm.__wbg_get_terrainmaterial_waveDirection(this.__wbg_ptr);
|
|
7501
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7502
|
+
}
|
|
7503
|
+
/**
|
|
7504
|
+
* Scales the wave slopes on the watermask's water, keeping their size and
|
|
7505
|
+
* speed; 0 is a flat mirror. Default: 1.
|
|
7506
|
+
* @returns {number | undefined}
|
|
7507
|
+
*/
|
|
7508
|
+
get waveExaggeration() {
|
|
7509
|
+
const ret = wasm.__wbg_get_terrainmaterial_waveExaggeration(this.__wbg_ptr);
|
|
7510
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7511
|
+
}
|
|
7512
|
+
/**
|
|
7513
|
+
* Sets the size, steepness and speed of the waves on the watermask's water:
|
|
7514
|
+
* about 1 is a calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
7515
|
+
* @returns {number | undefined}
|
|
7516
|
+
*/
|
|
7517
|
+
get waveStrength() {
|
|
7518
|
+
const ret = wasm.__wbg_get_terrainmaterial_waveStrength(this.__wbg_ptr);
|
|
7519
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7520
|
+
}
|
|
6395
7521
|
/**
|
|
6396
7522
|
* @param {boolean | null} [arg0]
|
|
6397
7523
|
*/
|
|
6398
7524
|
set castShadow(arg0) {
|
|
6399
7525
|
wasm.__wbg_set_terrainmaterial_castShadow(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6400
7526
|
}
|
|
7527
|
+
/**
|
|
7528
|
+
* Height in meters that stays in place while the terrain is exaggerated:
|
|
7529
|
+
* a terrain height `h` is rendered at
|
|
7530
|
+
* `(h - exaggerationRelativeHeight) * exaggeration + exaggerationRelativeHeight`.
|
|
7531
|
+
* Default: 0.
|
|
7532
|
+
* @param {number | null} [arg0]
|
|
7533
|
+
*/
|
|
7534
|
+
set exaggerationRelativeHeight(arg0) {
|
|
7535
|
+
wasm.__wbg_set_terrainmaterial_exaggerationRelativeHeight(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? 0 : arg0);
|
|
7536
|
+
}
|
|
7537
|
+
/**
|
|
7538
|
+
* Vertical exaggeration of the terrain. Terrain heights are scaled by this
|
|
7539
|
+
* factor around `exaggerationRelativeHeight`. A negative value is treated
|
|
7540
|
+
* as 0, which flattens the terrain. Default: 1.
|
|
7541
|
+
* @param {number | null} [arg0]
|
|
7542
|
+
*/
|
|
7543
|
+
set exaggeration(arg0) {
|
|
7544
|
+
wasm.__wbg_set_terrainmaterial_exaggeration(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? 0 : arg0);
|
|
7545
|
+
}
|
|
7546
|
+
/**
|
|
7547
|
+
* Speed in m/s of the current carrying the waves on the watermask's water
|
|
7548
|
+
* along `waveDirection`. Default: 0.
|
|
7549
|
+
* @param {number | null} [arg0]
|
|
7550
|
+
*/
|
|
7551
|
+
set flowSpeed(arg0) {
|
|
7552
|
+
wasm.__wbg_set_terrainmaterial_flowSpeed(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7553
|
+
}
|
|
6401
7554
|
/**
|
|
6402
7555
|
* Applies the lighting equation to the color output. When `false` the
|
|
6403
7556
|
* material outputs plain albedo (for deferred lighting) while normals and
|
|
@@ -6441,6 +7594,47 @@ export class TerrainMaterial {
|
|
|
6441
7594
|
set skirt(arg0) {
|
|
6442
7595
|
wasm.__wbg_set_terrainmaterial_skirt(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6443
7596
|
}
|
|
7597
|
+
/**
|
|
7598
|
+
* Where the waves on the watermask's water travel, in degrees clockwise
|
|
7599
|
+
* from north. Default: 0.
|
|
7600
|
+
* @param {number | null} [arg0]
|
|
7601
|
+
*/
|
|
7602
|
+
set waveDirection(arg0) {
|
|
7603
|
+
wasm.__wbg_set_terrainmaterial_waveDirection(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7604
|
+
}
|
|
7605
|
+
/**
|
|
7606
|
+
* Scales the wave slopes on the watermask's water, keeping their size and
|
|
7607
|
+
* speed; 0 is a flat mirror. Default: 1.
|
|
7608
|
+
* @param {number | null} [arg0]
|
|
7609
|
+
*/
|
|
7610
|
+
set waveExaggeration(arg0) {
|
|
7611
|
+
wasm.__wbg_set_terrainmaterial_waveExaggeration(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7612
|
+
}
|
|
7613
|
+
/**
|
|
7614
|
+
* Sets the size, steepness and speed of the waves on the watermask's water:
|
|
7615
|
+
* about 1 is a calm ripple, 5 moderate and 20 a storm. Default: 5.
|
|
7616
|
+
* @param {number | null} [arg0]
|
|
7617
|
+
*/
|
|
7618
|
+
set waveStrength(arg0) {
|
|
7619
|
+
wasm.__wbg_set_terrainmaterial_waveStrength(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7620
|
+
}
|
|
7621
|
+
/**
|
|
7622
|
+
* @param {number | null} [color]
|
|
7623
|
+
*/
|
|
7624
|
+
set waterMaskColor(color) {
|
|
7625
|
+
wasm.terrainmaterial_set_waterMaskColor(this.__wbg_ptr, isLikeNone(color) ? Number.MAX_SAFE_INTEGER : (color) >>> 0);
|
|
7626
|
+
}
|
|
7627
|
+
/**
|
|
7628
|
+
* Body color of the water the source's watermask marks. The water shows
|
|
7629
|
+
* this color under its reflections instead of the imagery or globe color
|
|
7630
|
+
* beneath it. Requires `requestWaterMask` on a quantized-mesh source.
|
|
7631
|
+
* An update with `undefined` uses that imagery or globe color.
|
|
7632
|
+
* @returns {number | undefined}
|
|
7633
|
+
*/
|
|
7634
|
+
get waterMaskColor() {
|
|
7635
|
+
const ret = wasm.terrainmaterial_waterMaskColor(this.__wbg_ptr);
|
|
7636
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7637
|
+
}
|
|
6444
7638
|
}
|
|
6445
7639
|
if (Symbol.dispose) TerrainMaterial.prototype[Symbol.dispose] = TerrainMaterial.prototype.free;
|
|
6446
7640
|
|
|
@@ -6456,10 +7650,27 @@ export class TextMaterial {
|
|
|
6456
7650
|
wasm.__wbg_textmaterial_free(ptr, 0);
|
|
6457
7651
|
}
|
|
6458
7652
|
/**
|
|
6459
|
-
*
|
|
6460
|
-
*
|
|
6461
|
-
*
|
|
6462
|
-
*
|
|
7653
|
+
* Part of the text block placed at the anchor point: `"center"`
|
|
7654
|
+
* (default), `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`,
|
|
7655
|
+
* `"top-right"`, `"bottom-left"` or `"bottom-right"`, as MapLibre's
|
|
7656
|
+
* `text-anchor`. The block is as wide as its widest line and one line
|
|
7657
|
+
* height tall per line.
|
|
7658
|
+
* @returns {string | undefined}
|
|
7659
|
+
*/
|
|
7660
|
+
get anchor() {
|
|
7661
|
+
const ret = wasm.__wbg_get_textmaterial_anchor(this.__wbg_ptr);
|
|
7662
|
+
let v1;
|
|
7663
|
+
if (ret[0] !== 0) {
|
|
7664
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
7665
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
7666
|
+
}
|
|
7667
|
+
return v1;
|
|
7668
|
+
}
|
|
7669
|
+
/**
|
|
7670
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
7671
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
7672
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
7673
|
+
* camera.
|
|
6463
7674
|
* @returns {boolean | undefined}
|
|
6464
7675
|
*/
|
|
6465
7676
|
get backfaceCulling() {
|
|
@@ -6487,13 +7698,6 @@ export class TextMaterial {
|
|
|
6487
7698
|
const ret = wasm.__wbg_get_textmaterial_borderWidth(this.__wbg_ptr);
|
|
6488
7699
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6489
7700
|
}
|
|
6490
|
-
/**
|
|
6491
|
-
* @returns {Vec2 | undefined}
|
|
6492
|
-
*/
|
|
6493
|
-
get center() {
|
|
6494
|
-
const ret = wasm.__wbg_get_textmaterial_center(this.__wbg_ptr);
|
|
6495
|
-
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
6496
|
-
}
|
|
6497
7701
|
/**
|
|
6498
7702
|
* @returns {boolean | undefined}
|
|
6499
7703
|
*/
|
|
@@ -6508,6 +7712,21 @@ export class TextMaterial {
|
|
|
6508
7712
|
const ret = wasm.__wbg_get_textmaterial_color(this.__wbg_ptr);
|
|
6509
7713
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6510
7714
|
}
|
|
7715
|
+
/**
|
|
7716
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
7717
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
7718
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
7719
|
+
* @returns {Float32Array | undefined}
|
|
7720
|
+
*/
|
|
7721
|
+
get declutterPadding() {
|
|
7722
|
+
const ret = wasm.__wbg_get_textmaterial_declutterPadding(this.__wbg_ptr);
|
|
7723
|
+
let v1;
|
|
7724
|
+
if (ret[0] !== 0) {
|
|
7725
|
+
v1 = getArrayF32FromWasm0(ret[0], ret[1]).slice();
|
|
7726
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
7727
|
+
}
|
|
7728
|
+
return v1;
|
|
7729
|
+
}
|
|
6511
7730
|
/**
|
|
6512
7731
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
6513
7732
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -6517,6 +7736,17 @@ export class TextMaterial {
|
|
|
6517
7736
|
const ret = wasm.__wbg_get_textmaterial_declutterPriority(this.__wbg_ptr);
|
|
6518
7737
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6519
7738
|
}
|
|
7739
|
+
/**
|
|
7740
|
+
* Coarse placement order for decluttering, compared before
|
|
7741
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
7742
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
7743
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
7744
|
+
* @returns {number | undefined}
|
|
7745
|
+
*/
|
|
7746
|
+
get declutterRank() {
|
|
7747
|
+
const ret = wasm.__wbg_get_textmaterial_declutterRank(this.__wbg_ptr);
|
|
7748
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7749
|
+
}
|
|
6520
7750
|
/**
|
|
6521
7751
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
6522
7752
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -6590,8 +7820,9 @@ export class TextMaterial {
|
|
|
6590
7820
|
}
|
|
6591
7821
|
/**
|
|
6592
7822
|
* Source geometry types this appearance consumes: `"point"`, `"line"`,
|
|
6593
|
-
* `"polygon"`. Defaults to `["point"]`; adding `"line"
|
|
6594
|
-
*
|
|
7823
|
+
* `"polygon"`. Defaults to `["point"]`; adding `"line"` also emits a
|
|
7824
|
+
* label per line string, at its first vertex, and `"polygon"` one per
|
|
7825
|
+
* polygon.
|
|
6595
7826
|
* @returns {string[] | undefined}
|
|
6596
7827
|
*/
|
|
6597
7828
|
get geometryTypes() {
|
|
@@ -6611,15 +7842,34 @@ export class TextMaterial {
|
|
|
6611
7842
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6612
7843
|
}
|
|
6613
7844
|
/**
|
|
6614
|
-
* Enable high-quality glyph rendering. When `true`, text uses an MTSDF
|
|
6615
|
-
* atlas (sharper corners at large sizes, dramatically slower
|
|
6616
|
-
* rasterization). When `false` or omitted, the default single-channel SDF
|
|
6617
|
-
* atlas is used (fast). Mirrors `navara_material::TextMaterial::high_quality`
|
|
6618
|
-
* on the Rust side.
|
|
7845
|
+
* Enable high-quality glyph rendering. When `true`, text uses an MTSDF
|
|
7846
|
+
* atlas (sharper corners at large sizes, dramatically slower
|
|
7847
|
+
* rasterization). When `false` or omitted, the default single-channel SDF
|
|
7848
|
+
* atlas is used (fast). Mirrors `navara_material::TextMaterial::high_quality`
|
|
7849
|
+
* on the Rust side.
|
|
7850
|
+
* @returns {boolean | undefined}
|
|
7851
|
+
*/
|
|
7852
|
+
get highQuality() {
|
|
7853
|
+
const ret = wasm.__wbg_get_textmaterial_highQuality(this.__wbg_ptr);
|
|
7854
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
7855
|
+
}
|
|
7856
|
+
/**
|
|
7857
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
7858
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
7859
|
+
* Defaults to `false`.
|
|
7860
|
+
* @returns {boolean | undefined}
|
|
7861
|
+
*/
|
|
7862
|
+
get ignorePlacement() {
|
|
7863
|
+
const ret = wasm.__wbg_get_textmaterial_ignorePlacement(this.__wbg_ptr);
|
|
7864
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
7865
|
+
}
|
|
7866
|
+
/**
|
|
7867
|
+
* Flip a label that would otherwise read right-to-left, so names stay
|
|
7868
|
+
* legible whichever way the underlying line runs. Defaults to `true`.
|
|
6619
7869
|
* @returns {boolean | undefined}
|
|
6620
7870
|
*/
|
|
6621
|
-
get
|
|
6622
|
-
const ret = wasm.
|
|
7871
|
+
get keepUpright() {
|
|
7872
|
+
const ret = wasm.__wbg_get_textmaterial_keepUpright(this.__wbg_ptr);
|
|
6623
7873
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6624
7874
|
}
|
|
6625
7875
|
/**
|
|
@@ -6636,14 +7886,47 @@ export class TextMaterial {
|
|
|
6636
7886
|
return v1;
|
|
6637
7887
|
}
|
|
6638
7888
|
/**
|
|
6639
|
-
*
|
|
6640
|
-
*
|
|
7889
|
+
* Extra space between characters, in ems (multiples of `size`). Not
|
|
7890
|
+
* added after the last character; ignored for Arabic-script text.
|
|
7891
|
+
* Negative values tighten. Defaults to `0.0`.
|
|
7892
|
+
* @returns {number | undefined}
|
|
7893
|
+
*/
|
|
7894
|
+
get letterSpacing() {
|
|
7895
|
+
const ret = wasm.__wbg_get_textmaterial_letterSpacing(this.__wbg_ptr);
|
|
7896
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7897
|
+
}
|
|
7898
|
+
/**
|
|
7899
|
+
* Distance between the baselines of a multi-line label, in ems
|
|
7900
|
+
* (multiples of `size`). Defaults to the font's natural line height
|
|
7901
|
+
* (ascender − descender + line gap).
|
|
6641
7902
|
* @returns {number | undefined}
|
|
6642
7903
|
*/
|
|
6643
7904
|
get lineHeight() {
|
|
6644
7905
|
const ret = wasm.__wbg_get_textmaterial_lineHeight(this.__wbg_ptr);
|
|
6645
7906
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6646
7907
|
}
|
|
7908
|
+
/**
|
|
7909
|
+
* Offset perpendicular to the line, in the same units as the font size:
|
|
7910
|
+
* pixels when `sizeInMeters` is false, metres when it is true. Positive is
|
|
7911
|
+
* to the left of the direction of travel, which puts the name above the
|
|
7912
|
+
* line. Defaults to `0.0`.
|
|
7913
|
+
* @returns {number | undefined}
|
|
7914
|
+
*/
|
|
7915
|
+
get lineOffset() {
|
|
7916
|
+
const ret = wasm.__wbg_get_textmaterial_lineOffset(this.__wbg_ptr);
|
|
7917
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7918
|
+
}
|
|
7919
|
+
/**
|
|
7920
|
+
* Largest turn, in degrees, the line may make under a label within a
|
|
7921
|
+
* window of about one and a half ems before the label is dropped as
|
|
7922
|
+
* unreadable. The window slides along the label, so a long gentle curve
|
|
7923
|
+
* is accepted however far it turns in total. Defaults to `45.0`.
|
|
7924
|
+
* @returns {number | undefined}
|
|
7925
|
+
*/
|
|
7926
|
+
get maxAngle() {
|
|
7927
|
+
const ret = wasm.__wbg_get_textmaterial_maxAngle(this.__wbg_ptr);
|
|
7928
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7929
|
+
}
|
|
6647
7930
|
/**
|
|
6648
7931
|
* Maximum line width in ems (multiples of `size`) before text wraps at
|
|
6649
7932
|
* word boundaries. `0.0` (the default) disables wrapping; explicit `\n`
|
|
@@ -6662,6 +7945,16 @@ export class TextMaterial {
|
|
|
6662
7945
|
const ret = wasm.__wbg_get_textmaterial_offsetDepth(this.__wbg_ptr);
|
|
6663
7946
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6664
7947
|
}
|
|
7948
|
+
/**
|
|
7949
|
+
* Shift from the anchor point, x right and y down, in ems (multiples of
|
|
7950
|
+
* `size`), as MapLibre's `text-offset`. Lies in the label's own plane, so
|
|
7951
|
+
* it turns with `rotation`. Defaults to `(0, 0)`.
|
|
7952
|
+
* @returns {Vec2 | undefined}
|
|
7953
|
+
*/
|
|
7954
|
+
get offset() {
|
|
7955
|
+
const ret = wasm.__wbg_get_textmaterial_offset(this.__wbg_ptr);
|
|
7956
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
7957
|
+
}
|
|
6665
7958
|
/**
|
|
6666
7959
|
* Opacity of the text
|
|
6667
7960
|
* @returns {number | undefined}
|
|
@@ -6671,7 +7964,15 @@ export class TextMaterial {
|
|
|
6671
7964
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6672
7965
|
}
|
|
6673
7966
|
/**
|
|
6674
|
-
*
|
|
7967
|
+
* Width over which the outline's outer edge fades out, centered on that
|
|
7968
|
+
* edge, in the unit of `outlineWidth`. Defaults to `0.0`.
|
|
7969
|
+
* @returns {number | undefined}
|
|
7970
|
+
*/
|
|
7971
|
+
get outlineBlur() {
|
|
7972
|
+
const ret = wasm.__wbg_get_textmaterial_outlineBlur(this.__wbg_ptr);
|
|
7973
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
7974
|
+
}
|
|
7975
|
+
/**
|
|
6675
7976
|
* @returns {number | undefined}
|
|
6676
7977
|
*/
|
|
6677
7978
|
get outlineColor() {
|
|
@@ -6687,7 +7988,9 @@ export class TextMaterial {
|
|
|
6687
7988
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6688
7989
|
}
|
|
6689
7990
|
/**
|
|
6690
|
-
* Outline thickness
|
|
7991
|
+
* Outline thickness in 1/64 em: pixels of text drawn 64 pixels tall, so
|
|
7992
|
+
* the outline keeps its proportion to the glyphs at any size. Defaults
|
|
7993
|
+
* to `0.0`.
|
|
6691
7994
|
* @returns {number | undefined}
|
|
6692
7995
|
*/
|
|
6693
7996
|
get outlineWidth() {
|
|
@@ -6695,11 +7998,49 @@ export class TextMaterial {
|
|
|
6695
7998
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6696
7999
|
}
|
|
6697
8000
|
/**
|
|
6698
|
-
* Whether the label
|
|
6699
|
-
*
|
|
6700
|
-
*
|
|
6701
|
-
*
|
|
6702
|
-
*
|
|
8001
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
8002
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
8003
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
8004
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
8005
|
+
* @returns {string | undefined}
|
|
8006
|
+
*/
|
|
8007
|
+
get overlap() {
|
|
8008
|
+
const ret = wasm.__wbg_get_textmaterial_overlap(this.__wbg_ptr);
|
|
8009
|
+
let v1;
|
|
8010
|
+
if (ret[0] !== 0) {
|
|
8011
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
8012
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
8013
|
+
}
|
|
8014
|
+
return v1;
|
|
8015
|
+
}
|
|
8016
|
+
/**
|
|
8017
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
8018
|
+
* default) puts a label per line string, at its first vertex, and one
|
|
8019
|
+
* per polygon, `"line"` repeats labels along the line every `spacing`
|
|
8020
|
+
* with the glyphs bending to follow it, `"line-center"` places a single
|
|
8021
|
+
* label at the line's midpoint. Polygon rings are walked like lines.
|
|
8022
|
+
* Requires `geometryTypes` to include `"line"` or `"polygon"`.
|
|
8023
|
+
* @returns {string | undefined}
|
|
8024
|
+
*/
|
|
8025
|
+
get placement() {
|
|
8026
|
+
const ret = wasm.__wbg_get_textmaterial_placement(this.__wbg_ptr);
|
|
8027
|
+
let v1;
|
|
8028
|
+
if (ret[0] !== 0) {
|
|
8029
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
8030
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
8031
|
+
}
|
|
8032
|
+
return v1;
|
|
8033
|
+
}
|
|
8034
|
+
/**
|
|
8035
|
+
* Whether the label turns with the camera or with the map, as MapLibre's
|
|
8036
|
+
* `text-rotation-alignment` `viewport` and `map`. `true` keeps it reading
|
|
8037
|
+
* left to right (a screen-aligned billboard, or a flat label yawed to the
|
|
8038
|
+
* camera). `false` aligns it with the map: upright, it stays on screen but
|
|
8039
|
+
* turns with the camera heading so its x-axis points east; flat, it lies
|
|
8040
|
+
* north-up. Along a line, `false` makes the label follow the line, and
|
|
8041
|
+
* `true` draws it straight at its anchor unless `spreadGlyphs` is set.
|
|
8042
|
+
* Left unset, it is `true` for `placement: "point"` and `false` along a
|
|
8043
|
+
* line, as MapLibre resolves `auto`.
|
|
6703
8044
|
* @returns {boolean | undefined}
|
|
6704
8045
|
*/
|
|
6705
8046
|
get rotateWithCamera() {
|
|
@@ -6711,8 +8052,10 @@ export class TextMaterial {
|
|
|
6711
8052
|
* degrees, clockwise seen from the front. Applied on top of whatever
|
|
6712
8053
|
* orientation `textFacing` and `rotateWithCamera` resolve to: it spins a
|
|
6713
8054
|
* billboard on screen and turns a surface label like a compass bearing.
|
|
6714
|
-
* `
|
|
6715
|
-
*
|
|
8055
|
+
* `anchor` decides where inside the text the pivot sits. Along a line
|
|
8056
|
+
* each glyph spins about its own point on the line, as MapLibre's
|
|
8057
|
+
* `text-rotate` does, except for a straight label (`rotateWithCamera`
|
|
8058
|
+
* without `spreadGlyphs`), which turns as a whole. Defaults to `0.0`.
|
|
6716
8059
|
* @returns {number | undefined}
|
|
6717
8060
|
*/
|
|
6718
8061
|
get rotation() {
|
|
@@ -6742,9 +8085,52 @@ export class TextMaterial {
|
|
|
6742
8085
|
const ret = wasm.__wbg_get_textmaterial_size(this.__wbg_ptr);
|
|
6743
8086
|
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
6744
8087
|
}
|
|
8088
|
+
/**
|
|
8089
|
+
* Distance between repeated labels along a line, in screen pixels, for
|
|
8090
|
+
* `vector-tile` and `geojson` sources alike. Resolved per label as the
|
|
8091
|
+
* camera moves: labels thin out as it pulls back and fill in as it
|
|
8092
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
8093
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
8094
|
+
* `symbol-spacing`, a label longer than three quarters of the spacing
|
|
8095
|
+
* spreads its repeats to its own length plus a quarter of the spacing, a
|
|
8096
|
+
* label within half the spacing of an earlier one with the same text is
|
|
8097
|
+
* dropped, and a vector tile places labels only inside its own bounds.
|
|
8098
|
+
* Defaults to `250.0`.
|
|
8099
|
+
* @returns {number | undefined}
|
|
8100
|
+
*/
|
|
8101
|
+
get spacing() {
|
|
8102
|
+
const ret = wasm.__wbg_get_textmaterial_spacing(this.__wbg_ptr);
|
|
8103
|
+
return ret === Number.MAX_SAFE_INTEGER ? undefined : ret;
|
|
8104
|
+
}
|
|
8105
|
+
/**
|
|
8106
|
+
* Place each glyph of an along-line label on its own instead of each
|
|
8107
|
+
* word. With `rotateWithCamera: false` each glyph turns with the line
|
|
8108
|
+
* under it (MapLibre's `symbol-placement: "line"`); with `true`, each
|
|
8109
|
+
* glyph turns to the camera like a point label and is spaced on the
|
|
8110
|
+
* screen (MapLibre's `viewport-glyph`). Can be overridden per feature
|
|
8111
|
+
* from a feature evaluator. Defaults to `false`.
|
|
8112
|
+
* @returns {boolean | undefined}
|
|
8113
|
+
*/
|
|
8114
|
+
get spreadGlyphs() {
|
|
8115
|
+
const ret = wasm.__wbg_get_textmaterial_spreadGlyphs(this.__wbg_ptr);
|
|
8116
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
8117
|
+
}
|
|
8118
|
+
/**
|
|
8119
|
+
* Whether this may show while its partner at the same anchor (the
|
|
8120
|
+
* layer's label for a billboard, its billboard for a label) is hidden.
|
|
8121
|
+
* With `false` on both, the two are placed together: both show or
|
|
8122
|
+
* neither does. Only meaningful when `declutter` is enabled. Defaults to
|
|
8123
|
+
* `true`.
|
|
8124
|
+
* @returns {boolean | undefined}
|
|
8125
|
+
*/
|
|
8126
|
+
get standalone() {
|
|
8127
|
+
const ret = wasm.__wbg_get_textmaterial_standalone(this.__wbg_ptr);
|
|
8128
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
8129
|
+
}
|
|
6745
8130
|
/**
|
|
6746
8131
|
* Horizontal alignment of lines within a multi-line block:
|
|
6747
|
-
* `"left"`, `"center"` (default), or `"
|
|
8132
|
+
* `"left"`, `"center"` (default), `"right"`, or `"auto"`, which aligns
|
|
8133
|
+
* towards the horizontal side of `anchor` (MapLibre's `text-justify`).
|
|
6748
8134
|
* @returns {string | undefined}
|
|
6749
8135
|
*/
|
|
6750
8136
|
get textAlign() {
|
|
@@ -6757,9 +8143,13 @@ export class TextMaterial {
|
|
|
6757
8143
|
return v1;
|
|
6758
8144
|
}
|
|
6759
8145
|
/**
|
|
6760
|
-
*
|
|
6761
|
-
* globe surface around its anchor (`"flat"`), following its
|
|
6762
|
-
* it reads as painted on the surface.
|
|
8146
|
+
* Plane the label lies in: the screen (`"upright"`, never foreshortened)
|
|
8147
|
+
* or the globe surface around its anchor (`"flat"`), following its
|
|
8148
|
+
* curvature so it reads as painted on the surface. MapLibre's
|
|
8149
|
+
* `text-pitch-alignment` `viewport` and `map`. Pair with
|
|
8150
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
8151
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
8152
|
+
* `auto`.
|
|
6763
8153
|
* @returns {string | undefined}
|
|
6764
8154
|
*/
|
|
6765
8155
|
get textFacing() {
|
|
@@ -6783,6 +8173,31 @@ export class TextMaterial {
|
|
|
6783
8173
|
}
|
|
6784
8174
|
return v1;
|
|
6785
8175
|
}
|
|
8176
|
+
/**
|
|
8177
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
8178
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
8179
|
+
* the screen axes. MapLibre's `text-translate-anchor`.
|
|
8180
|
+
* @returns {string | undefined}
|
|
8181
|
+
*/
|
|
8182
|
+
get translateAnchor() {
|
|
8183
|
+
const ret = wasm.__wbg_get_textmaterial_translateAnchor(this.__wbg_ptr);
|
|
8184
|
+
let v1;
|
|
8185
|
+
if (ret[0] !== 0) {
|
|
8186
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
8187
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
8188
|
+
}
|
|
8189
|
+
return v1;
|
|
8190
|
+
}
|
|
8191
|
+
/**
|
|
8192
|
+
* Screen-pixel shift of the drawn label, x right and y down, applied after
|
|
8193
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
8194
|
+
* MapLibre's `text-translate`. Defaults to `(0, 0)`.
|
|
8195
|
+
* @returns {Vec2 | undefined}
|
|
8196
|
+
*/
|
|
8197
|
+
get translate() {
|
|
8198
|
+
const ret = wasm.__wbg_get_textmaterial_translate(this.__wbg_ptr);
|
|
8199
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
8200
|
+
}
|
|
6786
8201
|
/**
|
|
6787
8202
|
* Enable transparency and alpha blending
|
|
6788
8203
|
* @returns {boolean | undefined}
|
|
@@ -6792,10 +8207,40 @@ export class TextMaterial {
|
|
|
6792
8207
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
6793
8208
|
}
|
|
6794
8209
|
/**
|
|
6795
|
-
*
|
|
6796
|
-
*
|
|
6797
|
-
*
|
|
6798
|
-
*
|
|
8210
|
+
* Placements the declutter pass tries in order, keeping the first whose
|
|
8211
|
+
* box is free, as MapLibre's `text-variable-anchor-offset`. The one in
|
|
8212
|
+
* use is tried first, so a label only moves when it must. Overrides
|
|
8213
|
+
* `anchor` and `offset` when not empty, except along a line. Without
|
|
8214
|
+
* declutter the first is used.
|
|
8215
|
+
* @returns {VariableAnchor[] | undefined}
|
|
8216
|
+
*/
|
|
8217
|
+
get variableAnchors() {
|
|
8218
|
+
const ret = wasm.__wbg_get_textmaterial_variableAnchors(this.__wbg_ptr);
|
|
8219
|
+
let v1;
|
|
8220
|
+
if (ret[0] !== 0) {
|
|
8221
|
+
v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
8222
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
8223
|
+
}
|
|
8224
|
+
return v1;
|
|
8225
|
+
}
|
|
8226
|
+
/**
|
|
8227
|
+
* Part of the text block placed at the anchor point: `"center"`
|
|
8228
|
+
* (default), `"left"`, `"right"`, `"top"`, `"bottom"`, `"top-left"`,
|
|
8229
|
+
* `"top-right"`, `"bottom-left"` or `"bottom-right"`, as MapLibre's
|
|
8230
|
+
* `text-anchor`. The block is as wide as its widest line and one line
|
|
8231
|
+
* height tall per line.
|
|
8232
|
+
* @param {string | null} [arg0]
|
|
8233
|
+
*/
|
|
8234
|
+
set anchor(arg0) {
|
|
8235
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8236
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8237
|
+
wasm.__wbg_set_textmaterial_anchor(this.__wbg_ptr, ptr0, len0);
|
|
8238
|
+
}
|
|
8239
|
+
/**
|
|
8240
|
+
* Whether faces seen from behind are culled. Default is false. Only a
|
|
8241
|
+
* flat quad has a back the camera can see: turn it on to hide the parts
|
|
8242
|
+
* of a large one that wrap over the horizon, which face away from the
|
|
8243
|
+
* camera.
|
|
6799
8244
|
* @param {boolean | null} [arg0]
|
|
6800
8245
|
*/
|
|
6801
8246
|
set backfaceCulling(arg0) {
|
|
@@ -6819,17 +8264,6 @@ export class TextMaterial {
|
|
|
6819
8264
|
set borderWidth(arg0) {
|
|
6820
8265
|
wasm.__wbg_set_textmaterial_borderWidth(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6821
8266
|
}
|
|
6822
|
-
/**
|
|
6823
|
-
* @param {Vec2 | null} [arg0]
|
|
6824
|
-
*/
|
|
6825
|
-
set center(arg0) {
|
|
6826
|
-
let ptr0 = 0;
|
|
6827
|
-
if (!isLikeNone(arg0)) {
|
|
6828
|
-
_assertClass(arg0, Vec2);
|
|
6829
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
6830
|
-
}
|
|
6831
|
-
wasm.__wbg_set_textmaterial_center(this.__wbg_ptr, ptr0);
|
|
6832
|
-
}
|
|
6833
8267
|
/**
|
|
6834
8268
|
* @param {boolean | null} [arg0]
|
|
6835
8269
|
*/
|
|
@@ -6842,6 +8276,17 @@ export class TextMaterial {
|
|
|
6842
8276
|
set color(arg0) {
|
|
6843
8277
|
wasm.__wbg_set_textmaterial_color(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : (arg0) >>> 0);
|
|
6844
8278
|
}
|
|
8279
|
+
/**
|
|
8280
|
+
* Extra space around the collision box, in screen pixels: one to four
|
|
8281
|
+
* values, expanded like CSS padding (top, right, bottom, left). Only
|
|
8282
|
+
* meaningful when `declutter` is enabled. Defaults to `[2]`.
|
|
8283
|
+
* @param {Float32Array | null} [arg0]
|
|
8284
|
+
*/
|
|
8285
|
+
set declutterPadding(arg0) {
|
|
8286
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayF32ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
8287
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8288
|
+
wasm.__wbg_set_textmaterial_declutterPadding(this.__wbg_ptr, ptr0, len0);
|
|
8289
|
+
}
|
|
6845
8290
|
/**
|
|
6846
8291
|
* Placement priority for decluttering; higher wins. Only meaningful when
|
|
6847
8292
|
* `declutter` is enabled. Defaults to `0.0`.
|
|
@@ -6850,6 +8295,16 @@ export class TextMaterial {
|
|
|
6850
8295
|
set declutterPriority(arg0) {
|
|
6851
8296
|
wasm.__wbg_set_textmaterial_declutterPriority(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6852
8297
|
}
|
|
8298
|
+
/**
|
|
8299
|
+
* Coarse placement order for decluttering, compared before
|
|
8300
|
+
* `declutterPriority`: every label with a higher rank is placed before any
|
|
8301
|
+
* label with a lower one, whatever their priorities. Only meaningful when
|
|
8302
|
+
* `declutter` is enabled. Defaults to `0.0`.
|
|
8303
|
+
* @param {number | null} [arg0]
|
|
8304
|
+
*/
|
|
8305
|
+
set declutterRank(arg0) {
|
|
8306
|
+
wasm.__wbg_set_textmaterial_declutterRank(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8307
|
+
}
|
|
6853
8308
|
/**
|
|
6854
8309
|
* Participate in screen-space decluttering: when labels/sprites overlap
|
|
6855
8310
|
* on screen, lower-priority ones are hidden. Defaults to `true`; set to
|
|
@@ -6911,8 +8366,9 @@ export class TextMaterial {
|
|
|
6911
8366
|
}
|
|
6912
8367
|
/**
|
|
6913
8368
|
* Source geometry types this appearance consumes: `"point"`, `"line"`,
|
|
6914
|
-
* `"polygon"`. Defaults to `["point"]`; adding `"line"
|
|
6915
|
-
*
|
|
8369
|
+
* `"polygon"`. Defaults to `["point"]`; adding `"line"` also emits a
|
|
8370
|
+
* label per line string, at its first vertex, and `"polygon"` one per
|
|
8371
|
+
* polygon.
|
|
6916
8372
|
* @param {string[] | null} [arg0]
|
|
6917
8373
|
*/
|
|
6918
8374
|
set geometryTypes(arg0) {
|
|
@@ -6937,6 +8393,23 @@ export class TextMaterial {
|
|
|
6937
8393
|
set highQuality(arg0) {
|
|
6938
8394
|
wasm.__wbg_set_textmaterial_highQuality(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6939
8395
|
}
|
|
8396
|
+
/**
|
|
8397
|
+
* Leave this label's box out of the collision grid, so symbols placed
|
|
8398
|
+
* after it may overlap it. Only meaningful when `declutter` is enabled.
|
|
8399
|
+
* Defaults to `false`.
|
|
8400
|
+
* @param {boolean | null} [arg0]
|
|
8401
|
+
*/
|
|
8402
|
+
set ignorePlacement(arg0) {
|
|
8403
|
+
wasm.__wbg_set_textmaterial_ignorePlacement(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
8404
|
+
}
|
|
8405
|
+
/**
|
|
8406
|
+
* Flip a label that would otherwise read right-to-left, so names stay
|
|
8407
|
+
* legible whichever way the underlying line runs. Defaults to `true`.
|
|
8408
|
+
* @param {boolean | null} [arg0]
|
|
8409
|
+
*/
|
|
8410
|
+
set keepUpright(arg0) {
|
|
8411
|
+
wasm.__wbg_set_textmaterial_keepUpright(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
8412
|
+
}
|
|
6940
8413
|
/**
|
|
6941
8414
|
* Language code for text shaping (e.g., "en", "ja", "ar"). Used for proper text rendering.
|
|
6942
8415
|
* @param {string | null} [arg0]
|
|
@@ -6947,13 +8420,43 @@ export class TextMaterial {
|
|
|
6947
8420
|
wasm.__wbg_set_textmaterial_lang(this.__wbg_ptr, ptr0, len0);
|
|
6948
8421
|
}
|
|
6949
8422
|
/**
|
|
6950
|
-
*
|
|
6951
|
-
*
|
|
8423
|
+
* Extra space between characters, in ems (multiples of `size`). Not
|
|
8424
|
+
* added after the last character; ignored for Arabic-script text.
|
|
8425
|
+
* Negative values tighten. Defaults to `0.0`.
|
|
8426
|
+
* @param {number | null} [arg0]
|
|
8427
|
+
*/
|
|
8428
|
+
set letterSpacing(arg0) {
|
|
8429
|
+
wasm.__wbg_set_textmaterial_letterSpacing(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8430
|
+
}
|
|
8431
|
+
/**
|
|
8432
|
+
* Distance between the baselines of a multi-line label, in ems
|
|
8433
|
+
* (multiples of `size`). Defaults to the font's natural line height
|
|
8434
|
+
* (ascender − descender + line gap).
|
|
6952
8435
|
* @param {number | null} [arg0]
|
|
6953
8436
|
*/
|
|
6954
8437
|
set lineHeight(arg0) {
|
|
6955
8438
|
wasm.__wbg_set_textmaterial_lineHeight(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6956
8439
|
}
|
|
8440
|
+
/**
|
|
8441
|
+
* Offset perpendicular to the line, in the same units as the font size:
|
|
8442
|
+
* pixels when `sizeInMeters` is false, metres when it is true. Positive is
|
|
8443
|
+
* to the left of the direction of travel, which puts the name above the
|
|
8444
|
+
* line. Defaults to `0.0`.
|
|
8445
|
+
* @param {number | null} [arg0]
|
|
8446
|
+
*/
|
|
8447
|
+
set lineOffset(arg0) {
|
|
8448
|
+
wasm.__wbg_set_textmaterial_lineOffset(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8449
|
+
}
|
|
8450
|
+
/**
|
|
8451
|
+
* Largest turn, in degrees, the line may make under a label within a
|
|
8452
|
+
* window of about one and a half ems before the label is dropped as
|
|
8453
|
+
* unreadable. The window slides along the label, so a long gentle curve
|
|
8454
|
+
* is accepted however far it turns in total. Defaults to `45.0`.
|
|
8455
|
+
* @param {number | null} [arg0]
|
|
8456
|
+
*/
|
|
8457
|
+
set maxAngle(arg0) {
|
|
8458
|
+
wasm.__wbg_set_textmaterial_maxAngle(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8459
|
+
}
|
|
6957
8460
|
/**
|
|
6958
8461
|
* Maximum line width in ems (multiples of `size`) before text wraps at
|
|
6959
8462
|
* word boundaries. `0.0` (the default) disables wrapping; explicit `\n`
|
|
@@ -6970,6 +8473,20 @@ export class TextMaterial {
|
|
|
6970
8473
|
set offsetDepth(arg0) {
|
|
6971
8474
|
wasm.__wbg_set_textmaterial_offsetDepth(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
6972
8475
|
}
|
|
8476
|
+
/**
|
|
8477
|
+
* Shift from the anchor point, x right and y down, in ems (multiples of
|
|
8478
|
+
* `size`), as MapLibre's `text-offset`. Lies in the label's own plane, so
|
|
8479
|
+
* it turns with `rotation`. Defaults to `(0, 0)`.
|
|
8480
|
+
* @param {Vec2 | null} [arg0]
|
|
8481
|
+
*/
|
|
8482
|
+
set offset(arg0) {
|
|
8483
|
+
let ptr0 = 0;
|
|
8484
|
+
if (!isLikeNone(arg0)) {
|
|
8485
|
+
_assertClass(arg0, Vec2);
|
|
8486
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
8487
|
+
}
|
|
8488
|
+
wasm.__wbg_set_textmaterial_offset(this.__wbg_ptr, ptr0);
|
|
8489
|
+
}
|
|
6973
8490
|
/**
|
|
6974
8491
|
* Opacity of the text
|
|
6975
8492
|
* @param {number | null} [arg0]
|
|
@@ -6978,7 +8495,14 @@ export class TextMaterial {
|
|
|
6978
8495
|
wasm.__wbg_set_textmaterial_opacity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6979
8496
|
}
|
|
6980
8497
|
/**
|
|
6981
|
-
*
|
|
8498
|
+
* Width over which the outline's outer edge fades out, centered on that
|
|
8499
|
+
* edge, in the unit of `outlineWidth`. Defaults to `0.0`.
|
|
8500
|
+
* @param {number | null} [arg0]
|
|
8501
|
+
*/
|
|
8502
|
+
set outlineBlur(arg0) {
|
|
8503
|
+
wasm.__wbg_set_textmaterial_outlineBlur(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8504
|
+
}
|
|
8505
|
+
/**
|
|
6982
8506
|
* @param {number | null} [arg0]
|
|
6983
8507
|
*/
|
|
6984
8508
|
set outlineColor(arg0) {
|
|
@@ -6992,18 +8516,50 @@ export class TextMaterial {
|
|
|
6992
8516
|
wasm.__wbg_set_textmaterial_outlineOpacity(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
6993
8517
|
}
|
|
6994
8518
|
/**
|
|
6995
|
-
* Outline thickness
|
|
8519
|
+
* Outline thickness in 1/64 em: pixels of text drawn 64 pixels tall, so
|
|
8520
|
+
* the outline keeps its proportion to the glyphs at any size. Defaults
|
|
8521
|
+
* to `0.0`.
|
|
6996
8522
|
* @param {number | null} [arg0]
|
|
6997
8523
|
*/
|
|
6998
8524
|
set outlineWidth(arg0) {
|
|
6999
8525
|
wasm.__wbg_set_textmaterial_outlineWidth(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7000
8526
|
}
|
|
7001
8527
|
/**
|
|
7002
|
-
* Whether the label
|
|
7003
|
-
*
|
|
7004
|
-
*
|
|
7005
|
-
*
|
|
7006
|
-
*
|
|
8528
|
+
* Whether the label may be drawn over symbols placed before it:
|
|
8529
|
+
* `"never"` (the default) hides it on any collision, `"always"` never
|
|
8530
|
+
* does, `"cooperative"` hides it only when it collides with a `"never"`
|
|
8531
|
+
* symbol. Only meaningful when `declutter` is enabled.
|
|
8532
|
+
* @param {string | null} [arg0]
|
|
8533
|
+
*/
|
|
8534
|
+
set overlap(arg0) {
|
|
8535
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8536
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8537
|
+
wasm.__wbg_set_textmaterial_overlap(this.__wbg_ptr, ptr0, len0);
|
|
8538
|
+
}
|
|
8539
|
+
/**
|
|
8540
|
+
* How anchors are derived from line and polygon geometry: `"point"` (the
|
|
8541
|
+
* default) puts a label per line string, at its first vertex, and one
|
|
8542
|
+
* per polygon, `"line"` repeats labels along the line every `spacing`
|
|
8543
|
+
* with the glyphs bending to follow it, `"line-center"` places a single
|
|
8544
|
+
* label at the line's midpoint. Polygon rings are walked like lines.
|
|
8545
|
+
* Requires `geometryTypes` to include `"line"` or `"polygon"`.
|
|
8546
|
+
* @param {string | null} [arg0]
|
|
8547
|
+
*/
|
|
8548
|
+
set placement(arg0) {
|
|
8549
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8550
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8551
|
+
wasm.__wbg_set_textmaterial_placement(this.__wbg_ptr, ptr0, len0);
|
|
8552
|
+
}
|
|
8553
|
+
/**
|
|
8554
|
+
* Whether the label turns with the camera or with the map, as MapLibre's
|
|
8555
|
+
* `text-rotation-alignment` `viewport` and `map`. `true` keeps it reading
|
|
8556
|
+
* left to right (a screen-aligned billboard, or a flat label yawed to the
|
|
8557
|
+
* camera). `false` aligns it with the map: upright, it stays on screen but
|
|
8558
|
+
* turns with the camera heading so its x-axis points east; flat, it lies
|
|
8559
|
+
* north-up. Along a line, `false` makes the label follow the line, and
|
|
8560
|
+
* `true` draws it straight at its anchor unless `spreadGlyphs` is set.
|
|
8561
|
+
* Left unset, it is `true` for `placement: "point"` and `false` along a
|
|
8562
|
+
* line, as MapLibre resolves `auto`.
|
|
7007
8563
|
* @param {boolean | null} [arg0]
|
|
7008
8564
|
*/
|
|
7009
8565
|
set rotateWithCamera(arg0) {
|
|
@@ -7014,8 +8570,10 @@ export class TextMaterial {
|
|
|
7014
8570
|
* degrees, clockwise seen from the front. Applied on top of whatever
|
|
7015
8571
|
* orientation `textFacing` and `rotateWithCamera` resolve to: it spins a
|
|
7016
8572
|
* billboard on screen and turns a surface label like a compass bearing.
|
|
7017
|
-
* `
|
|
7018
|
-
*
|
|
8573
|
+
* `anchor` decides where inside the text the pivot sits. Along a line
|
|
8574
|
+
* each glyph spins about its own point on the line, as MapLibre's
|
|
8575
|
+
* `text-rotate` does, except for a straight label (`rotateWithCamera`
|
|
8576
|
+
* without `spreadGlyphs`), which turns as a whole. Defaults to `0.0`.
|
|
7019
8577
|
* @param {number | null} [arg0]
|
|
7020
8578
|
*/
|
|
7021
8579
|
set rotation(arg0) {
|
|
@@ -7041,9 +8599,49 @@ export class TextMaterial {
|
|
|
7041
8599
|
set size(arg0) {
|
|
7042
8600
|
wasm.__wbg_set_textmaterial_size(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
7043
8601
|
}
|
|
8602
|
+
/**
|
|
8603
|
+
* Distance between repeated labels along a line, in screen pixels, for
|
|
8604
|
+
* `vector-tile` and `geojson` sources alike. Resolved per label as the
|
|
8605
|
+
* camera moves: labels thin out as it pulls back and fill in as it
|
|
8606
|
+
* closes, never moving, so the gap on screen stays between one and two
|
|
8607
|
+
* times `spacing` across a pitched view. As MapLibre does with
|
|
8608
|
+
* `symbol-spacing`, a label longer than three quarters of the spacing
|
|
8609
|
+
* spreads its repeats to its own length plus a quarter of the spacing, a
|
|
8610
|
+
* label within half the spacing of an earlier one with the same text is
|
|
8611
|
+
* dropped, and a vector tile places labels only inside its own bounds.
|
|
8612
|
+
* Defaults to `250.0`.
|
|
8613
|
+
* @param {number | null} [arg0]
|
|
8614
|
+
*/
|
|
8615
|
+
set spacing(arg0) {
|
|
8616
|
+
wasm.__wbg_set_textmaterial_spacing(this.__wbg_ptr, isLikeNone(arg0) ? Number.MAX_SAFE_INTEGER : Math.fround(arg0));
|
|
8617
|
+
}
|
|
8618
|
+
/**
|
|
8619
|
+
* Place each glyph of an along-line label on its own instead of each
|
|
8620
|
+
* word. With `rotateWithCamera: false` each glyph turns with the line
|
|
8621
|
+
* under it (MapLibre's `symbol-placement: "line"`); with `true`, each
|
|
8622
|
+
* glyph turns to the camera like a point label and is spaced on the
|
|
8623
|
+
* screen (MapLibre's `viewport-glyph`). Can be overridden per feature
|
|
8624
|
+
* from a feature evaluator. Defaults to `false`.
|
|
8625
|
+
* @param {boolean | null} [arg0]
|
|
8626
|
+
*/
|
|
8627
|
+
set spreadGlyphs(arg0) {
|
|
8628
|
+
wasm.__wbg_set_textmaterial_spreadGlyphs(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
8629
|
+
}
|
|
8630
|
+
/**
|
|
8631
|
+
* Whether this may show while its partner at the same anchor (the
|
|
8632
|
+
* layer's label for a billboard, its billboard for a label) is hidden.
|
|
8633
|
+
* With `false` on both, the two are placed together: both show or
|
|
8634
|
+
* neither does. Only meaningful when `declutter` is enabled. Defaults to
|
|
8635
|
+
* `true`.
|
|
8636
|
+
* @param {boolean | null} [arg0]
|
|
8637
|
+
*/
|
|
8638
|
+
set standalone(arg0) {
|
|
8639
|
+
wasm.__wbg_set_textmaterial_standalone(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
8640
|
+
}
|
|
7044
8641
|
/**
|
|
7045
8642
|
* Horizontal alignment of lines within a multi-line block:
|
|
7046
|
-
* `"left"`, `"center"` (default), or `"
|
|
8643
|
+
* `"left"`, `"center"` (default), `"right"`, or `"auto"`, which aligns
|
|
8644
|
+
* towards the horizontal side of `anchor` (MapLibre's `text-justify`).
|
|
7047
8645
|
* @param {string | null} [arg0]
|
|
7048
8646
|
*/
|
|
7049
8647
|
set textAlign(arg0) {
|
|
@@ -7052,9 +8650,13 @@ export class TextMaterial {
|
|
|
7052
8650
|
wasm.__wbg_set_textmaterial_textAlign(this.__wbg_ptr, ptr0, len0);
|
|
7053
8651
|
}
|
|
7054
8652
|
/**
|
|
7055
|
-
*
|
|
7056
|
-
* globe surface around its anchor (`"flat"`), following its
|
|
7057
|
-
* it reads as painted on the surface.
|
|
8653
|
+
* Plane the label lies in: the screen (`"upright"`, never foreshortened)
|
|
8654
|
+
* or the globe surface around its anchor (`"flat"`), following its
|
|
8655
|
+
* curvature so it reads as painted on the surface. MapLibre's
|
|
8656
|
+
* `text-pitch-alignment` `viewport` and `map`. Pair with
|
|
8657
|
+
* `rotateWithCamera`. Left unset, it is `"flat"` when `rotateWithCamera`
|
|
8658
|
+
* resolves to `false` and `"upright"` otherwise, as MapLibre resolves
|
|
8659
|
+
* `auto`.
|
|
7058
8660
|
* @param {string | null} [arg0]
|
|
7059
8661
|
*/
|
|
7060
8662
|
set textFacing(arg0) {
|
|
@@ -7070,6 +8672,31 @@ export class TextMaterial {
|
|
|
7070
8672
|
var len0 = WASM_VECTOR_LEN;
|
|
7071
8673
|
wasm.__wbg_set_textmaterial_text(this.__wbg_ptr, ptr0, len0);
|
|
7072
8674
|
}
|
|
8675
|
+
/**
|
|
8676
|
+
* Frame `translate` is measured in: `"map"` (default) turns it with the
|
|
8677
|
+
* camera heading so +x points east and +y south; `"viewport"` keeps it on
|
|
8678
|
+
* the screen axes. MapLibre's `text-translate-anchor`.
|
|
8679
|
+
* @param {string | null} [arg0]
|
|
8680
|
+
*/
|
|
8681
|
+
set translateAnchor(arg0) {
|
|
8682
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8683
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8684
|
+
wasm.__wbg_set_textmaterial_translateAnchor(this.__wbg_ptr, ptr0, len0);
|
|
8685
|
+
}
|
|
8686
|
+
/**
|
|
8687
|
+
* Screen-pixel shift of the drawn label, x right and y down, applied after
|
|
8688
|
+
* projection so it stays the same number of pixels at any distance, as
|
|
8689
|
+
* MapLibre's `text-translate`. Defaults to `(0, 0)`.
|
|
8690
|
+
* @param {Vec2 | null} [arg0]
|
|
8691
|
+
*/
|
|
8692
|
+
set translate(arg0) {
|
|
8693
|
+
let ptr0 = 0;
|
|
8694
|
+
if (!isLikeNone(arg0)) {
|
|
8695
|
+
_assertClass(arg0, Vec2);
|
|
8696
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
8697
|
+
}
|
|
8698
|
+
wasm.__wbg_set_textmaterial_translate(this.__wbg_ptr, ptr0);
|
|
8699
|
+
}
|
|
7073
8700
|
/**
|
|
7074
8701
|
* Enable transparency and alpha blending
|
|
7075
8702
|
* @param {boolean | null} [arg0]
|
|
@@ -7077,6 +8704,19 @@ export class TextMaterial {
|
|
|
7077
8704
|
set transparent(arg0) {
|
|
7078
8705
|
wasm.__wbg_set_textmaterial_transparent(this.__wbg_ptr, isLikeNone(arg0) ? 0xFFFFFF : arg0 ? 1 : 0);
|
|
7079
8706
|
}
|
|
8707
|
+
/**
|
|
8708
|
+
* Placements the declutter pass tries in order, keeping the first whose
|
|
8709
|
+
* box is free, as MapLibre's `text-variable-anchor-offset`. The one in
|
|
8710
|
+
* use is tried first, so a label only moves when it must. Overrides
|
|
8711
|
+
* `anchor` and `offset` when not empty, except along a line. Without
|
|
8712
|
+
* declutter the first is used.
|
|
8713
|
+
* @param {VariableAnchor[] | null} [arg0]
|
|
8714
|
+
*/
|
|
8715
|
+
set variableAnchors(arg0) {
|
|
8716
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
8717
|
+
var len0 = WASM_VECTOR_LEN;
|
|
8718
|
+
wasm.__wbg_set_textmaterial_variableAnchors(this.__wbg_ptr, ptr0, len0);
|
|
8719
|
+
}
|
|
7080
8720
|
}
|
|
7081
8721
|
if (Symbol.dispose) TextMaterial.prototype[Symbol.dispose] = TextMaterial.prototype.free;
|
|
7082
8722
|
|
|
@@ -8095,6 +9735,83 @@ export class UpsamplableTerrainGeometry {
|
|
|
8095
9735
|
}
|
|
8096
9736
|
if (Symbol.dispose) UpsamplableTerrainGeometry.prototype[Symbol.dispose] = UpsamplableTerrainGeometry.prototype.free;
|
|
8097
9737
|
|
|
9738
|
+
/**
|
|
9739
|
+
* One placement a label may take, as an entry of MapLibre's
|
|
9740
|
+
* `text-variable-anchor-offset`.
|
|
9741
|
+
*/
|
|
9742
|
+
export class VariableAnchor {
|
|
9743
|
+
static __wrap(ptr) {
|
|
9744
|
+
const obj = Object.create(VariableAnchor.prototype);
|
|
9745
|
+
obj.__wbg_ptr = ptr;
|
|
9746
|
+
VariableAnchorFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
9747
|
+
return obj;
|
|
9748
|
+
}
|
|
9749
|
+
static __unwrap(jsValue) {
|
|
9750
|
+
if (!(jsValue instanceof VariableAnchor)) {
|
|
9751
|
+
return 0;
|
|
9752
|
+
}
|
|
9753
|
+
return jsValue.__destroy_into_raw();
|
|
9754
|
+
}
|
|
9755
|
+
__destroy_into_raw() {
|
|
9756
|
+
const ptr = this.__wbg_ptr;
|
|
9757
|
+
this.__wbg_ptr = 0;
|
|
9758
|
+
VariableAnchorFinalization.unregister(this);
|
|
9759
|
+
return ptr;
|
|
9760
|
+
}
|
|
9761
|
+
free() {
|
|
9762
|
+
const ptr = this.__destroy_into_raw();
|
|
9763
|
+
wasm.__wbg_variableanchor_free(ptr, 0);
|
|
9764
|
+
}
|
|
9765
|
+
/**
|
|
9766
|
+
* Part of the text block placed at the anchor point, as `anchor`.
|
|
9767
|
+
* @returns {string}
|
|
9768
|
+
*/
|
|
9769
|
+
get anchor() {
|
|
9770
|
+
let deferred1_0;
|
|
9771
|
+
let deferred1_1;
|
|
9772
|
+
try {
|
|
9773
|
+
const ret = wasm.__wbg_get_variableanchor_anchor(this.__wbg_ptr);
|
|
9774
|
+
deferred1_0 = ret[0];
|
|
9775
|
+
deferred1_1 = ret[1];
|
|
9776
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
9777
|
+
} finally {
|
|
9778
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
9779
|
+
}
|
|
9780
|
+
}
|
|
9781
|
+
/**
|
|
9782
|
+
* Shift from the anchor point, x right and y down, in ems. Defaults to
|
|
9783
|
+
* `(0, 0)`.
|
|
9784
|
+
* @returns {Vec2 | undefined}
|
|
9785
|
+
*/
|
|
9786
|
+
get offset() {
|
|
9787
|
+
const ret = wasm.__wbg_get_variableanchor_offset(this.__wbg_ptr);
|
|
9788
|
+
return ret === 0 ? undefined : Vec2.__wrap(ret);
|
|
9789
|
+
}
|
|
9790
|
+
/**
|
|
9791
|
+
* Part of the text block placed at the anchor point, as `anchor`.
|
|
9792
|
+
* @param {string} arg0
|
|
9793
|
+
*/
|
|
9794
|
+
set anchor(arg0) {
|
|
9795
|
+
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
9796
|
+
const len0 = WASM_VECTOR_LEN;
|
|
9797
|
+
wasm.__wbg_set_variableanchor_anchor(this.__wbg_ptr, ptr0, len0);
|
|
9798
|
+
}
|
|
9799
|
+
/**
|
|
9800
|
+
* Shift from the anchor point, x right and y down, in ems. Defaults to
|
|
9801
|
+
* `(0, 0)`.
|
|
9802
|
+
* @param {Vec2 | null} [arg0]
|
|
9803
|
+
*/
|
|
9804
|
+
set offset(arg0) {
|
|
9805
|
+
let ptr0 = 0;
|
|
9806
|
+
if (!isLikeNone(arg0)) {
|
|
9807
|
+
_assertClass(arg0, Vec2);
|
|
9808
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
9809
|
+
}
|
|
9810
|
+
wasm.__wbg_set_variableanchor_offset(this.__wbg_ptr, ptr0);
|
|
9811
|
+
}
|
|
9812
|
+
}
|
|
9813
|
+
if (Symbol.dispose) VariableAnchor.prototype[Symbol.dispose] = VariableAnchor.prototype.free;
|
|
9814
|
+
|
|
8098
9815
|
export class Vec2 {
|
|
8099
9816
|
static __wrap(ptr) {
|
|
8100
9817
|
const obj = Object.create(Vec2.prototype);
|
|
@@ -8767,6 +10484,14 @@ function __wbg_get_imports() {
|
|
|
8767
10484
|
const ret = arg0.value;
|
|
8768
10485
|
return ret;
|
|
8769
10486
|
},
|
|
10487
|
+
__wbg_variableanchor_new: function(arg0) {
|
|
10488
|
+
const ret = VariableAnchor.__wrap(arg0);
|
|
10489
|
+
return ret;
|
|
10490
|
+
},
|
|
10491
|
+
__wbg_variableanchor_unwrap: function(arg0) {
|
|
10492
|
+
const ret = VariableAnchor.__unwrap(arg0);
|
|
10493
|
+
return ret;
|
|
10494
|
+
},
|
|
8770
10495
|
__wbindgen_cast_0000000000000001: function(arg0) {
|
|
8771
10496
|
// Cast intrinsic for `F64 -> Externref`.
|
|
8772
10497
|
const ret = arg0;
|
|
@@ -8983,6 +10708,9 @@ const UintAttributeFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
|
8983
10708
|
const UpsamplableTerrainGeometryFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
8984
10709
|
? { register: () => {}, unregister: () => {} }
|
|
8985
10710
|
: new FinalizationRegistry(ptr => wasm.__wbg_upsamplableterraingeometry_free(ptr, 1));
|
|
10711
|
+
const VariableAnchorFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
10712
|
+
? { register: () => {}, unregister: () => {} }
|
|
10713
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_variableanchor_free(ptr, 1));
|
|
8986
10714
|
const Vec2Finalization = (typeof FinalizationRegistry === 'undefined')
|
|
8987
10715
|
? { register: () => {}, unregister: () => {} }
|
|
8988
10716
|
: new FinalizationRegistry(ptr => wasm.__wbg_vec2_free(ptr, 1));
|