@fxi/zartigl 0.10.3 → 0.10.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/catalog.d.ts +2 -0
- package/dist/catalog.js +1 -1
- package/dist/engine.d.ts +2 -0
- package/dist/{index-vBlS9sIT.js → index-CNtMu8AU.js} +4 -2
- package/dist/zartigl.d.ts +22 -0
- package/dist/zartigl.js +1274 -1171
- package/package.json +1 -1
package/dist/catalog.d.ts
CHANGED
|
@@ -275,6 +275,8 @@ export declare interface ParticleStyle {
|
|
|
275
275
|
grade: ParticleGrade;
|
|
276
276
|
/** Solid color under the trails; replaced as a whole, not merged. */
|
|
277
277
|
backdrop: BackdropStyle;
|
|
278
|
+
/** Halo of the trails' own color, [0, 1]; 0 is off. */
|
|
279
|
+
glow: number;
|
|
278
280
|
}
|
|
279
281
|
|
|
280
282
|
/** Partial particle style; a partial backdrop takes the defaults' keys. */
|
package/dist/catalog.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as s, L as r, P as t, h as o, R as l, i, j as y, g as L, k as S, l as E, n as c, o as g, q as T, t as d, m, a as n, p as C, e as R, d as _, u as f, v as p, r as A, w as v, c as Y, x as u, b as P, s as k } from "./index-
|
|
1
|
+
import { C as s, L as r, P as t, h as o, R as l, i, j as y, g as L, k as S, l as E, n as c, o as g, q as T, t as d, m, a as n, p as C, e as R, d as _, u as f, v as p, r as A, w as v, c as Y, x as u, b as P, s as k } from "./index-CNtMu8AU.js";
|
|
2
2
|
export {
|
|
3
3
|
s as CATALOG_URL,
|
|
4
4
|
r as LAYER_STYLE_DEFAULTS,
|
package/dist/engine.d.ts
CHANGED
|
@@ -961,6 +961,8 @@ declare interface ParticleStyle {
|
|
|
961
961
|
grade: ParticleGrade;
|
|
962
962
|
/** Solid color under the trails; replaced as a whole, not merged. */
|
|
963
963
|
backdrop: BackdropStyle;
|
|
964
|
+
/** Halo of the trails' own color, [0, 1]; 0 is off. */
|
|
965
|
+
glow: number;
|
|
964
966
|
}
|
|
965
967
|
|
|
966
968
|
/** Partial particle style; a partial backdrop takes the defaults' keys. */
|
|
@@ -11,7 +11,8 @@ const O = 2, U = "en", G = /* @__PURE__ */ JSON.parse('[{"id":"61a81ddd-6c8e-402
|
|
|
11
11
|
speed: 1,
|
|
12
12
|
fade: 0.7,
|
|
13
13
|
grade: "off",
|
|
14
|
-
backdrop: D
|
|
14
|
+
backdrop: D,
|
|
15
|
+
glow: 0
|
|
15
16
|
}),
|
|
16
17
|
raster: Object.freeze({
|
|
17
18
|
opacity: 1,
|
|
@@ -92,6 +93,7 @@ const M = [
|
|
|
92
93
|
density: [p(0, 0.2, !0), "a number in (0, 0.2]"],
|
|
93
94
|
speed: [p(0, 10, !0), "a number in (0, 10]"],
|
|
94
95
|
fade: [p(0, 1), "a number in [0, 1]"],
|
|
96
|
+
glow: [p(0, 1), "a number in [0, 1]"],
|
|
95
97
|
grade: [
|
|
96
98
|
(e) => W.includes(e) || B(e),
|
|
97
99
|
`"off", "vibrant" or an object of ${Object.keys(v).join(", ")} in range`
|
|
@@ -189,7 +191,7 @@ function _e(e, a, o = {}) {
|
|
|
189
191
|
}
|
|
190
192
|
return A(s);
|
|
191
193
|
}
|
|
192
|
-
const S = "0.10.
|
|
194
|
+
const S = "0.10.4", N = { "maplibre-gl": "^5.17.0" }, le = {
|
|
193
195
|
version: S,
|
|
194
196
|
devDependencies: N
|
|
195
197
|
}, F = "https://sos-ch-gva-2.exo.io/mapx-zartigl/catalog/v2/catalog.json";
|
package/dist/zartigl.d.ts
CHANGED
|
@@ -627,6 +627,7 @@ export declare class ParticleSimulation {
|
|
|
627
627
|
private drawProgram;
|
|
628
628
|
private fadeProgram;
|
|
629
629
|
private compositeProgram;
|
|
630
|
+
private glowProgram;
|
|
630
631
|
private gridProgram;
|
|
631
632
|
private gridGlobeProgram;
|
|
632
633
|
private particleStateTextures;
|
|
@@ -647,6 +648,8 @@ export declare class ParticleSimulation {
|
|
|
647
648
|
private screenFramebuffers;
|
|
648
649
|
private screenWidth;
|
|
649
650
|
private screenHeight;
|
|
651
|
+
private glowTexture;
|
|
652
|
+
private glowFramebuffer;
|
|
650
653
|
private quadBuffer;
|
|
651
654
|
private rasterGridBuffer;
|
|
652
655
|
private rasterGridIndexBuffer;
|
|
@@ -657,6 +660,7 @@ export declare class ParticleSimulation {
|
|
|
657
660
|
private drawLocs;
|
|
658
661
|
private fadeLocs;
|
|
659
662
|
private compositeLocs;
|
|
663
|
+
private glowLocs;
|
|
660
664
|
private gridLocs;
|
|
661
665
|
private gridGlobeLocs;
|
|
662
666
|
constructor(params?: Partial<SimulationParams>);
|
|
@@ -687,6 +691,12 @@ export declare class ParticleSimulation {
|
|
|
687
691
|
east: number;
|
|
688
692
|
north: number;
|
|
689
693
|
}, isGlobe?: boolean, globeCenter?: [number, number, number], clippingPlane?: [number, number, number, number], velocityPair?: VelocityTexturePair): void;
|
|
694
|
+
/**
|
|
695
|
+
* Reduce the latest trails into the glow texture (glow.glsl), then rebind
|
|
696
|
+
* `framebuffer` with the full viewport.
|
|
697
|
+
*/
|
|
698
|
+
private renderGlow;
|
|
699
|
+
private deleteGlowTarget;
|
|
690
700
|
renderGrid(velocityTexUnit: number, velocityMin: [number, number], velocityMax: [number, number], matrix: Iterable<number>, worldSize: number, worldCopyOffsets: number[], geoBounds: {
|
|
691
701
|
west: number;
|
|
692
702
|
south: number;
|
|
@@ -721,6 +731,8 @@ export declare class ParticleSimulation {
|
|
|
721
731
|
setColorGrade(grade: Partial<ColorGrade>): void;
|
|
722
732
|
/** Missing values take the defaults; see resolveBackdrop. */
|
|
723
733
|
setBackdrop(backdrop: Partial<BackdropStyle>): void;
|
|
734
|
+
/** Halo strength, clamped to [0, 1]; 0 frees the glow texture. */
|
|
735
|
+
setGlow(v: number): void;
|
|
724
736
|
setScalarMode(v: boolean): void;
|
|
725
737
|
setRgba8MaxParticleZoom(v: number): void;
|
|
726
738
|
/**
|
|
@@ -758,6 +770,7 @@ export declare interface ParticleSimulationDebugInfo {
|
|
|
758
770
|
vibrance: number;
|
|
759
771
|
colorGrade: ColorGrade;
|
|
760
772
|
backdrop: BackdropStyle;
|
|
773
|
+
glow: number;
|
|
761
774
|
scalarMode: boolean;
|
|
762
775
|
devicePixelRatio?: number;
|
|
763
776
|
webgl: WebGLRendererInfo | null;
|
|
@@ -778,6 +791,8 @@ declare interface ParticleStyle {
|
|
|
778
791
|
grade: ParticleGrade;
|
|
779
792
|
/** Solid color under the trails; replaced as a whole, not merged. */
|
|
780
793
|
backdrop: BackdropStyle;
|
|
794
|
+
/** Halo of the trails' own color, [0, 1]; 0 is off. */
|
|
795
|
+
glow: number;
|
|
781
796
|
}
|
|
782
797
|
|
|
783
798
|
/** Partial particle style; a partial backdrop takes the defaults' keys. */
|
|
@@ -980,6 +995,8 @@ declare interface SimulationParams {
|
|
|
980
995
|
colorGrade: ColorGrade;
|
|
981
996
|
/** Solid color under the trails, on valid cells; off by default. */
|
|
982
997
|
backdrop: BackdropStyle;
|
|
998
|
+
/** Halo of the trails' color, [0, 1]; 0 (default) skips its pass. */
|
|
999
|
+
glow: number;
|
|
983
1000
|
scalarMode: boolean;
|
|
984
1001
|
particleState: ParticleStateMode;
|
|
985
1002
|
rgba8MaxParticleZoom: number;
|
|
@@ -1190,6 +1207,7 @@ export declare class VectorLayer implements CustomLayerInterface {
|
|
|
1190
1207
|
setVibrance(v: number): void;
|
|
1191
1208
|
setColorGrade(grade: Partial<ColorGrade>): void;
|
|
1192
1209
|
setBackdrop(backdrop: Partial<BackdropStyle>): void;
|
|
1210
|
+
setGlow(v: number): void;
|
|
1193
1211
|
getDebugInfo(): VectorLayerDebugInfo;
|
|
1194
1212
|
on<K extends keyof LayerEventMap_2>(event: K, handler: LayerEventMap_2[K]): this;
|
|
1195
1213
|
off<K extends keyof LayerEventMap_2>(event: K, handler: LayerEventMap_2[K]): this;
|
|
@@ -1249,6 +1267,8 @@ export declare interface VectorLayerOptions {
|
|
|
1249
1267
|
colorGrade?: Partial<ColorGrade>;
|
|
1250
1268
|
/** Solid color under the trails, on valid cells. Omitted: off. */
|
|
1251
1269
|
backdrop?: Partial<BackdropStyle>;
|
|
1270
|
+
/** Halo of the trails' color, [0, 1]. Default 0 (off). */
|
|
1271
|
+
glow?: number;
|
|
1252
1272
|
unit?: string;
|
|
1253
1273
|
}
|
|
1254
1274
|
|
|
@@ -1851,6 +1871,8 @@ export declare interface ZartiglSettings {
|
|
|
1851
1871
|
colorGrade: Partial<ColorGrade>;
|
|
1852
1872
|
/** Solid color under particle trails, on valid cells; off by default. */
|
|
1853
1873
|
backdrop: Partial<BackdropStyle>;
|
|
1874
|
+
/** Halo of the particle trails' color, [0, 1]; 0 by default. */
|
|
1875
|
+
glow: number;
|
|
1854
1876
|
/** Fixed physical-value domain for scalar colors. Null uses frame extrema. */
|
|
1855
1877
|
colorDomain: [number, number] | null;
|
|
1856
1878
|
/** Transparent ends of the color range, as in RasterStyle. */
|