Uploaded image for project: 'Exodus Viewer'
  1. EV-4

Move gamma correction to a 2D LUT on all gamma correct shaders

    Details

    • Type: New Feature
    • Status: Closed (View workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: Pre-Organisation
    • Labels:
      None
    • Sprint:

      Description

      Gamma correction currently uses several pow instructions to convert diffuse textures to linear space. Each pow instruction can extend shader length by two or more instructions, so it would be a good idea to start moving everything over to 2D LUTs to minimize this cost. Could also look into applying the conversion LUT to the diffuse G-Buffer in the deferred renderer to reduce the cost of applying it to all partially visible objects in the scene.

      Alternatively, we could just move over to approximating a gamma of 2.0 by multiplying the diffuse texture against its self, or finding a way to approximate a gamma of 2.2 without the use of pow().

      Update: Instead, we're going for approximating pow(..., 2.2); and pow(..., 1.0/2.2); using a polynomial function that costs less taxing instructions than a single pow.

        Attachments

          Activity

            People

            • Assignee:
              geenz Geenz Spad
              Reporter:
              geenz Geenz Spad
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: