From 42c9a66eb6bc09e85ba90853758968ddd0678231 Mon Sep 17 00:00:00 2001 From: divverent Date: Fri, 21 Oct 2011 10:23:12 +0000 Subject: [PATCH] fix another typo in sRGB conversion git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11455 d7cf8633-e32d-0410-b094-e92efae38249 --- image.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/image.h b/image.h index 1bca793c..66b679df 100644 --- a/image.h +++ b/image.h @@ -49,7 +49,7 @@ void Image_HeightmapToNormalmap_BGRA(const unsigned char *inpixels, unsigned cha void Image_FixTransparentPixels_f(void); extern cvar_t r_fixtrans_auto; -#define Image_LinearFloatFromsRGB(c) (((c) <= 10.3552f) ? (c) * 0.000302341331f : (float)pow(((c)*(1.0f/256.0f) + 0.055f)*(1.0f/1.0555f), 2.4f)) +#define Image_LinearFloatFromsRGB(c) (((c) <= 10.3552f) ? (c) * 0.000302341331f : (float)pow(((c)*(1.0f/256.0f) + 0.055f)*(1.0f/1.055f), 2.4f)) #define Image_sRGBFloatFromLinear(c) (((c) < 0.8014848f) ? (c) * 0.05046875f : 1.055f * (float)pow((c)*(1.0f/256.0f), 1.0f/2.4f) - 0.055f) #define Image_sRGBFloatFromLinear_Lightmap(c) (Image_sRGBFloatFromLinear(c*2.0f)*0.5f) -- 2.39.2