aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-10-30 08:08:23 +0100
committermarha <marha@users.sourceforge.net>2012-10-30 08:08:23 +0100
commit7b3f315a5d8b90dcb0db5512ed91fa700027cb7a (patch)
tree5d8a2f4983d9814c71325059d75e6de2af1a3b3e /mesalib/src/mesa/main
parent8d86f8c566c4181c846a872a5a2f88718e635a72 (diff)
downloadvcxsrv-7b3f315a5d8b90dcb0db5512ed91fa700027cb7a.tar.gz
vcxsrv-7b3f315a5d8b90dcb0db5512ed91fa700027cb7a.tar.bz2
vcxsrv-7b3f315a5d8b90dcb0db5512ed91fa700027cb7a.zip
fontconfig xserver mesa git update 30 oct 2012
fontconfig: bdaef0b80dc27f4ab7a9d9bcedcfd8b5724b3cfd xserver: 1ca096d5e07221025c4c4110528772b7d94f15ee mesa: 0a66ced8f822b0d5478b0cd6d72c1a6ad70647a2
Diffstat (limited to 'mesalib/src/mesa/main')
-rw-r--r--mesalib/src/mesa/main/accum.c4
-rw-r--r--mesalib/src/mesa/main/config.h2
-rw-r--r--mesalib/src/mesa/main/context.c2
-rw-r--r--mesalib/src/mesa/main/format_unpack.c8
-rw-r--r--mesalib/src/mesa/main/get.c6
-rw-r--r--mesalib/src/mesa/main/mtypes.h12
-rw-r--r--mesalib/src/mesa/main/shared.c2
-rw-r--r--mesalib/src/mesa/main/texstorage.c2
-rw-r--r--mesalib/src/mesa/main/transformfeedback.c6
9 files changed, 22 insertions, 22 deletions
diff --git a/mesalib/src/mesa/main/accum.c b/mesalib/src/mesa/main/accum.c
index 8b71640df..e2d7726b5 100644
--- a/mesalib/src/mesa/main/accum.c
+++ b/mesalib/src/mesa/main/accum.c
@@ -205,7 +205,7 @@ accum_scale_or_bias(struct gl_context *ctx, GLfloat value,
if (accRb->Format == MESA_FORMAT_SIGNED_RGBA_16) {
const GLshort incr = (GLshort) (value * 32767.0f);
- GLuint i, j;
+ GLint i, j;
if (bias) {
for (j = 0; j < height; j++) {
GLshort *acc = (GLshort *) accMap;
@@ -283,7 +283,7 @@ accum_or_load(struct gl_context *ctx, GLfloat value,
if (accRb->Format == MESA_FORMAT_SIGNED_RGBA_16) {
const GLfloat scale = value * 32767.0f;
- GLuint i, j;
+ GLint i, j;
GLfloat (*rgba)[4];
rgba = malloc(width * 4 * sizeof(GLfloat));
diff --git a/mesalib/src/mesa/main/config.h b/mesalib/src/mesa/main/config.h
index 1b72b5449..99910d7f3 100644
--- a/mesalib/src/mesa/main/config.h
+++ b/mesalib/src/mesa/main/config.h
@@ -187,7 +187,7 @@
#define MAX_PROGRAM_CALL_DEPTH 8
#define MAX_PROGRAM_TEMPS 256
#define MAX_PROGRAM_ADDRESS_REGS 2
-#define MAX_VARYING 16 /**< number of float[4] vectors */
+#define MAX_VARYING 32 /**< number of float[4] vectors */
#define MAX_SAMPLERS MAX_TEXTURE_IMAGE_UNITS
#define MAX_PROGRAM_INPUTS 32
#define MAX_PROGRAM_OUTPUTS 64
diff --git a/mesalib/src/mesa/main/context.c b/mesalib/src/mesa/main/context.c
index b00c64233..a51073843 100644
--- a/mesalib/src/mesa/main/context.c
+++ b/mesalib/src/mesa/main/context.c
@@ -614,7 +614,7 @@ _mesa_init_constants(struct gl_context *ctx)
ctx->Const.MaxVertexTextureImageUnits = MAX_VERTEX_TEXTURE_IMAGE_UNITS;
ctx->Const.MaxCombinedTextureImageUnits = MAX_COMBINED_TEXTURE_IMAGE_UNITS;
- ctx->Const.MaxVarying = MAX_VARYING;
+ ctx->Const.MaxVarying = 16; /* old limit not to break tnl and swrast */
ctx->Const.MaxGeometryTextureImageUnits = MAX_GEOMETRY_TEXTURE_IMAGE_UNITS;
ctx->Const.MaxVertexVaryingComponents = MAX_VERTEX_VARYING_COMPONENTS;
ctx->Const.MaxGeometryVaryingComponents = MAX_GEOMETRY_VARYING_COMPONENTS;
diff --git a/mesalib/src/mesa/main/format_unpack.c b/mesalib/src/mesa/main/format_unpack.c
index 7b46dfc79..04fd1d698 100644
--- a/mesalib/src/mesa/main/format_unpack.c
+++ b/mesalib/src/mesa/main/format_unpack.c
@@ -633,7 +633,7 @@ unpack_Z24_S8(const void *src, GLfloat dst[][4], GLuint n)
for (i = 0; i < n; i++) {
dst[i][0] =
dst[i][1] =
- dst[i][2] = (s[i] >> 8) * scale;
+ dst[i][2] = (GLfloat) ((s[i] >> 8) * scale);
dst[i][3] = 1.0F;
ASSERT(dst[i][0] >= 0.0F);
ASSERT(dst[i][0] <= 1.0F);
@@ -650,7 +650,7 @@ unpack_S8_Z24(const void *src, GLfloat dst[][4], GLuint n)
for (i = 0; i < n; i++) {
dst[i][0] =
dst[i][1] =
- dst[i][2] = (s[i] & 0x00ffffff) * scale;
+ dst[i][2] = (float) ((s[i] & 0x00ffffff) * scale);
dst[i][3] = 1.0F;
ASSERT(dst[i][0] >= 0.0F);
ASSERT(dst[i][0] <= 1.0F);
@@ -2856,7 +2856,7 @@ unpack_float_z_Z24_X8(GLuint n, const void *src, GLfloat *dst)
const GLdouble scale = 1.0 / (GLdouble) 0xffffff;
GLuint i;
for (i = 0; i < n; i++) {
- dst[i] = (s[i] >> 8) * scale;
+ dst[i] = (GLfloat) ((s[i] >> 8) * scale);
ASSERT(dst[i] >= 0.0F);
ASSERT(dst[i] <= 1.0F);
}
@@ -2870,7 +2870,7 @@ unpack_float_z_X8_Z24(GLuint n, const void *src, GLfloat *dst)
const GLdouble scale = 1.0 / (GLdouble) 0xffffff;
GLuint i;
for (i = 0; i < n; i++) {
- dst[i] = (s[i] & 0x00ffffff) * scale;
+ dst[i] = (GLfloat) ((s[i] & 0x00ffffff) * scale);
ASSERT(dst[i] >= 0.0F);
ASSERT(dst[i] <= 1.0F);
}
diff --git a/mesalib/src/mesa/main/get.c b/mesalib/src/mesa/main/get.c
index e38d594e2..805f0f978 100644
--- a/mesalib/src/mesa/main/get.c
+++ b/mesalib/src/mesa/main/get.c
@@ -1149,7 +1149,7 @@ _mesa_GetFloatv(GLenum pname, GLfloat *params)
break;
case TYPE_DOUBLEN:
- params[0] = ((GLdouble *) p)[0];
+ params[0] = (GLfloat) (((GLdouble *) p)[0]);
break;
case TYPE_INT_4:
@@ -1170,7 +1170,7 @@ _mesa_GetFloatv(GLenum pname, GLfloat *params)
break;
case TYPE_INT64:
- params[0] = ((GLint64 *) p)[0];
+ params[0] = (GLfloat) (((GLint64 *) p)[0]);
break;
case TYPE_BOOLEAN:
@@ -1449,7 +1449,7 @@ _mesa_GetDoublev(GLenum pname, GLdouble *params)
break;
case TYPE_INT64:
- params[0] = ((GLint64 *) p)[0];
+ params[0] = (GLdouble) (((GLint64 *) p)[0]);
break;
case TYPE_BOOLEAN:
diff --git a/mesalib/src/mesa/main/mtypes.h b/mesalib/src/mesa/main/mtypes.h
index c3378cd99..7f2adc773 100644
--- a/mesalib/src/mesa/main/mtypes.h
+++ b/mesalib/src/mesa/main/mtypes.h
@@ -2763,12 +2763,12 @@ struct gl_program_constants
*/
struct gl_constants
{
- GLint MaxTextureMbytes; /**< Max memory per image, in MB */
- GLint MaxTextureLevels; /**< Max mipmap levels. */
- GLint Max3DTextureLevels; /**< Max mipmap levels for 3D textures */
- GLint MaxCubeTextureLevels; /**< Max mipmap levels for cube textures */
- GLint MaxArrayTextureLayers; /**< Max layers in array textures */
- GLint MaxTextureRectSize; /**< Max rectangle texture size, in pixes */
+ GLuint MaxTextureMbytes; /**< Max memory per image, in MB */
+ GLuint MaxTextureLevels; /**< Max mipmap levels. */
+ GLuint Max3DTextureLevels; /**< Max mipmap levels for 3D textures */
+ GLuint MaxCubeTextureLevels; /**< Max mipmap levels for cube textures */
+ GLuint MaxArrayTextureLayers; /**< Max layers in array textures */
+ GLuint MaxTextureRectSize; /**< Max rectangle texture size, in pixes */
GLuint MaxTextureCoordUnits;
GLuint MaxTextureImageUnits;
GLuint MaxVertexTextureImageUnits;
diff --git a/mesalib/src/mesa/main/shared.c b/mesalib/src/mesa/main/shared.c
index fab2995a4..2d2f7bd1d 100644
--- a/mesalib/src/mesa/main/shared.c
+++ b/mesalib/src/mesa/main/shared.c
@@ -89,7 +89,7 @@ _mesa_alloc_shared_state(struct gl_context *ctx)
/* Create default texture objects */
for (i = 0; i < NUM_TEXTURE_TARGETS; i++) {
/* NOTE: the order of these enums matches the TEXTURE_x_INDEX values */
- static const GLenum targets[NUM_TEXTURE_TARGETS] = {
+ static const GLenum targets[] = {
GL_TEXTURE_BUFFER,
GL_TEXTURE_2D_ARRAY_EXT,
GL_TEXTURE_1D_ARRAY_EXT,
diff --git a/mesalib/src/mesa/main/texstorage.c b/mesalib/src/mesa/main/texstorage.c
index ca02ef301..283aefad3 100644
--- a/mesalib/src/mesa/main/texstorage.c
+++ b/mesalib/src/mesa/main/texstorage.c
@@ -284,7 +284,7 @@ tex_storage_error_check(struct gl_context *ctx, GLuint dims, GLenum target,
}
/* check levels against maximum (note different error than above) */
- if (levels > _mesa_max_texture_levels(ctx, target)) {
+ if (levels > (GLint) _mesa_max_texture_levels(ctx, target)) {
_mesa_error(ctx, GL_INVALID_OPERATION,
"glTexStorage%uD(levels too large)", dims);
return GL_TRUE;
diff --git a/mesalib/src/mesa/main/transformfeedback.c b/mesalib/src/mesa/main/transformfeedback.c
index 0669b3a25..1afc0dccb 100644
--- a/mesalib/src/mesa/main/transformfeedback.c
+++ b/mesalib/src/mesa/main/transformfeedback.c
@@ -277,7 +277,7 @@ _mesa_BeginTransformFeedback(GLenum mode)
{
struct gl_transform_feedback_object *obj;
struct gl_transform_feedback_info *info;
- int i;
+ GLuint i;
GET_CURRENT_CONTEXT(ctx);
obj = ctx->TransformFeedback.CurrentObject;
@@ -537,7 +537,7 @@ _mesa_TransformFeedbackVaryings(GLuint program, GLsizei count,
const GLchar **varyings, GLenum bufferMode)
{
struct gl_shader_program *shProg;
- GLuint i;
+ GLint i;
GET_CURRENT_CONTEXT(ctx);
switch (bufferMode) {
@@ -648,7 +648,7 @@ _mesa_GetTransformFeedbackVarying(GLuint program, GLuint index,
}
linked_xfb_info = &shProg->LinkedTransformFeedback;
- if (index >= linked_xfb_info->NumVarying) {
+ if (index >= (GLuint) linked_xfb_info->NumVarying) {
_mesa_error(ctx, GL_INVALID_VALUE,
"glGetTransformFeedbackVaryings(index=%u)", index);
return;