-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Gamma correct rendering + sRGBDemo app
- Add sRGB helper class to allow user to input colors in non-linear sRGB (which will be what most people are used to). Conversion to linear sRGB is done automatic - Shaders assume linear color inputs - Textures can be marked as either sRGB (for things that are colors) or not (for things that are "maps", like normal, bump, etc). Marking color textures as sRGB encoded means that samplers will decode "automatically" to linear for use in shaders - Output framebuffers (both the backbuffer and intermediate framebuffers) are marked as sRGB, so that writes from the shaders (linear) will automatcally sRGB encode the outputs (i.e. no need to manually gamma correct as the final step of the shader) - Add "012 - sRGB" demo to show gamma correct alpha blending - Move "ImGuiEx" into Pikzel "ImGui" library. Saves duplicating it in clients. - Add a method to initialise ImGui to a "default" Pikzel ImGui style Note: ImGui does not play nice with sRGB framebuffers. This is a known issue (eg. ocornut/imgui#578 and also issues 1724, and 2468).
- Loading branch information
Showing
52 changed files
with
1,681 additions
and
782 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.