@woosh/meep-engine 2.116.1 → 2.117.1
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/build/meep.cjs +30 -32
- package/build/meep.min.js +1 -1
- package/build/meep.module.js +30 -32
- package/package.json +1 -1
- package/src/core/model/object/object_deep_clone.d.ts +7 -0
- package/src/core/model/object/object_deep_clone.d.ts.map +1 -0
- package/src/core/model/object/object_deep_clone.js +47 -0
- package/src/engine/development/performance/MetricCollection.d.ts +1 -1
- package/src/engine/development/performance/MetricCollection.js +2 -2
- package/src/engine/development/performance/monitor/MetricCollectionConsoleMonitor.d.ts +10 -0
- package/src/engine/development/performance/monitor/MetricCollectionConsoleMonitor.d.ts.map +1 -0
- package/src/engine/development/performance/monitor/MetricCollectionConsoleMonitor.js +23 -0
- package/src/engine/graphics/render/forward_plus/model/AbstractLight.d.ts.map +1 -1
- package/src/engine/graphics/render/forward_plus/model/AbstractLight.js +3 -3
- package/src/engine/graphics/render/forward_plus/model/DirectionalLight.d.ts +6 -6
- package/src/engine/graphics/render/forward_plus/model/DirectionalLight.d.ts.map +1 -1
- package/src/engine/graphics/render/forward_plus/model/DirectionalLight.js +26 -27
- package/src/engine/graphics/render/forward_plus/model/PointLight.d.ts +4 -4
- package/src/engine/graphics/render/forward_plus/model/PointLight.d.ts.map +1 -1
- package/src/engine/graphics/render/forward_plus/model/PointLight.js +31 -33
- package/src/engine/graphics/render/forward_plus/model/SpotLight.d.ts +14 -14
- package/src/engine/graphics/render/forward_plus/model/SpotLight.d.ts.map +1 -1
- package/src/engine/graphics/render/forward_plus/model/SpotLight.js +46 -47
- package/src/engine/graphics/render/visibility/hiz/query/QueryShader.d.ts.map +1 -1
- package/src/engine/graphics/render/visibility/hiz/query/QueryShader.js +0 -4
- package/src/engine/graphics/sh3/lpv/PathTracerProbeRenderer.d.ts.map +1 -1
- package/src/engine/graphics/sh3/lpv/PathTracerProbeRenderer.js +3 -4
- package/src/engine/physics/fluid/prototype.js +7 -12
- package/src/view/elements/progress/SmoothProgressBar.d.ts +7 -14
- package/src/view/elements/progress/SmoothProgressBar.d.ts.map +1 -1
- package/src/view/elements/progress/SmoothProgressBar.js +23 -6
package/build/meep.module.js
CHANGED
|
@@ -87665,7 +87665,7 @@ class MetricCollection {
|
|
|
87665
87665
|
/**
|
|
87666
87666
|
*
|
|
87667
87667
|
* @param {string} name
|
|
87668
|
-
* @param {number} buffer_size
|
|
87668
|
+
* @param {number} [buffer_size]
|
|
87669
87669
|
* @returns {AbstractMetric}
|
|
87670
87670
|
*/
|
|
87671
87671
|
create({ name, buffer_size = 1000 }) {
|
|
@@ -110512,9 +110512,9 @@ class LightRenderMetadata {
|
|
|
110512
110512
|
let id_counter = 0;
|
|
110513
110513
|
|
|
110514
110514
|
class AbstractLight {
|
|
110515
|
-
|
|
110516
|
-
|
|
110517
|
-
|
|
110515
|
+
|
|
110516
|
+
id = id_counter++;
|
|
110517
|
+
|
|
110518
110518
|
|
|
110519
110519
|
toString() {
|
|
110520
110520
|
return `Light#${this.id}`;
|
|
@@ -112707,33 +112707,31 @@ class SystemEntityContext {
|
|
|
112707
112707
|
}
|
|
112708
112708
|
|
|
112709
112709
|
class PointLight extends AbstractLight {
|
|
112710
|
-
constructor() {
|
|
112711
|
-
super();
|
|
112712
112710
|
|
|
112713
|
-
|
|
112714
|
-
|
|
112715
|
-
|
|
112716
|
-
|
|
112717
|
-
|
|
112711
|
+
/**
|
|
112712
|
+
* @readonly
|
|
112713
|
+
* @type {Vector3}
|
|
112714
|
+
*/
|
|
112715
|
+
position = new Vector3$1();
|
|
112718
112716
|
|
|
112719
|
-
|
|
112720
|
-
|
|
112721
|
-
|
|
112722
|
-
|
|
112723
|
-
|
|
112717
|
+
/**
|
|
112718
|
+
* @readonly
|
|
112719
|
+
* @type {Vector1}
|
|
112720
|
+
*/
|
|
112721
|
+
radius = new Vector1(1);
|
|
112724
112722
|
|
|
112725
|
-
|
|
112726
|
-
|
|
112727
|
-
|
|
112728
|
-
|
|
112729
|
-
|
|
112723
|
+
/**
|
|
112724
|
+
* @readonly
|
|
112725
|
+
* @type {Color}
|
|
112726
|
+
*/
|
|
112727
|
+
color = new Color(1, 1, 1);
|
|
112728
|
+
|
|
112729
|
+
/**
|
|
112730
|
+
* @readonly
|
|
112731
|
+
* @type {Vector1}
|
|
112732
|
+
*/
|
|
112733
|
+
intensity = new Vector1(1);
|
|
112730
112734
|
|
|
112731
|
-
/**
|
|
112732
|
-
*
|
|
112733
|
-
* @type {Vector1}
|
|
112734
|
-
*/
|
|
112735
|
-
this.intensity = new Vector1(1);
|
|
112736
|
-
}
|
|
112737
112735
|
|
|
112738
112736
|
getCenter(result) {
|
|
112739
112737
|
this.position.writeToArray(result, 0);
|
|
@@ -112748,12 +112746,12 @@ class PointLight extends AbstractLight {
|
|
|
112748
112746
|
const center_z = p.z;
|
|
112749
112747
|
|
|
112750
112748
|
result[0] = center_x - r;
|
|
112751
|
-
|
|
112752
|
-
|
|
112749
|
+
result[1] = center_y - r;
|
|
112750
|
+
result[2] = center_z - r;
|
|
112753
112751
|
|
|
112754
|
-
|
|
112755
|
-
|
|
112756
|
-
|
|
112752
|
+
result[3] = center_x + r;
|
|
112753
|
+
result[4] = center_y + r;
|
|
112754
|
+
result[5] = center_z + r;
|
|
112757
112755
|
}
|
|
112758
112756
|
|
|
112759
112757
|
onDimensionChanged(listener, context) {
|
package/package.json
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"object_deep_clone.d.ts","sourceRoot":"","sources":["../../../../../src/core/model/object/object_deep_clone.js"],"names":[],"mappings":"AAmBA;;;;GAIG;AACH,mDAqBC"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* @param {Object} source
|
|
4
|
+
* @returns {Object}
|
|
5
|
+
*/
|
|
6
|
+
function structural_clone(source) {
|
|
7
|
+
const result = Object.create(Object.getPrototypeOf(source));
|
|
8
|
+
|
|
9
|
+
const ownKeys = Reflect.ownKeys(source);
|
|
10
|
+
|
|
11
|
+
for (let i = 0; i < ownKeys.length; i++) {
|
|
12
|
+
const ownKey = ownKeys[i];
|
|
13
|
+
|
|
14
|
+
result[ownKey] = object_deep_clone(source[ownKey]);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
return result;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Will invoke any "clone" methods and inherit prototypes where possible
|
|
22
|
+
* @template T
|
|
23
|
+
* @param {T} source
|
|
24
|
+
* @returns {T}
|
|
25
|
+
*/
|
|
26
|
+
export function object_deep_clone(source) {
|
|
27
|
+
|
|
28
|
+
const source_type = typeof source;
|
|
29
|
+
if (source_type === "object") {
|
|
30
|
+
if (source !== null) {
|
|
31
|
+
if (typeof source.clone === "function") {
|
|
32
|
+
// has clone method
|
|
33
|
+
return source.clone();
|
|
34
|
+
} else {
|
|
35
|
+
// do structural cloning
|
|
36
|
+
return structural_clone(source);
|
|
37
|
+
}
|
|
38
|
+
} else {
|
|
39
|
+
// value is null
|
|
40
|
+
return source;
|
|
41
|
+
}
|
|
42
|
+
} else {
|
|
43
|
+
// not an object, assume primitive type and just return that
|
|
44
|
+
return source;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { RingBufferMetric } from "./RingBufferMetric.js";
|
|
2
1
|
import { assert } from "../../../core/assert.js";
|
|
2
|
+
import { RingBufferMetric } from "./RingBufferMetric.js";
|
|
3
3
|
|
|
4
4
|
export class MetricCollection {
|
|
5
5
|
constructor() {
|
|
@@ -27,7 +27,7 @@ export class MetricCollection {
|
|
|
27
27
|
/**
|
|
28
28
|
*
|
|
29
29
|
* @param {string} name
|
|
30
|
-
* @param {number} buffer_size
|
|
30
|
+
* @param {number} [buffer_size]
|
|
31
31
|
* @returns {AbstractMetric}
|
|
32
32
|
*/
|
|
33
33
|
create({ name, buffer_size = 1000 }) {
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export class MetricCollectionConsoleMonitor {
|
|
2
|
+
/**
|
|
3
|
+
*
|
|
4
|
+
* @param {MetricCollection} metrics
|
|
5
|
+
* @returns {PeriodicConsolePrinter}
|
|
6
|
+
*/
|
|
7
|
+
static from(metrics: MetricCollection): PeriodicConsolePrinter;
|
|
8
|
+
}
|
|
9
|
+
import { PeriodicConsolePrinter } from "./PeriodicConsolePrinter.js";
|
|
10
|
+
//# sourceMappingURL=MetricCollectionConsoleMonitor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MetricCollectionConsoleMonitor.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/development/performance/monitor/MetricCollectionConsoleMonitor.js"],"names":[],"mappings":"AAGA;IAEI;;;;OAIG;IACH,wCAFa,sBAAsB,CAYlC;CAEJ;uCArBsC,6BAA6B"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { MetricStatistics } from "../MetricStatistics.js";
|
|
2
|
+
import { PeriodicConsolePrinter } from "./PeriodicConsolePrinter.js";
|
|
3
|
+
|
|
4
|
+
export class MetricCollectionConsoleMonitor{
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
*
|
|
8
|
+
* @param {MetricCollection} metrics
|
|
9
|
+
* @returns {PeriodicConsolePrinter}
|
|
10
|
+
*/
|
|
11
|
+
static from(metrics){
|
|
12
|
+
|
|
13
|
+
const metric_stats = new MetricStatistics();
|
|
14
|
+
|
|
15
|
+
return new PeriodicConsolePrinter(3, () => metrics.list().map(m => {
|
|
16
|
+
metrics.get(m).computeStats(metric_stats);
|
|
17
|
+
|
|
18
|
+
return `${m}: ${metric_stats}`;
|
|
19
|
+
}).join('\n'));
|
|
20
|
+
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AbstractLight.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/render/forward_plus/model/AbstractLight.js"],"names":[],"mappings":"AAEA;
|
|
1
|
+
{"version":3,"file":"AbstractLight.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/render/forward_plus/model/AbstractLight.js"],"names":[],"mappings":"AAEA;IAEI,WAAkB;IAGlB,mBAEC;IAED;;;;;OAKG;IACH,gDAFa,IAAI,CAIhB;IAED;;;;;OAKG;IACH,iDAFa,IAAI,CAIhB;IAED;;;;OAIG;IACH,kBAHW,MAAM,EAAE,GACN,IAAI,CAIhB;IAED;;;;OAIG;IACH,gBAHW,MAAM,EAAE,GAAC,UAAU,MAAM,CAAC,GAAC,YAAY,GACrC,IAAI,CAIhB;IAED;;;;;OAKG;IACH,qBAJW,MAAM,EAAE,GAAC,YAAY,GAAC,YAAY,WAClC,MAAM,GACJ,MAAM,CAIlB;IAED;;;;OAIG;IACH,eAHW,aAAa,GACX,MAAM,CAIlB;IAGL,aAA4B;CAF3B"}
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
export class DirectionalLight extends AbstractLight {
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
3
|
+
* @readonly
|
|
4
4
|
* @type {Vector3}
|
|
5
5
|
*/
|
|
6
|
-
position: Vector3;
|
|
6
|
+
readonly position: Vector3;
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
8
|
+
* @readonly
|
|
9
9
|
* @type {Vector3}
|
|
10
10
|
*/
|
|
11
|
-
direction: Vector3;
|
|
11
|
+
readonly direction: Vector3;
|
|
12
12
|
/**
|
|
13
13
|
* @readonly
|
|
14
14
|
* @type {Color}
|
|
15
15
|
*/
|
|
16
16
|
readonly color: Color;
|
|
17
17
|
/**
|
|
18
|
-
*
|
|
18
|
+
* @readonly
|
|
19
19
|
* @type {Vector1}
|
|
20
20
|
*/
|
|
21
|
-
intensity: Vector1;
|
|
21
|
+
readonly intensity: Vector1;
|
|
22
22
|
/**
|
|
23
23
|
* @readonly
|
|
24
24
|
* @type {boolean}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DirectionalLight.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/render/forward_plus/model/DirectionalLight.js"],"names":[],"mappings":"AAKA;
|
|
1
|
+
{"version":3,"file":"DirectionalLight.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/render/forward_plus/model/DirectionalLight.js"],"names":[],"mappings":"AAKA;IAGI;;;OAGG;IACH,mBAFU,OAAO,CAEQ;IAEzB;;;OAGG;IACH,oBAFU,OAAO,CAES;IAE1B;;;OAGG;IACH,gBAFU,KAAK,CAEY;IAE3B;;;OAGG;IACH,oBAFU,OAAO,CAEU;IAI/B;;;OAGG;IACH,6BAFU,OAAO,CAE4B;CAN5C;8BA7B6B,oBAAoB;oBAD9B,qCAAqC;sBAFnC,oCAAoC;oBACtC,qCAAqC"}
|
|
@@ -4,33 +4,32 @@ import Vector3 from "../../../../../core/geom/Vector3.js";
|
|
|
4
4
|
import { AbstractLight } from "./AbstractLight.js";
|
|
5
5
|
|
|
6
6
|
export class DirectionalLight extends AbstractLight {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
}
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* @readonly
|
|
11
|
+
* @type {Vector3}
|
|
12
|
+
*/
|
|
13
|
+
position = new Vector3();
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* @readonly
|
|
17
|
+
* @type {Vector3}
|
|
18
|
+
*/
|
|
19
|
+
direction = new Vector3();
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* @readonly
|
|
23
|
+
* @type {Color}
|
|
24
|
+
*/
|
|
25
|
+
color = new Color(1, 1, 1);
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* @readonly
|
|
29
|
+
* @type {Vector1}
|
|
30
|
+
*/
|
|
31
|
+
intensity = new Vector1(1);
|
|
32
|
+
|
|
34
33
|
}
|
|
35
34
|
|
|
36
35
|
/**
|
|
@@ -5,20 +5,20 @@ export class PointLight extends AbstractLight {
|
|
|
5
5
|
*/
|
|
6
6
|
readonly position: Vector3;
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
8
|
+
* @readonly
|
|
9
9
|
* @type {Vector1}
|
|
10
10
|
*/
|
|
11
|
-
radius: Vector1;
|
|
11
|
+
readonly radius: Vector1;
|
|
12
12
|
/**
|
|
13
13
|
* @readonly
|
|
14
14
|
* @type {Color}
|
|
15
15
|
*/
|
|
16
16
|
readonly color: Color;
|
|
17
17
|
/**
|
|
18
|
-
*
|
|
18
|
+
* @readonly
|
|
19
19
|
* @type {Vector1}
|
|
20
20
|
*/
|
|
21
|
-
intensity: Vector1;
|
|
21
|
+
readonly intensity: Vector1;
|
|
22
22
|
getCenter(result: any): void;
|
|
23
23
|
getAABB(result: any): void;
|
|
24
24
|
onDimensionChanged(listener: any, context: any): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PointLight.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/render/forward_plus/model/PointLight.js"],"names":[],"mappings":"AAKA;
|
|
1
|
+
{"version":3,"file":"PointLight.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/render/forward_plus/model/PointLight.js"],"names":[],"mappings":"AAKA;IAEI;;;OAGG;IACH,mBAFU,OAAO,CAEQ;IAEzB;;;OAGG;IACH,iBAFU,OAAO,CAEO;IAExB;;;OAGG;IACH,gBAFU,KAAK,CAEY;IAE3B;;;OAGG;IACH,oBAFU,OAAO,CAEU;IAG3B,6BAEC;IAED,2BAeC;IAED,sDAGC;IAED,uDAGC;IA6BL;;;OAGG;IACH,uBAFU,OAAO,CAEgB;IAEjC,2BAAuC;CARtC;8BArF6B,oBAAoB;oBAD9B,qCAAqC;oBADrC,qCAAqC;sBADnC,oCAAoC"}
|
|
@@ -1,36 +1,34 @@
|
|
|
1
|
-
import Vector3 from "../../../../../core/geom/Vector3.js";
|
|
2
1
|
import { Color } from "../../../../../core/color/Color.js";
|
|
3
2
|
import Vector1 from "../../../../../core/geom/Vector1.js";
|
|
3
|
+
import Vector3 from "../../../../../core/geom/Vector3.js";
|
|
4
4
|
import { AbstractLight } from "./AbstractLight.js";
|
|
5
5
|
|
|
6
6
|
export class PointLight extends AbstractLight {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
this.intensity = new Vector1(1);
|
|
33
|
-
}
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* @readonly
|
|
10
|
+
* @type {Vector3}
|
|
11
|
+
*/
|
|
12
|
+
position = new Vector3();
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* @readonly
|
|
16
|
+
* @type {Vector1}
|
|
17
|
+
*/
|
|
18
|
+
radius = new Vector1(1);
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* @readonly
|
|
22
|
+
* @type {Color}
|
|
23
|
+
*/
|
|
24
|
+
color = new Color(1, 1, 1);
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* @readonly
|
|
28
|
+
* @type {Vector1}
|
|
29
|
+
*/
|
|
30
|
+
intensity = new Vector1(1);
|
|
31
|
+
|
|
34
32
|
|
|
35
33
|
getCenter(result) {
|
|
36
34
|
this.position.writeToArray(result, 0);
|
|
@@ -45,12 +43,12 @@ export class PointLight extends AbstractLight {
|
|
|
45
43
|
const center_z = p.z;
|
|
46
44
|
|
|
47
45
|
result[0] = center_x - r;
|
|
48
|
-
|
|
49
|
-
|
|
46
|
+
result[1] = center_y - r;
|
|
47
|
+
result[2] = center_z - r;
|
|
50
48
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
49
|
+
result[3] = center_x + r;
|
|
50
|
+
result[4] = center_y + r;
|
|
51
|
+
result[5] = center_z + r;
|
|
54
52
|
}
|
|
55
53
|
|
|
56
54
|
onDimensionChanged(listener, context) {
|
|
@@ -1,39 +1,39 @@
|
|
|
1
1
|
export class SpotLight extends AbstractLight {
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
3
|
+
* @readonly
|
|
4
4
|
* @type {Vector3}
|
|
5
5
|
*/
|
|
6
|
-
position: Vector3;
|
|
6
|
+
readonly position: Vector3;
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
8
|
+
* @readonly
|
|
9
9
|
* @type {Vector3}
|
|
10
10
|
*/
|
|
11
|
-
direction: Vector3;
|
|
11
|
+
readonly direction: Vector3;
|
|
12
12
|
/**
|
|
13
|
-
*
|
|
13
|
+
* @readonly
|
|
14
14
|
* @type {Vector1}
|
|
15
15
|
*/
|
|
16
|
-
angle: Vector1;
|
|
16
|
+
readonly angle: Vector1;
|
|
17
17
|
/**
|
|
18
|
-
*
|
|
18
|
+
* @readonly
|
|
19
19
|
* @type {Vector1}
|
|
20
20
|
*/
|
|
21
|
-
distance: Vector1;
|
|
21
|
+
readonly distance: Vector1;
|
|
22
22
|
/**
|
|
23
|
-
*
|
|
23
|
+
* @readonly
|
|
24
24
|
* @type {Color}
|
|
25
25
|
*/
|
|
26
|
-
color: Color;
|
|
26
|
+
readonly color: Color;
|
|
27
27
|
/**
|
|
28
|
-
*
|
|
28
|
+
* @readonly
|
|
29
29
|
* @type {Vector1}
|
|
30
30
|
*/
|
|
31
|
-
intensity: Vector1;
|
|
31
|
+
readonly intensity: Vector1;
|
|
32
32
|
/**
|
|
33
|
-
*
|
|
33
|
+
* @readonly
|
|
34
34
|
* @type {Vector1}
|
|
35
35
|
*/
|
|
36
|
-
penumbra: Vector1;
|
|
36
|
+
readonly penumbra: Vector1;
|
|
37
37
|
getCenter(result: any): void;
|
|
38
38
|
getAABB(result: any): void;
|
|
39
39
|
onDimensionChanged(listener: any, context: any): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SpotLight.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/render/forward_plus/model/SpotLight.js"],"names":[],"mappings":"AAMA;
|
|
1
|
+
{"version":3,"file":"SpotLight.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/render/forward_plus/model/SpotLight.js"],"names":[],"mappings":"AAMA;IAGI;;;OAGG;IACH,mBAFU,OAAO,CAEQ;IAEzB;;;OAGG;IACH,oBAFU,OAAO,CAES;IAE1B;;;OAGG;IACH,gBAFU,OAAO,CAEgB;IAEjC;;;OAGG;IACH,mBAFU,OAAO,CAES;IAE1B;;;OAGG;IACH,gBAFU,KAAK,CAEY;IAE3B;;;OAGG;IACH,oBAFU,OAAO,CAEU;IAE3B;;;OAGG;IACH,mBAFU,OAAO,CAEW;IAG5B,6BAYC;IAED,2BAcC;IAED,sDAKC;IAED,uDAKC;IAuCL;;;OAGG;IACH,sBAFU,OAAO,CAEc;CAN9B;8BA/H6B,oBAAoB;oBAD9B,qCAAqC;oBADrC,qCAAqC;sBAFnC,oCAAoC"}
|
|
@@ -1,55 +1,54 @@
|
|
|
1
|
-
import Vector3 from "../../../../../core/geom/Vector3.js";
|
|
2
|
-
import Vector1 from "../../../../../core/geom/Vector1.js";
|
|
3
1
|
import { Color } from "../../../../../core/color/Color.js";
|
|
4
2
|
import { computeConeBoundingBox } from "../../../../../core/geom/3d/cone/computeConeBoundingBox.js";
|
|
3
|
+
import Vector1 from "../../../../../core/geom/Vector1.js";
|
|
4
|
+
import Vector3 from "../../../../../core/geom/Vector3.js";
|
|
5
5
|
import { AbstractLight } from "./AbstractLight.js";
|
|
6
6
|
|
|
7
7
|
export class SpotLight extends AbstractLight {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
}
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* @readonly
|
|
12
|
+
* @type {Vector3}
|
|
13
|
+
*/
|
|
14
|
+
position = new Vector3();
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* @readonly
|
|
18
|
+
* @type {Vector3}
|
|
19
|
+
*/
|
|
20
|
+
direction = new Vector3();
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* @readonly
|
|
24
|
+
* @type {Vector1}
|
|
25
|
+
*/
|
|
26
|
+
angle = new Vector1(Math.PI / 2);
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* @readonly
|
|
30
|
+
* @type {Vector1}
|
|
31
|
+
*/
|
|
32
|
+
distance = new Vector1(1);
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* @readonly
|
|
36
|
+
* @type {Color}
|
|
37
|
+
*/
|
|
38
|
+
color = new Color(1, 1, 1);
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* @readonly
|
|
42
|
+
* @type {Vector1}
|
|
43
|
+
*/
|
|
44
|
+
intensity = new Vector1(1);
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* @readonly
|
|
48
|
+
* @type {Vector1}
|
|
49
|
+
*/
|
|
50
|
+
penumbra = new Vector1(0.4);
|
|
51
|
+
|
|
53
52
|
|
|
54
53
|
getCenter(result) {
|
|
55
54
|
// find center of the cone (mid point along the cone length)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QueryShader.d.ts","sourceRoot":"","sources":["../../../../../../../../src/engine/graphics/render/visibility/hiz/query/QueryShader.js"],"names":[],"mappings":"AAEA,
|
|
1
|
+
{"version":3,"file":"QueryShader.d.ts","sourceRoot":"","sources":["../../../../../../../../src/engine/graphics/render/visibility/hiz/query/QueryShader.js"],"names":[],"mappings":"AAEA,kDAsKC;+BAxK8C,OAAO"}
|
|
@@ -15,10 +15,6 @@ export function makeQueryShader() {
|
|
|
15
15
|
|
|
16
16
|
out highp vec4 out_value;
|
|
17
17
|
|
|
18
|
-
float reduce(float a, float b, float c, float d){
|
|
19
|
-
return max( a, max( b, max( c, d ) ) );
|
|
20
|
-
}
|
|
21
|
-
|
|
22
18
|
vec3 read_input_v3(ivec2 start){
|
|
23
19
|
float x = texelFetch(utInput, start, 0).x;
|
|
24
20
|
float y = texelFetch(utInput, start + ivec2(1,0), 0).x;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PathTracerProbeRenderer.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/graphics/sh3/lpv/PathTracerProbeRenderer.js"],"names":[],"mappings":"AAuBA;IACI,mBAA0B;IAC1B,yBAAqB;
|
|
1
|
+
{"version":3,"file":"PathTracerProbeRenderer.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/graphics/sh3/lpv/PathTracerProbeRenderer.js"],"names":[],"mappings":"AAuBA;IACI,mBAA0B;IAC1B,yBAAqB;IACrB,qBAAmB;IAEnB,qBAAyB;IAEzB,uBAA6B;IAE7B;;;;;;;;OAQG;IACH,kCAPW,MAAM,aACN,MAAM,YACN,MAAM,EAAE,mBACR,MAAM,UACN,MAAM,EAAE,iBACR,MAAM,QAchB;IAED,iFAuCC;IAKD,mBACC;IAED,4BAKC;CACJ;8BA9F6B,oBAAoB;2BAHvB,8BAA8B;gCADzB,mCAAmC"}
|