Skip to content

Commit 66c2cd1

Browse files
committed
docs: update tone mapping examples and props table
1 parent 90d10d5 commit 66c2cd1

1 file changed

Lines changed: 24 additions & 10 deletions

File tree

docs/effects/tone-mapping.mdx

Lines changed: 24 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,19 @@ nav: 1
55

66
A tone mapping effect.
77

8+
```jsx
9+
import { ToneMapping } from '@react-three/postprocessing'
10+
import { ToneMappingMode } from 'postprocessing'
11+
12+
return (
13+
<ToneMapping
14+
mode={ToneMappingMode.ACES_FILMIC} // tone mapping mode
15+
/>
16+
)
17+
```
18+
19+
OR
20+
821
```jsx
922
import { ToneMapping } from '@react-three/postprocessing'
1023
import { BlendFunction } from 'postprocessing'
@@ -28,13 +41,14 @@ return (
2841

2942
## Props
3043

31-
| Name | Type | Default | Description |
32-
| ---------------- | ------------- | ------- | ------------------------------------------------------------------- |
33-
| resolution | Number | 256 | The resolution of the luminance texture. Must be a power of two. |
34-
| adaptive | boolean | true | Toggle adaptive luminance map usage |
35-
| blendFunction | BlendFunction | | The blend function of this effect. |
36-
| middleGrey | Number | 0.6 | The middle grey factor. |
37-
| maxLuminance | Number | 16 | Maximum luminance |
38-
| minLuminance | Number | 0.01 | The minimum luminance. Prevents very high exposure in dark scenes. |
39-
| averageLuminance | Number | 1 | The average luminance. Used for the non-adaptive Reinhard operator. |
40-
| adaptationRate | Number | 1 | The luminance adaptation rate. |
44+
| Name | Type | Default | Description |
45+
| ---------------- | --------------- | ------- | ------------------------------------------------------------------- |
46+
| mode | ToneMappingMode | | The tone mapping algorithm |
47+
| resolution | Number | 256 | The resolution of the luminance texture. Must be a power of two. |
48+
| adaptive | boolean | true | Toggle adaptive luminance map usage |
49+
| blendFunction | BlendFunction | | The blend function of this effect. |
50+
| middleGrey | Number | 0.6 | The middle grey factor. |
51+
| maxLuminance | Number | 16 | Maximum luminance |
52+
| minLuminance | Number | 0.01 | The minimum luminance. Prevents very high exposure in dark scenes. |
53+
| averageLuminance | Number | 1 | The average luminance. Used for the non-adaptive Reinhard operator. |
54+
| adaptationRate | Number | 1 | The luminance adaptation rate. |

0 commit comments

Comments
 (0)