Implementation of sRGB image support. Overhauls the linearization setup to utilize the sRGB image types, as well as refactors the use of ColorF and ColorI to be properly internally consistent. ColorIs are used only for front-facing/editing/UI settings, and ColorFs, now renamed to LinearColorF to reduce confusion of purpose, are used for color info in the engine itself. This avoids confusing and expensive conversions back and forth between types and avoids botches with linearity. Majority work done by @rextimmy

This commit is contained in:
Areloch 2017-06-23 11:36:20 -05:00
parent 8943c673fb
commit 0801a3cca8
294 changed files with 3894 additions and 2813 deletions

View file

@ -39,7 +39,7 @@ public:
virtual GFXFormat getFormat()
{
// TODO: Fix me!
return GFXFormatR8G8B8A8;
return GFXFormatR8G8B8A8_SRGB;
}
void makeActive();
virtual bool present();
@ -50,9 +50,6 @@ public:
virtual void resolveTo(GFXTextureObject* obj);
void _onAppSignal(WindowId wnd, S32 event);
// create pixel format for the window
void createPixelFormat();
private:
friend class GFXGLDevice;
@ -61,8 +58,6 @@ private:
GFXTexHandle mBackBufferColorTex, mBackBufferDepthTex;
Point2I size;
GFXDevice* mDevice;
/// Is this a secondary window
bool mSecondaryWindow;
void* mContext;
void* mFullscreenContext;
void _teardownCurrentMode();