Skip to content

Commit ea9bff5

Browse files
committed
fix: update n8ao
1 parent e4a0482 commit ea9bff5

File tree

3 files changed

+13
-5
lines changed

3 files changed

+13
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
},
4848
"dependencies": {
4949
"maath": "^0.5.3",
50-
"n8ao": "^1.4.2",
50+
"n8ao": "^1.5.1",
5151
"postprocessing": "^6.31.0",
5252
"screen-space-reflections": "^2.5.0",
5353
"three-stdlib": "^2.23.4"

src/effects/N8AO.tsx

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,19 @@ type N8AOProps = {
1515
denoiseSamples?: number
1616
denoiseRadius?: number
1717
color?: ReactThreeFiber.Color
18+
halfRes?: boolean
19+
depthAwareUpsampling?: boolean
1820
screenSpaceRadius?: boolean
1921
renderMode?: 0 | 1 | 2 | 3 | 4
2022
}
2123

2224
export const N8AO = forwardRef<N8AOPostPass, N8AOProps>(
2325
(
2426
{
27+
halfRes,
2528
screenSpaceRadius,
2629
quality,
30+
depthAwareUpsampling = true,
2731
aoRadius = 5,
2832
aoSamples = 16,
2933
denoiseSamples = 4,
@@ -48,6 +52,8 @@ export const N8AO = forwardRef<N8AOPostPass, N8AOProps>(
4852
denoiseRadius,
4953
screenSpaceRadius,
5054
renderMode,
55+
halfRes,
56+
depthAwareUpsampling,
5157
})
5258
}, [
5359
screenSpaceRadius,
@@ -59,6 +65,8 @@ export const N8AO = forwardRef<N8AOPostPass, N8AOProps>(
5965
denoiseSamples,
6066
denoiseRadius,
6167
renderMode,
68+
halfRes,
69+
depthAwareUpsampling,
6270
])
6371
useLayoutEffect(() => {
6472
if (quality) effect.setQualityMode(quality.charAt(0).toUpperCase() + quality.slice(1))

yarn.lock

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7547,10 +7547,10 @@ mute-stream@~1.0.0:
75477547
resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-1.0.0.tgz#e31bd9fe62f0aed23520aa4324ea6671531e013e"
75487548
integrity sha512-avsJQhyd+680gKXyG/sQc0nXaC6rBkPOfyHYcFb9+hdkqQkR9bdnkJ0AMZhke0oesPqIO+mFFJ+IdBc7mst4IA==
75497549

7550-
n8ao@^1.4.2:
7551-
version "1.4.2"
7552-
resolved "https://registry.yarnpkg.com/n8ao/-/n8ao-1.4.2.tgz#46ad1e0a286aa64e62216e7a9cb1001470eec74a"
7553-
integrity sha512-B5bwykVEjuqjPbwzoIHlzuDcDKBznqZ4Q3mky+Q7g69J7BxXGzQWKjNjEpaQhxybEgtAzByVJm59EANzNktfMw==
7550+
n8ao@^1.5.1:
7551+
version "1.5.1"
7552+
resolved "https://registry.yarnpkg.com/n8ao/-/n8ao-1.5.1.tgz#e48960352e9c358955d7da072a341bbc64961bb5"
7553+
integrity sha512-Dn5o6ecmLC1xZm2mby2qdGYgwKcNsC9oKv85TQBKFbDJVzUHGXV2oys14rDl6nhwjH+zZU3YcLJkMcY7qe+jTg==
75547554

75557555
nanoid@^3.3.1, nanoid@^3.3.6:
75567556
version "3.3.6"

0 commit comments

Comments
 (0)