angular-three-postprocessing 4.0.0-next.115 → 4.0.0-next.118
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/README.md +4 -0
- package/fesm2022/angular-three-postprocessing-n8ao.mjs +40 -5
- package/fesm2022/angular-three-postprocessing-n8ao.mjs.map +1 -1
- package/fesm2022/angular-three-postprocessing.mjs +1066 -141
- package/fesm2022/angular-three-postprocessing.mjs.map +1 -1
- package/package.json +5 -5
- package/types/angular-three-postprocessing-n8ao.d.ts +167 -0
- package/types/angular-three-postprocessing.d.ts +1868 -0
- package/index.d.ts +0 -715
- package/n8ao/index.d.ts +0 -39
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "angular-three-postprocessing",
|
|
3
|
-
"version": "4.0.0-next.
|
|
3
|
+
"version": "4.0.0-next.118",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"maath": ">=0.10.0 <0.11.0",
|
|
28
28
|
"n8ao": ">=1.9.4 <2.0.0",
|
|
29
29
|
"postprocessing": "^6.0.0",
|
|
30
|
-
"three": ">=0.157.0 <0.
|
|
30
|
+
"three": ">=0.157.0 <0.183.0",
|
|
31
31
|
"three-stdlib": "^2.0.0"
|
|
32
32
|
},
|
|
33
33
|
"peerDependenciesMeta": {
|
|
@@ -44,17 +44,17 @@
|
|
|
44
44
|
"node_modules/angular-three/web-types.json"
|
|
45
45
|
],
|
|
46
46
|
"module": "fesm2022/angular-three-postprocessing.mjs",
|
|
47
|
-
"typings": "
|
|
47
|
+
"typings": "types/angular-three-postprocessing.d.ts",
|
|
48
48
|
"exports": {
|
|
49
49
|
"./package.json": {
|
|
50
50
|
"default": "./package.json"
|
|
51
51
|
},
|
|
52
52
|
".": {
|
|
53
|
-
"types": "./
|
|
53
|
+
"types": "./types/angular-three-postprocessing.d.ts",
|
|
54
54
|
"default": "./fesm2022/angular-three-postprocessing.mjs"
|
|
55
55
|
},
|
|
56
56
|
"./n8ao": {
|
|
57
|
-
"types": "./n8ao
|
|
57
|
+
"types": "./types/angular-three-postprocessing-n8ao.d.ts",
|
|
58
58
|
"default": "./fesm2022/angular-three-postprocessing-n8ao.mjs"
|
|
59
59
|
}
|
|
60
60
|
}
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
import * as THREE from 'three';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Configuration options for the N8AO (N8 Ambient Occlusion) effect.
|
|
6
|
+
*
|
|
7
|
+
* N8AO is a high-quality, screen-space ambient occlusion implementation
|
|
8
|
+
* that provides realistic shadowing in crevices and corners.
|
|
9
|
+
*/
|
|
10
|
+
interface NgtpN8AOOptions {
|
|
11
|
+
/**
|
|
12
|
+
* Radius of the ambient occlusion effect in world units.
|
|
13
|
+
* @default 5.0
|
|
14
|
+
*/
|
|
15
|
+
aoRadius: number;
|
|
16
|
+
/**
|
|
17
|
+
* Number of tones for AO gradient.
|
|
18
|
+
* @default 0.0
|
|
19
|
+
*/
|
|
20
|
+
aoTones: number;
|
|
21
|
+
/**
|
|
22
|
+
* How quickly the AO effect falls off with distance.
|
|
23
|
+
* @default 1.0
|
|
24
|
+
*/
|
|
25
|
+
distanceFalloff: number;
|
|
26
|
+
/**
|
|
27
|
+
* Intensity/strength of the ambient occlusion effect.
|
|
28
|
+
* @default 5
|
|
29
|
+
*/
|
|
30
|
+
intensity: number;
|
|
31
|
+
/**
|
|
32
|
+
* Bias offset for depth comparison.
|
|
33
|
+
* @default 0.0
|
|
34
|
+
*/
|
|
35
|
+
biasOffset: number;
|
|
36
|
+
/**
|
|
37
|
+
* Bias multiplier for depth comparison.
|
|
38
|
+
* @default 0.0
|
|
39
|
+
*/
|
|
40
|
+
biasMultiplier: number;
|
|
41
|
+
/**
|
|
42
|
+
* Number of samples for ambient occlusion calculation.
|
|
43
|
+
* Higher values = better quality but slower.
|
|
44
|
+
* @default 16
|
|
45
|
+
*/
|
|
46
|
+
aoSamples: number;
|
|
47
|
+
/**
|
|
48
|
+
* Number of samples for denoising.
|
|
49
|
+
* @default 8
|
|
50
|
+
*/
|
|
51
|
+
denoiseSamples: number;
|
|
52
|
+
/**
|
|
53
|
+
* Radius of the denoising filter.
|
|
54
|
+
* @default 12
|
|
55
|
+
*/
|
|
56
|
+
denoiseRadius: number;
|
|
57
|
+
/**
|
|
58
|
+
* Color of the ambient occlusion shadows.
|
|
59
|
+
* @default 'black'
|
|
60
|
+
*/
|
|
61
|
+
color: THREE.ColorRepresentation;
|
|
62
|
+
/**
|
|
63
|
+
* Whether to render at half resolution for better performance.
|
|
64
|
+
* @default false
|
|
65
|
+
*/
|
|
66
|
+
halfRes: boolean;
|
|
67
|
+
/**
|
|
68
|
+
* Whether to use depth-aware upsampling when using half resolution.
|
|
69
|
+
* @default true
|
|
70
|
+
*/
|
|
71
|
+
depthAwareUpsampling: boolean;
|
|
72
|
+
/**
|
|
73
|
+
* Whether to use screen-space radius instead of world-space.
|
|
74
|
+
* @default false
|
|
75
|
+
*/
|
|
76
|
+
screenSpaceRadius: boolean;
|
|
77
|
+
/**
|
|
78
|
+
* Render mode for debugging and visualization.
|
|
79
|
+
* 0: Combined, 1: AO only, 2: Normals, 3: Depth, 4: Denoise
|
|
80
|
+
* @default 0
|
|
81
|
+
*/
|
|
82
|
+
renderMode: 0 | 1 | 2 | 3 | 4;
|
|
83
|
+
/**
|
|
84
|
+
* Number of iterations for the denoising filter.
|
|
85
|
+
* @default 2.0
|
|
86
|
+
*/
|
|
87
|
+
denoiseIterations: number;
|
|
88
|
+
/**
|
|
89
|
+
* Whether to handle transparent objects correctly.
|
|
90
|
+
* @default false
|
|
91
|
+
*/
|
|
92
|
+
transparencyAware: boolean;
|
|
93
|
+
/**
|
|
94
|
+
* Whether to apply gamma correction.
|
|
95
|
+
* @default true
|
|
96
|
+
*/
|
|
97
|
+
gammaCorrection: boolean;
|
|
98
|
+
/**
|
|
99
|
+
* Whether to use logarithmic depth buffer.
|
|
100
|
+
* @default false
|
|
101
|
+
*/
|
|
102
|
+
logarithmicDepthBuffer: boolean;
|
|
103
|
+
/**
|
|
104
|
+
* Whether to multiply the color instead of darkening.
|
|
105
|
+
* @default true
|
|
106
|
+
*/
|
|
107
|
+
colorMultiply: boolean;
|
|
108
|
+
/**
|
|
109
|
+
* Whether to accumulate samples over frames for better quality.
|
|
110
|
+
* @default false
|
|
111
|
+
*/
|
|
112
|
+
accumulate: boolean;
|
|
113
|
+
/**
|
|
114
|
+
* Quality preset that overrides individual settings.
|
|
115
|
+
* Options: 'performance', 'low', 'medium', 'high', 'ultra'
|
|
116
|
+
* @default undefined
|
|
117
|
+
*/
|
|
118
|
+
quality?: 'performance' | 'low' | 'medium' | 'high' | 'ultra';
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Angular component that applies N8AO (N8 Ambient Occlusion) to the scene.
|
|
122
|
+
*
|
|
123
|
+
* N8AO is a high-quality screen-space ambient occlusion effect that adds
|
|
124
|
+
* realistic shadowing to crevices, corners, and areas where objects meet.
|
|
125
|
+
* It provides various quality presets and fine-grained control over the
|
|
126
|
+
* AO appearance.
|
|
127
|
+
*
|
|
128
|
+
* @example
|
|
129
|
+
* ```html
|
|
130
|
+
* <ngtp-effect-composer>
|
|
131
|
+
* <ngtp-n8ao [options]="{ intensity: 3, aoRadius: 2 }" />
|
|
132
|
+
* </ngtp-effect-composer>
|
|
133
|
+
* ```
|
|
134
|
+
*
|
|
135
|
+
* @example
|
|
136
|
+
* ```html
|
|
137
|
+
* <!-- Using quality preset -->
|
|
138
|
+
* <ngtp-effect-composer>
|
|
139
|
+
* <ngtp-n8ao [options]="{ quality: 'high' }" />
|
|
140
|
+
* </ngtp-effect-composer>
|
|
141
|
+
* ```
|
|
142
|
+
*/
|
|
143
|
+
declare class NgtpN8AO {
|
|
144
|
+
/**
|
|
145
|
+
* Configuration options for the N8AO effect.
|
|
146
|
+
* @see NgtpN8AOOptions
|
|
147
|
+
*/
|
|
148
|
+
options: _angular_core.InputSignalWithTransform<NgtpN8AOOptions, "" | Partial<NgtpN8AOOptions>>;
|
|
149
|
+
private quality;
|
|
150
|
+
private effectComposer;
|
|
151
|
+
/**
|
|
152
|
+
* The underlying N8AOPostPass instance.
|
|
153
|
+
* Created with the scene and camera from the effect composer.
|
|
154
|
+
*/
|
|
155
|
+
protected effect: _angular_core.Signal<any>;
|
|
156
|
+
constructor();
|
|
157
|
+
/**
|
|
158
|
+
* Applies a quality preset to the effect.
|
|
159
|
+
* Converts the quality string to title case and calls the effect's setQuality method.
|
|
160
|
+
*/
|
|
161
|
+
private setQualityEffect;
|
|
162
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<NgtpN8AO, never>;
|
|
163
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<NgtpN8AO, "ngtp-n8ao", never, { "options": { "alias": "options"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
export { NgtpN8AO };
|
|
167
|
+
export type { NgtpN8AOOptions };
|