@@ -802,6 +802,11 @@ static std::string GenEngineConstants() {
802802 AddConst ( str, " r_RimExponent" , r_rimExponent->value );
803803 }
804804
805+ if ( r_cheapSRGB.Get () )
806+ {
807+ AddDefine ( str, " r_cheapSRGB" , 1 );
808+ }
809+
805810 if ( r_showLightTiles->integer )
806811 {
807812 AddDefine ( str, " r_showLightTiles" , 1 );
@@ -2261,6 +2266,7 @@ GLShader_generic::GLShader_generic( GLShaderManager *manager ) :
22612266 u_AlphaThreshold( this ),
22622267 u_ModelMatrix( this ),
22632268 u_ModelViewProjectionMatrix( this ),
2269+ u_LinearizeTexture( this ),
22642270 u_ColorModulateColorGen( this ),
22652271 u_Color( this ),
22662272 u_Bones( this ),
@@ -2293,6 +2299,7 @@ GLShader_genericMaterial::GLShader_genericMaterial( GLShaderManager* manager ) :
22932299 u_AlphaThreshold( this ),
22942300 u_ModelMatrix( this ),
22952301 u_ModelViewProjectionMatrix( this ),
2302+ u_LinearizeTexture( this ),
22962303 u_ColorModulateColorGen( this ),
22972304 u_Color( this ),
22982305 u_DepthScale( this ),
@@ -2334,6 +2341,7 @@ GLShader_lightMapping::GLShader_lightMapping( GLShaderManager *manager ) :
23342341 u_ViewOrigin( this ),
23352342 u_ModelMatrix( this ),
23362343 u_ModelViewProjectionMatrix( this ),
2344+ u_LinearizeTexture( this ),
23372345 u_Bones( this ),
23382346 u_VertexInterpolation( this ),
23392347 u_ReliefDepthScale( this ),
@@ -2402,6 +2410,7 @@ GLShader_lightMappingMaterial::GLShader_lightMappingMaterial( GLShaderManager* m
24022410 u_ViewOrigin( this ),
24032411 u_ModelMatrix( this ),
24042412 u_ModelViewProjectionMatrix( this ),
2413+ u_LinearizeTexture( this ),
24052414 u_ReliefDepthScale( this ),
24062415 u_ReliefOffsetBias( this ),
24072416 u_NormalScale( this ),
@@ -2712,6 +2721,7 @@ GLShader_skybox::GLShader_skybox( GLShaderManager *manager ) :
27122721 u_CloudHeight( this ),
27132722 u_UseCloudMap( this ),
27142723 u_AlphaThreshold( this ),
2724+ u_LinearizeTexture( this ),
27152725 u_ModelViewProjectionMatrix( this )
27162726{
27172727}
@@ -2730,6 +2740,7 @@ GLShader_skyboxMaterial::GLShader_skyboxMaterial( GLShaderManager* manager ) :
27302740 u_CloudHeight( this ),
27312741 u_UseCloudMap( this ),
27322742 u_AlphaThreshold( this ),
2743+ u_LinearizeTexture( this ),
27332744 u_ModelViewProjectionMatrix( this )
27342745{}
27352746
@@ -2743,6 +2754,7 @@ GLShader_fogQuake3::GLShader_fogQuake3( GLShaderManager *manager ) :
27432754 u_FogMap( this ),
27442755 u_ModelMatrix( this ),
27452756 u_ModelViewProjectionMatrix( this ),
2757+ u_LinearizeTexture( this ),
27462758 u_ColorGlobal( this ),
27472759 u_Bones( this ),
27482760 u_VertexInterpolation( this ),
@@ -2765,6 +2777,7 @@ GLShader_fogQuake3Material::GLShader_fogQuake3Material( GLShaderManager* manager
27652777 u_FogMap( this ),
27662778 u_ModelMatrix( this ),
27672779 u_ModelViewProjectionMatrix( this ),
2780+ u_LinearizeTexture( this ),
27682781 u_ColorGlobal( this ),
27692782 u_FogDistanceVector( this ),
27702783 u_FogDepthVector( this ),
@@ -2782,6 +2795,7 @@ GLShader_fogGlobal::GLShader_fogGlobal( GLShaderManager *manager ) :
27822795 u_DepthMap( this ),
27832796 u_ModelViewProjectionMatrix( this ),
27842797 u_UnprojectMatrix( this ),
2798+ u_LinearizeTexture( this ),
27852799 u_Color( this ),
27862800 u_FogDistanceVector( this )
27872801{
@@ -2896,7 +2910,8 @@ GLShader_cameraEffects::GLShader_cameraEffects( GLShaderManager *manager ) :
28962910 u_ColorModulate( this ),
28972911 u_TextureMatrix( this ),
28982912 u_ModelViewProjectionMatrix( this ),
2899- u_InverseGamma( this )
2913+ u_InverseGamma( this ),
2914+ u_DelinearizeScreen( this )
29002915{
29012916}
29022917
0 commit comments