aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/drivers
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-01-09 16:34:28 +0100
committermarha <marha@users.sourceforge.net>2012-01-09 16:34:28 +0100
commita1e97828c89278770cb249039ec92d959440c640 (patch)
treef3d4ed7e3f3d589c606f01b3c9e6de03d638e2d3 /mesalib/src/mesa/drivers
parent7e9f4ea970e8f7008c212d7d3918a974eb0066da (diff)
downloadvcxsrv-a1e97828c89278770cb249039ec92d959440c640.tar.gz
vcxsrv-a1e97828c89278770cb249039ec92d959440c640.tar.bz2
vcxsrv-a1e97828c89278770cb249039ec92d959440c640.zip
xwininfo libX11 mesa mkfontscale xkeyboard-config git update 9 jan 2011
Diffstat (limited to 'mesalib/src/mesa/drivers')
-rw-r--r--mesalib/src/mesa/drivers/common/meta.c39
-rw-r--r--mesalib/src/mesa/drivers/common/meta.h12
2 files changed, 31 insertions, 20 deletions
diff --git a/mesalib/src/mesa/drivers/common/meta.c b/mesalib/src/mesa/drivers/common/meta.c
index 785a59531..ad289aa70 100644
--- a/mesalib/src/mesa/drivers/common/meta.c
+++ b/mesalib/src/mesa/drivers/common/meta.c
@@ -1026,7 +1026,7 @@ _mesa_meta_in_progress(struct gl_context *ctx)
static INLINE GLfloat
invert_z(GLfloat normZ)
{
- GLfloat objZ = 1.0 - 2.0 * normZ;
+ GLfloat objZ = 1.0f - 2.0f * normZ;
return objZ;
}
@@ -2920,7 +2920,7 @@ _mesa_meta_GenerateMipmap(struct gl_context *ctx, GLenum target,
/* setup texcoords (XXX what about border?) */
setup_texture_coords(faceTarget,
- 0.0, 0.0, /* width, height never used here */
+ 0.0f, 0.0f, /* width, height never used here */
slice,
verts[0].tex,
verts[1].tex,
@@ -3098,20 +3098,19 @@ get_temp_image_type(struct gl_context *ctx, GLenum baseFormat)
*/
static void
copy_tex_sub_image(struct gl_context *ctx,
- GLuint dims, GLenum target, GLint level,
+ GLuint dims,
+ struct gl_texture_image *texImage,
GLint xoffset, GLint yoffset, GLint zoffset,
+ struct gl_renderbuffer *rb,
GLint x, GLint y,
GLsizei width, GLsizei height)
{
- struct gl_texture_object *texObj;
- struct gl_texture_image *texImage;
+ struct gl_texture_object *texObj = texImage->TexObject;
+ const GLenum target = texObj->Target;
GLenum format, type;
GLint bpp;
void *buf;
- texObj = _mesa_get_current_tex_object(ctx, target);
- texImage = _mesa_select_tex_image(ctx, texObj, target, level);
-
/* Choose format/type for temporary image buffer */
format = _mesa_get_format_base_format(texImage->TexFormat);
if (format == GL_LUMINANCE ||
@@ -3180,34 +3179,40 @@ copy_tex_sub_image(struct gl_context *ctx,
void
-_mesa_meta_CopyTexSubImage1D(struct gl_context *ctx, GLenum target, GLint level,
+_mesa_meta_CopyTexSubImage1D(struct gl_context *ctx,
+ struct gl_texture_image *texImage,
GLint xoffset,
+ struct gl_renderbuffer *rb,
GLint x, GLint y, GLsizei width)
{
- copy_tex_sub_image(ctx, 1, target, level, xoffset, 0, 0,
- x, y, width, 1);
+ copy_tex_sub_image(ctx, 1, texImage, xoffset, 0, 0,
+ rb, x, y, width, 1);
}
void
-_mesa_meta_CopyTexSubImage2D(struct gl_context *ctx, GLenum target, GLint level,
+_mesa_meta_CopyTexSubImage2D(struct gl_context *ctx,
+ struct gl_texture_image *texImage,
GLint xoffset, GLint yoffset,
+ struct gl_renderbuffer *rb,
GLint x, GLint y,
GLsizei width, GLsizei height)
{
- copy_tex_sub_image(ctx, 2, target, level, xoffset, yoffset, 0,
- x, y, width, height);
+ copy_tex_sub_image(ctx, 2, texImage, xoffset, yoffset, 0,
+ rb, x, y, width, height);
}
void
-_mesa_meta_CopyTexSubImage3D(struct gl_context *ctx, GLenum target, GLint level,
+_mesa_meta_CopyTexSubImage3D(struct gl_context *ctx,
+ struct gl_texture_image *texImage,
GLint xoffset, GLint yoffset, GLint zoffset,
+ struct gl_renderbuffer *rb,
GLint x, GLint y,
GLsizei width, GLsizei height)
{
- copy_tex_sub_image(ctx, 3, target, level, xoffset, yoffset, zoffset,
- x, y, width, height);
+ copy_tex_sub_image(ctx, 3, texImage, xoffset, yoffset, zoffset,
+ rb, x, y, width, height);
}
diff --git a/mesalib/src/mesa/drivers/common/meta.h b/mesalib/src/mesa/drivers/common/meta.h
index d13796ebe..de039b575 100644
--- a/mesalib/src/mesa/drivers/common/meta.h
+++ b/mesalib/src/mesa/drivers/common/meta.h
@@ -111,19 +111,25 @@ _mesa_meta_GenerateMipmap(struct gl_context *ctx, GLenum target,
struct gl_texture_object *texObj);
extern void
-_mesa_meta_CopyTexSubImage1D(struct gl_context *ctx, GLenum target, GLint level,
+_mesa_meta_CopyTexSubImage1D(struct gl_context *ctx,
+ struct gl_texture_image *texImage,
GLint xoffset,
+ struct gl_renderbuffer *rb,
GLint x, GLint y, GLsizei width);
extern void
-_mesa_meta_CopyTexSubImage2D(struct gl_context *ctx, GLenum target, GLint level,
+_mesa_meta_CopyTexSubImage2D(struct gl_context *ctx,
+ struct gl_texture_image *texImage,
GLint xoffset, GLint yoffset,
+ struct gl_renderbuffer *rb,
GLint x, GLint y,
GLsizei width, GLsizei height);
extern void
-_mesa_meta_CopyTexSubImage3D(struct gl_context *ctx, GLenum target, GLint level,
+_mesa_meta_CopyTexSubImage3D(struct gl_context *ctx,
+ struct gl_texture_image *texImage,
GLint xoffset, GLint yoffset, GLint zoffset,
+ struct gl_renderbuffer *rb,
GLint x, GLint y,
GLsizei width, GLsizei height);