Add AgX tonemapper option to Environment

Technical implementation notes:

- Moved linearization step to before the outset matrix is applied and
  changed polynomial contrast curve approximation.
  - This does *not* implement Blender's chroma rotation to address hue shift.
    This hue rotation was found to have a significant performance impact.
- Improved performance by combining the AgX outset matrix with the Rec 2020 matrix.

Co-authored-by: Allen Pestaluky <allenpestaluky@gmail.com>
Co-authored-by: Clay John <claynjohn@gmail.com>
This commit is contained in:
Hugo Locurcio
2024-01-01 18:10:42 +01:00
parent d2ada64a03
commit 084e84be78
8 changed files with 174 additions and 18 deletions

View File

@ -1243,7 +1243,8 @@ public:
ENV_TONE_MAPPER_LINEAR,
ENV_TONE_MAPPER_REINHARD,
ENV_TONE_MAPPER_FILMIC,
ENV_TONE_MAPPER_ACES
ENV_TONE_MAPPER_ACES,
ENV_TONE_MAPPER_AGX,
};
virtual void environment_set_tonemap(RID p_env, EnvironmentToneMapper p_tone_mapper, float p_exposure, float p_white) = 0;