illutions 0.21.9 → 0.22.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/CHANGELOG.md +14 -0
- package/dist/main.d.ts +40 -16
- package/dist/main.min.cjs +1 -1
- package/dist/main.min.js +1 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.22.0
|
|
4
|
+
|
|
5
|
+
### Changed
|
|
6
|
+
|
|
7
|
+
- Updated the framework to Three.js r185.
|
|
8
|
+
- Changed the default renderer selection to `render.api = 'auto'`.
|
|
9
|
+
- Added `envCtrls.dataType` to configure environment texture data handling.
|
|
10
|
+
- Replaced `SsrWebGpuCfg.opacity` with `SsrWebGpuCfg.intensity`.
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
|
|
14
|
+
- Clarified the WebGL/WebGPU renderer switch behavior.
|
|
15
|
+
- Enabled WebGPU renderer loading even when post-processing is disabled.
|
|
16
|
+
|
|
3
17
|
## 0.21.9
|
|
4
18
|
|
|
5
19
|
### Changed
|
package/dist/main.d.ts
CHANGED
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import { AnyEventObject } from 'xstate';
|
|
2
2
|
import { AnyStateMachine } from 'xstate';
|
|
3
|
+
import { ao } from 'three/addons/tsl/display/GTAONode.js';
|
|
4
|
+
import { createBrowserInspector } from '@statelyai/inspect';
|
|
3
5
|
import { default as default_2 } from 'three/addons/tsl/display/GTAONode.js';
|
|
4
6
|
import { default as default_3 } from 'three/addons/tsl/display/SSRNode.js';
|
|
5
7
|
import { DRACOLoader } from 'three/addons/loaders/DRACOLoader.js';
|
|
6
8
|
import { EffectComposer } from 'three/addons/postprocessing/EffectComposer.js';
|
|
7
9
|
import { EXRLoader } from 'three/addons/loaders/EXRLoader.js';
|
|
10
|
+
import { FXAAShader } from 'three/addons/shaders/FXAAShader.js';
|
|
8
11
|
import { GLTFLoader } from 'three/addons/loaders/GLTFLoader.js';
|
|
9
12
|
import { HDRLoader } from 'three/addons/loaders/HDRLoader.js';
|
|
10
13
|
import { KTX2Loader } from 'three/addons/loaders/KTX2Loader.js';
|
|
@@ -12,16 +15,21 @@ import { MeshoptDecoder } from 'three/addons/libs/meshopt_decoder.module.js';
|
|
|
12
15
|
import { OrbitControls } from 'three/addons/controls/OrbitControls.js';
|
|
13
16
|
import { OrbitControls as OrbitControls_2 } from 'three/examples/jsm/controls/OrbitControls.js';
|
|
14
17
|
import { OutputPass } from 'three/addons/postprocessing/OutputPass.js';
|
|
18
|
+
import { Pane } from 'tweakpane';
|
|
15
19
|
import { PointerLockControls } from 'three/addons/controls/PointerLockControls.js';
|
|
16
20
|
import { PointerLockControls as PointerLockControls_2 } from 'three/examples/jsm/controls/PointerLockControls.js';
|
|
17
21
|
import { ReflectorForSSRPass } from 'three/addons/objects/ReflectorForSSRPass.js';
|
|
18
22
|
import { RenderPass } from 'three/addons/postprocessing/RenderPass.js';
|
|
19
23
|
import { ShaderPass } from 'three/addons/postprocessing/ShaderPass.js';
|
|
24
|
+
import { smaa } from 'three/addons/tsl/display/SMAANode.js';
|
|
25
|
+
import { SMAAPass } from 'three/addons/postprocessing/SMAAPass.js';
|
|
20
26
|
import { SSAOPass } from 'three/addons/postprocessing/SSAOPass.js';
|
|
27
|
+
import { ssr } from 'three/addons/tsl/display/SSRNode.js';
|
|
21
28
|
import { SSRPass } from 'three/addons/postprocessing/SSRPass.js';
|
|
22
29
|
import type * as THREE_TYPE from 'three';
|
|
23
30
|
import type * as THREE_WEBGPU_TYPE from 'three/webgpu';
|
|
24
31
|
import type * as THREE_WEBTSL_TYPE from 'three/tsl';
|
|
32
|
+
import { TierResult } from 'detect-gpu';
|
|
25
33
|
|
|
26
34
|
/**
|
|
27
35
|
* Defines the shared anti-aliasing settings.
|
|
@@ -500,6 +508,8 @@ export declare interface ClipFadeEvent {
|
|
|
500
508
|
action?: THREE_TYPE.AnimationAction;
|
|
501
509
|
}
|
|
502
510
|
|
|
511
|
+
declare type ColorNode = THREE_WEBGPU_TYPE.Node<'vec4'>;
|
|
512
|
+
|
|
503
513
|
/**
|
|
504
514
|
* Represents a reusable web-component logic unit bound to a custom element that participates in the scene lifecycle.
|
|
505
515
|
* @category Components
|
|
@@ -999,6 +1009,11 @@ export declare interface EnvCtrlsCfg {
|
|
|
999
1009
|
* @default 0
|
|
1000
1010
|
*/
|
|
1001
1011
|
backgroundIntensity: number;
|
|
1012
|
+
/**
|
|
1013
|
+
* Specifies the texture data type used by EXR and HDR loaders.
|
|
1014
|
+
* @default 'halfFloat'
|
|
1015
|
+
*/
|
|
1016
|
+
dataType: 'halfFloat' | 'float';
|
|
1002
1017
|
/**
|
|
1003
1018
|
* Enables or disables environment and background map handling.
|
|
1004
1019
|
* @default false
|
|
@@ -1249,6 +1264,8 @@ export declare interface FxaaCfg {
|
|
|
1249
1264
|
sharpness: number;
|
|
1250
1265
|
}
|
|
1251
1266
|
|
|
1267
|
+
declare type FXAAPostNode = (input: ColorNode) => ColorNode;
|
|
1268
|
+
|
|
1252
1269
|
/**
|
|
1253
1270
|
* Defines the GUI elements for runtime information, controls and inspection.
|
|
1254
1271
|
* @category Cfg
|
|
@@ -1547,17 +1564,17 @@ export declare interface ModelLoadingEvent {
|
|
|
1547
1564
|
}
|
|
1548
1565
|
|
|
1549
1566
|
declare class Modules {
|
|
1550
|
-
gpuTier:
|
|
1551
|
-
fxaaNode:
|
|
1552
|
-
fxaaShader:
|
|
1553
|
-
smaaPassClass:
|
|
1554
|
-
smaaNode:
|
|
1555
|
-
ssaoPassClass:
|
|
1556
|
-
gtaoNodeClass:
|
|
1557
|
-
ssrNode:
|
|
1558
|
-
ssrPassClass:
|
|
1559
|
-
paneClass:
|
|
1560
|
-
createBrowserInspector:
|
|
1567
|
+
gpuTier: TierResult | null;
|
|
1568
|
+
fxaaNode: FXAAPostNode | null;
|
|
1569
|
+
fxaaShader: typeof FXAAShader | null;
|
|
1570
|
+
smaaPassClass: typeof SMAAPass | null;
|
|
1571
|
+
smaaNode: typeof smaa | null;
|
|
1572
|
+
ssaoPassClass: typeof SSAOPass | null;
|
|
1573
|
+
gtaoNodeClass: typeof ao | null;
|
|
1574
|
+
ssrNode: typeof ssr | null;
|
|
1575
|
+
ssrPassClass: typeof SSRPass | null;
|
|
1576
|
+
paneClass: typeof Pane | null;
|
|
1577
|
+
createBrowserInspector: typeof createBrowserInspector | null;
|
|
1561
1578
|
effectComposerClass: typeof EffectComposer | null;
|
|
1562
1579
|
envLoader: EXRLoader | HDRLoader | null;
|
|
1563
1580
|
dracoLoader: DRACOLoader | null;
|
|
@@ -1582,8 +1599,8 @@ declare class Modules {
|
|
|
1582
1599
|
tslVec3: typeof THREE_WEBTSL_TYPE.vec3 | null;
|
|
1583
1600
|
tslVec4: typeof THREE_WEBTSL_TYPE.vec4 | null;
|
|
1584
1601
|
tslFloat: typeof THREE_WEBTSL_TYPE.float | null;
|
|
1585
|
-
|
|
1586
|
-
|
|
1602
|
+
packNormalToRGB: typeof THREE_WEBTSL_TYPE.packNormalToRGB | null;
|
|
1603
|
+
unpackRGBToNormal: typeof THREE_WEBTSL_TYPE.unpackRGBToNormal | null;
|
|
1587
1604
|
private cfg;
|
|
1588
1605
|
constructor(cfg: Cfg);
|
|
1589
1606
|
private consoleLog;
|
|
@@ -2076,7 +2093,7 @@ export declare interface RenderCfg {
|
|
|
2076
2093
|
* - `webgpu`: use `THREE.WebGPURenderer`
|
|
2077
2094
|
* - `auto`: use WebGPU if supported, otherwise fall back to WebGL
|
|
2078
2095
|
*
|
|
2079
|
-
* @default '
|
|
2096
|
+
* @default 'webgl'
|
|
2080
2097
|
*/
|
|
2081
2098
|
api: Renderer;
|
|
2082
2099
|
/**
|
|
@@ -2400,10 +2417,10 @@ export declare interface SsrWebGpuCfg {
|
|
|
2400
2417
|
*/
|
|
2401
2418
|
maxDistance: number;
|
|
2402
2419
|
/**
|
|
2403
|
-
* Reflection
|
|
2420
|
+
* Reflection intensity value.
|
|
2404
2421
|
* @default 0.5
|
|
2405
2422
|
*/
|
|
2406
|
-
|
|
2423
|
+
intensity: number;
|
|
2407
2424
|
/**
|
|
2408
2425
|
* Ray thickness used for SSR intersection tests.
|
|
2409
2426
|
* @default 0.018
|
|
@@ -2475,3 +2492,10 @@ export declare interface WindowResizeEvent {
|
|
|
2475
2492
|
}
|
|
2476
2493
|
|
|
2477
2494
|
export { }
|
|
2495
|
+
|
|
2496
|
+
|
|
2497
|
+
declare module 'three/addons/postprocessing/SSRPass.js' {
|
|
2498
|
+
interface SSRPassParams {
|
|
2499
|
+
bouncing?: boolean;
|
|
2500
|
+
}
|
|
2501
|
+
}
|