mirror of
https://github.com/godotengine/godot.git
synced 2024-11-23 12:43:43 +00:00
Updated tutorial_hdr (markdown)
parent
406ee89acb
commit
96ce2cb8e6
@ -4,17 +4,18 @@
|
||||
|
||||
Normally, an artist does all the 3D modelling, then all the texturing, looks at his or her awesome looking model in the 3D DCC and says "looks fantastic, ready for integration!" then goes into the game, lighting is setup and the game runs.
|
||||
|
||||
So where does all this HDR stuff thing come from? The idea is that instead of dealing with colors that go
|
||||
from black to white (0 to 1), we deal with colors higher than white (for example, 0 to 8 times white).
|
||||
So where does all this HDR stuff thing come from? The idea is that instead of dealing with colors that go from black to white (0 to 1), we use colors whiter than white (for example, 0 to 8 times white).
|
||||
|
||||
To be more practical, imagine that in a regular scene, the intensity of a light (generally 1) is set to 5. The whole scene will turn super bright and almost white and nothing will make sense. The next step is computing the exposure, which is getting the average of all the pixels on the screen. It will most likely be still above 1. Finally, using the exposure we try bring back the scene brightness to something that makes sense. This last operation is called tone-mapping. The simplest and most common way of tone-mapping is dividing every pixel by the exposure. This basically what most real-life cameras do, either physically (by adjusting the incoming light), or digitally.
|
||||
|
||||
Finally, we are at the same place we started. So, what was the point of all this?
|
||||
|
||||
... to be continued (work in progress!)
|
||||
To be more practical, imagine that in a regular scene, the intensity of a light (generally 1.0) is set to 5.0. The whole scene will turn very bright (towards white) and look horrible.
|
||||
After this the luminance of the scene is computed by averaging the luminance of every pixel of it, and this value is used to bring the scene back to normal ranges. This last operation is called tone-mapping. Finally, we are at a similar place from where we started:
|
||||
|
||||
<p align="center"><img src="images/hdr_tonemap.png"></p>
|
||||
|
||||
Except the scene is more contrasted, because there is a higher light range in play. What is this all useful for? The idea is that the scene luminance will change while you move through the world, allowing situations like this to happen:
|
||||
|
||||
<p align="center"><img src="images/hdr_cave.png"></p>
|
||||
|
||||
Additionally, it is possible to set a threshold value to send to the glow buffer depending on the pixel luminance. This allows for more realistic light bleeding effects in the scene.
|
||||
|
||||
## Parameters of HDR
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user