diff options
author | marha <marha@users.sourceforge.net> | 2014-08-11 21:22:25 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2014-08-11 21:22:25 +0200 |
commit | 8e27619ab489dece35cc4bec86950ee7729cd309 (patch) | |
tree | ab59dbc661e00c12ed4777cf9d0d37393c4163aa /mesalib/src/mesa/swrast/s_texfetch_tmp.h | |
parent | ffc99ce2402fe5c9a6eb8fcf193e8e9472fd993b (diff) | |
parent | fdbedba4d50e1b28b0249c83ba11c029f096e400 (diff) | |
download | vcxsrv-8e27619ab489dece35cc4bec86950ee7729cd309.tar.gz vcxsrv-8e27619ab489dece35cc4bec86950ee7729cd309.tar.bz2 vcxsrv-8e27619ab489dece35cc4bec86950ee7729cd309.zip |
Merge remote-tracking branch 'origin/released'
Conflicts:
libxcb/src/c_client.py
mesalib/include/GL/glext.h
mesalib/include/GL/glxext.h
mesalib/src/glsl/.gitignore
mesalib/src/mesa/drivers/dri/common/xmlconfig.h
mesalib/src/mesa/main/.gitignore
xorg-server/Xext/xvmain.c
xorg-server/dix/dispatch.c
xorg-server/hw/xfree86/common/compiler.h
Diffstat (limited to 'mesalib/src/mesa/swrast/s_texfetch_tmp.h')
-rw-r--r-- | mesalib/src/mesa/swrast/s_texfetch_tmp.h | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/mesalib/src/mesa/swrast/s_texfetch_tmp.h b/mesalib/src/mesa/swrast/s_texfetch_tmp.h index deda59246..72037ec00 100644 --- a/mesalib/src/mesa/swrast/s_texfetch_tmp.h +++ b/mesalib/src/mesa/swrast/s_texfetch_tmp.h @@ -737,9 +737,9 @@ FETCH(BGR_SRGB8)(const struct swrast_texture_image *texImage, GLint i, GLint j, GLint k, GLfloat *texel) { const GLubyte *src = TEXEL_ADDR(GLubyte, texImage, i, j, k, 3); - texel[RCOMP] = nonlinear_to_linear(src[2]); - texel[GCOMP] = nonlinear_to_linear(src[1]); - texel[BCOMP] = nonlinear_to_linear(src[0]); + texel[RCOMP] = util_format_srgb_8unorm_to_linear_float(src[2]); + texel[GCOMP] = util_format_srgb_8unorm_to_linear_float(src[1]); + texel[BCOMP] = util_format_srgb_8unorm_to_linear_float(src[0]); texel[ACOMP] = 1.0F; } @@ -749,9 +749,9 @@ FETCH(A8B8G8R8_SRGB)(const struct swrast_texture_image *texImage, GLint i, GLint j, GLint k, GLfloat *texel) { const GLuint s = *TEXEL_ADDR(GLuint, texImage, i, j, k, 1); - texel[RCOMP] = nonlinear_to_linear( (s >> 24) ); - texel[GCOMP] = nonlinear_to_linear( (s >> 16) & 0xff ); - texel[BCOMP] = nonlinear_to_linear( (s >> 8) & 0xff ); + texel[RCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 24) ); + texel[GCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 16) & 0xff ); + texel[BCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 8) & 0xff ); texel[ACOMP] = UBYTE_TO_FLOAT( (s ) & 0xff ); /* linear! */ } @@ -761,9 +761,9 @@ FETCH(B8G8R8A8_SRGB)(const struct swrast_texture_image *texImage, GLint i, GLint j, GLint k, GLfloat *texel) { const GLuint s = *TEXEL_ADDR(GLuint, texImage, i, j, k, 1); - texel[RCOMP] = nonlinear_to_linear( (s >> 16) & 0xff ); - texel[GCOMP] = nonlinear_to_linear( (s >> 8) & 0xff ); - texel[BCOMP] = nonlinear_to_linear( (s ) & 0xff ); + texel[RCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 16) & 0xff ); + texel[GCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 8) & 0xff ); + texel[BCOMP] = util_format_srgb_8unorm_to_linear_float( (s ) & 0xff ); texel[ACOMP] = UBYTE_TO_FLOAT( (s >> 24) ); /* linear! */ } @@ -773,9 +773,9 @@ FETCH(R8G8B8A8_SRGB)(const struct swrast_texture_image *texImage, GLint i, GLint j, GLint k, GLfloat *texel) { const GLuint s = *TEXEL_ADDR(GLuint, texImage, i, j, k, 1); - texel[RCOMP] = nonlinear_to_linear( (s ) & 0xff ); - texel[GCOMP] = nonlinear_to_linear( (s >> 8) & 0xff ); - texel[BCOMP] = nonlinear_to_linear( (s >> 16) & 0xff ); + texel[RCOMP] = util_format_srgb_8unorm_to_linear_float( (s ) & 0xff ); + texel[GCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 8) & 0xff ); + texel[BCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 16) & 0xff ); texel[ACOMP] = UBYTE_TO_FLOAT( (s >> 24) ); /* linear! */ } @@ -785,9 +785,9 @@ FETCH(R8G8B8X8_SRGB)(const struct swrast_texture_image *texImage, GLint i, GLint j, GLint k, GLfloat *texel) { const GLuint s = *TEXEL_ADDR(GLuint, texImage, i, j, k, 1); - texel[RCOMP] = nonlinear_to_linear( (s ) & 0xff ); - texel[GCOMP] = nonlinear_to_linear( (s >> 8) & 0xff ); - texel[BCOMP] = nonlinear_to_linear( (s >> 16) & 0xff ); + texel[RCOMP] = util_format_srgb_8unorm_to_linear_float( (s ) & 0xff ); + texel[GCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 8) & 0xff ); + texel[BCOMP] = util_format_srgb_8unorm_to_linear_float( (s >> 16) & 0xff ); texel[ACOMP] = 1.0f; } @@ -799,7 +799,7 @@ FETCH(L_SRGB8)(const struct swrast_texture_image *texImage, const GLubyte *src = TEXEL_ADDR(GLubyte, texImage, i, j, k, 1); texel[RCOMP] = texel[GCOMP] = - texel[BCOMP] = nonlinear_to_linear(src[0]); + texel[BCOMP] = util_format_srgb_8unorm_to_linear_float(src[0]); texel[ACOMP] = 1.0F; } @@ -811,7 +811,7 @@ FETCH(L8A8_SRGB)(const struct swrast_texture_image *texImage, const GLubyte *src = TEXEL_ADDR(GLubyte, texImage, i, j, k, 2); texel[RCOMP] = texel[GCOMP] = - texel[BCOMP] = nonlinear_to_linear(src[0]); + texel[BCOMP] = util_format_srgb_8unorm_to_linear_float(src[0]); texel[ACOMP] = UBYTE_TO_FLOAT(src[1]); /* linear */ } |