Skip to content

Glow/HDR improvements

Rafał Mikrut requested to merge github/fork/CptPotato/glow-improvements into master

Created by: CptPotato

A few improvements and changes around glow and HDR.

These are the changes I made (for myself) that improve or restructure some parts of godots HDR. I figured some of it might be helpful so I decided to make this PR. You can use parts of it or just use this as reference for future changes. If you wish to merge the PR but want some things changed or removed, let me know. Note that these changes do "break" existing projects.

Here's a quick screenshot (I don't have any better test scenes right now).

newglow

Here's a list of things I chaged or added:

  • added "filmic saturation" option to tonemapper (6c6bdf8)
  • added two new glow blend modes "linear add" and "linear mix" (4d7cc8b)
  • switched to a new, more adjustable way of applying the glow highpass/threshold (4e8c122, including the following 2)
  • added glow per-level-weight (was previously called "strength")
  • made glow energy conserving (always on at the moment)
  • switched to a different soft-light algorithm which is less complex (30a0b73)
  • fixed reinhard tonemapping whitepoint (along with misspelling of it's name "reinhard" across different files) (186a17e, 133bf16)
  • "fixed" filmic tonemapping (this one is debatable) (d9aa07a)
  • added 2 tonemappers: the widely used Uncharted 2 algorithm and a simplified filmic one (both from an Uncharted 2 paper) (8c85e3c)

For more detailed explanations with screenshots: https://imgur.com/a/7DjwWM7 The names of the properties are maybe not optimal, so I'm open for suggestions.

I will keep the commits separated until I know if this PR is okay and if there is anything I should change or remove.

Merge request reports