From 6890b0698254051f366e0083eee40ed42613c58c Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 17:54:47 -0800 Subject: st/mesa: Remove unnecessary headers from st_gen_mipmap.c. --- src/mesa/state_tracker/st_gen_mipmap.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_gen_mipmap.c b/src/mesa/state_tracker/st_gen_mipmap.c index 2d404d5..cffb880 100644 --- a/src/mesa/state_tracker/st_gen_mipmap.c +++ b/src/mesa/state_tracker/st_gen_mipmap.c @@ -44,9 +44,7 @@ #include "st_debug.h" #include "st_context.h" -#include "st_draw.h" #include "st_gen_mipmap.h" -#include "st_program.h" #include "st_texture.h" #include "st_cb_texture.h" #include "st_inlines.h" -- cgit v1.1 From eaedc1bb3e651884a184f520bd81aa12c569c29b Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 18:10:06 -0800 Subject: st/mesa: Remove unnecessary headers from st_framebuffer.c. --- src/mesa/state_tracker/st_framebuffer.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_framebuffer.c b/src/mesa/state_tracker/st_framebuffer.c index a5d1ae3..835142e 100644 --- a/src/mesa/state_tracker/st_framebuffer.c +++ b/src/mesa/state_tracker/st_framebuffer.c @@ -30,15 +30,11 @@ #include "main/buffers.h" #include "main/context.h" #include "main/framebuffer.h" -#include "main/matrix.h" #include "main/renderbuffer.h" -#include "main/scissor.h" -#include "main/viewport.h" #include "st_context.h" #include "st_cb_fbo.h" #include "st_public.h" #include "pipe/p_defines.h" -#include "pipe/p_context.h" struct st_framebuffer * -- cgit v1.1 From 8a8a27b01a60ba80608f736c46da82747c215586 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 18:19:39 -0800 Subject: st/mesa: Remove unnecessary header from st_format.c. --- src/mesa/state_tracker/st_format.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_format.c b/src/mesa/state_tracker/st_format.c index 2785728..6b1c499 100644 --- a/src/mesa/state_tracker/st_format.c +++ b/src/mesa/state_tracker/st_format.c @@ -35,7 +35,6 @@ #include "main/imports.h" #include "main/context.h" #include "main/texstore.h" -#include "main/texformat.h" #include "main/enums.h" #include "main/macros.h" -- cgit v1.1 From 9e7778d7aa9bd079a4a5d3d1656d75d6e4978a1d Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 18:34:59 -0800 Subject: st/mesa: Remove unnecessary header from st_extensions.c. --- src/mesa/state_tracker/st_extensions.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c index 57fe72d..54d7c61 100644 --- a/src/mesa/state_tracker/st_extensions.c +++ b/src/mesa/state_tracker/st_extensions.c @@ -28,7 +28,6 @@ #include "main/imports.h" #include "main/context.h" -#include "main/extensions.h" #include "main/macros.h" #include "pipe/p_context.h" -- cgit v1.1 From 604e9ec2c436b8bc595faf97db1a4f57fe5368f2 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 18:46:51 -0800 Subject: st/mesa: Remove unnecessary header from st_draw_feedback.c. --- src/mesa/state_tracker/st_draw_feedback.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_draw_feedback.c b/src/mesa/state_tracker/st_draw_feedback.c index b2d682e..0660a2c 100644 --- a/src/mesa/state_tracker/st_draw_feedback.c +++ b/src/mesa/state_tracker/st_draw_feedback.c @@ -28,7 +28,6 @@ #include "main/imports.h" #include "main/image.h" #include "main/macros.h" -#include "shader/prog_uniform.h" #include "vbo/vbo.h" -- cgit v1.1 From 53c6c384125726ad4e528d57272be95f197fb630 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 18:53:51 -0800 Subject: st/mesa: Remove unnecessary headers from st_context.c. --- src/mesa/state_tracker/st_context.c | 6 ------ 1 file changed, 6 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c index d18a25a..6c463ca 100644 --- a/src/mesa/state_tracker/st_context.c +++ b/src/mesa/state_tracker/st_context.c @@ -27,11 +27,6 @@ #include "main/imports.h" #include "main/context.h" -#include "main/extensions.h" -#include "main/matrix.h" -#include "main/buffers.h" -#include "main/scissor.h" -#include "main/viewport.h" #include "vbo/vbo.h" #include "shader/shader_api.h" #include "glapi/glapi.h" @@ -68,7 +63,6 @@ #include "st_program.h" #include "pipe/p_context.h" #include "draw/draw_context.h" -#include "cso_cache/cso_cache.h" #include "cso_cache/cso_context.h" -- cgit v1.1 From 4f8baf7dce47b1295292bf3d153d1e93ea83e6a1 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 19:00:27 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_viewport.c. --- src/mesa/state_tracker/st_cb_viewport.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_viewport.c b/src/mesa/state_tracker/st_cb_viewport.c index 75b0a21..9450b3a 100644 --- a/src/mesa/state_tracker/st_cb_viewport.c +++ b/src/mesa/state_tracker/st_cb_viewport.c @@ -27,11 +27,9 @@ #include "main/glheader.h" #include "st_context.h" -#include "st_public.h" #include "st_cb_viewport.h" #include "pipe/p_context.h" -#include "pipe/p_inlines.h" #include "pipe/p_state.h" #include "pipe/p_defines.h" #include "pipe/internal/p_winsys_screen.h" -- cgit v1.1 From 644572a3723bc5167fb71f15e0bbfec3f999be9b Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 22:27:13 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_texture.c. --- src/mesa/state_tracker/st_cb_texture.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c index cb9106c..e9c30cb 100644 --- a/src/mesa/state_tracker/st_cb_texture.c +++ b/src/mesa/state_tracker/st_cb_texture.c @@ -36,10 +36,8 @@ #include "main/imports.h" #include "main/macros.h" #include "main/mipmap.h" -#include "main/pixel.h" #include "main/texcompress.h" #include "main/texfetch.h" -#include "main/texformat.h" #include "main/texgetimage.h" #include "main/teximage.h" #include "main/texobj.h" -- cgit v1.1 From cde041cd1320849be70dc8571da1460b8b913f14 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 22:30:00 -0800 Subject: st/mesa: Remove unnecessary header from st_cb_strings.c. --- src/mesa/state_tracker/st_cb_strings.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_strings.c b/src/mesa/state_tracker/st_cb_strings.c index bb931f1..f22c536 100644 --- a/src/mesa/state_tracker/st_cb_strings.c +++ b/src/mesa/state_tracker/st_cb_strings.c @@ -33,7 +33,6 @@ #include "main/glheader.h" #include "main/macros.h" -#include "main/version.h" #include "pipe/p_context.h" #include "pipe/p_screen.h" #include "st_context.h" -- cgit v1.1 From 9c2ef74a76fc3707ca428dca2ca401da790cb915 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 23:03:37 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_readpixels.c. --- src/mesa/state_tracker/st_cb_readpixels.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_readpixels.c b/src/mesa/state_tracker/st_cb_readpixels.c index 772bb3b..be98195 100644 --- a/src/mesa/state_tracker/st_cb_readpixels.c +++ b/src/mesa/state_tracker/st_cb_readpixels.c @@ -45,10 +45,8 @@ #include "st_debug.h" #include "st_context.h" -#include "st_cb_bitmap.h" #include "st_cb_readpixels.h" #include "st_cb_fbo.h" -#include "st_format.h" #include "st_public.h" #include "st_texture.h" #include "st_inlines.h" -- cgit v1.1 From 79a5a2839029eef23f4c238fec6878b5f87ceec3 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 14 Jan 2010 23:05:42 -0800 Subject: st/mesa: Remove unnecessary header from st_cb_rasterpos.c. --- src/mesa/state_tracker/st_cb_rasterpos.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_rasterpos.c b/src/mesa/state_tracker/st_cb_rasterpos.c index d82b2a2..42a1377 100644 --- a/src/mesa/state_tracker/st_cb_rasterpos.c +++ b/src/mesa/state_tracker/st_cb_rasterpos.c @@ -47,7 +47,6 @@ #include "st_draw.h" #include "draw/draw_context.h" #include "draw/draw_pipe.h" -#include "shader/prog_instruction.h" #include "vbo/vbo.h" -- cgit v1.1 From 73856817973caab283427c52152672f524c49a07 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 15 Jan 2010 14:19:23 -0700 Subject: swrast: fix broken _swrast_depth_clamp_span() The integer Z clamping range depends on the number of bits in the Z buffer because that's the scale factor used when we transform NDC coords by the viewport/depth range. Fixes fd.o bug #25972 but only for Z buffers up to a depth of 30 bits. Beyond that we get into messy integer overflow issues and things fall apart. --- src/mesa/swrast/s_depth.c | 41 +++++++++++++++++++++++++++-------------- 1 file changed, 27 insertions(+), 14 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/swrast/s_depth.c b/src/mesa/swrast/s_depth.c index 0b6bb7e..ac5dae2 100644 --- a/src/mesa/swrast/s_depth.c +++ b/src/mesa/swrast/s_depth.c @@ -497,17 +497,24 @@ depth_test_span32( GLcontext *ctx, GLuint n, return passed; } -/* Apply ARB_depth_clamp to span of fragments. */ + + +/** + * Clamp fragment Z values to the depth near/far range (glDepthRange()). + * This is used when GL_ARB_depth_clamp/GL_DEPTH_CLAMP is turned on. + * In that case, vertexes are not clipped against the near/far planes + * so rasterization will produce fragment Z values outside the usual + * [0,1] range. + */ void _swrast_depth_clamp_span( GLcontext *ctx, SWspan *span ) { struct gl_framebuffer *fb = ctx->DrawBuffer; - struct gl_renderbuffer *rb = fb->_DepthBuffer; const GLuint count = span->end; - GLuint *zValues = span->array->z; - GLuint min, max; + GLint *zValues = (GLint *) span->array->z; /* sign change */ + GLint min, max; GLfloat min_f, max_f; - int i; + GLuint i; if (ctx->Viewport.Near < ctx->Viewport.Far) { min_f = ctx->Viewport.Near; @@ -517,15 +524,21 @@ _swrast_depth_clamp_span( GLcontext *ctx, SWspan *span ) max_f = ctx->Viewport.Near; } - if (rb->DataType == GL_UNSIGNED_SHORT) { - CLAMPED_FLOAT_TO_USHORT(min, min_f); - CLAMPED_FLOAT_TO_USHORT(max, max_f); - } else { - assert(rb->DataType == GL_UNSIGNED_INT); - min = FLOAT_TO_UINT(min_f); - max = FLOAT_TO_UINT(max_f); - } - + /* Convert floating point values in [0,1] to device Z coordinates in + * [0, DepthMax]. + * ex: If the the Z buffer has 24 bits, DepthMax = 0xffffff. + * + * XXX this all falls apart if we have 31 or more bits of Z because + * the triangle rasterization code produces unsigned Z values. Negative + * vertex Z values come out as large fragment Z uints. + */ + min = (GLint) (min_f * fb->_DepthMaxF); + max = (GLint) (max_f * fb->_DepthMaxF); + if (max < 0) + max = 0x7fffffff; /* catch over flow for 30-bit z */ + + /* Note that we do the comparisons here using signed integers. + */ for (i = 0; i < count; i++) { if (zValues[i] < min) zValues[i] = min; -- cgit v1.1 From 2c5aa02e2086f5e79630cdffec804a3e9de0d966 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 15 Jan 2010 14:25:30 -0700 Subject: swrast: add missing call to _swrast_depth_bounds_test() We were calling this from the CI span function, but not the RGBA span function. I don't know of a test program for the GL_EXT_depth_bounds_test extension... --- src/mesa/swrast/s_span.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/swrast/s_span.c b/src/mesa/swrast/s_span.c index 1a51d4f..07248c7 100644 --- a/src/mesa/swrast/s_span.c +++ b/src/mesa/swrast/s_span.c @@ -1316,6 +1316,13 @@ _swrast_write_rgba_span( GLcontext *ctx, SWspan *span) ASSERT(span->end <= MAX_WIDTH); + /* Depth bounds test */ + if (ctx->Depth.BoundsTest && fb->Visual.depthBits > 0) { + if (!_swrast_depth_bounds_test(ctx, span)) { + return; + } + } + #ifdef DEBUG /* Make sure all fragments are within window bounds */ if (span->arrayMask & SPAN_XY) { -- cgit v1.1 From fbda223893301cc10182fb12c91493c959e3fe8b Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Fri, 15 Jan 2010 16:27:28 -0800 Subject: st/mesa: Remove unnecessary header from st_cb_queryobj.c. --- src/mesa/state_tracker/st_cb_queryobj.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_queryobj.c b/src/mesa/state_tracker/st_cb_queryobj.c index dcf4c38..5ef7765 100644 --- a/src/mesa/state_tracker/st_cb_queryobj.c +++ b/src/mesa/state_tracker/st_cb_queryobj.c @@ -41,7 +41,6 @@ #include "pipe/p_defines.h" #include "st_context.h" #include "st_cb_queryobj.h" -#include "st_public.h" struct st_query_object -- cgit v1.1 From 2d2d8900485ac9f462fccdb0a817f7fc598b95f8 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Fri, 15 Jan 2010 16:28:56 -0800 Subject: st/mesa: Remove unnecessary header from st_cb_program.c. --- src/mesa/state_tracker/st_cb_program.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_program.c b/src/mesa/state_tracker/st_cb_program.c index b2d5c39..22cb61c 100644 --- a/src/mesa/state_tracker/st_cb_program.c +++ b/src/mesa/state_tracker/st_cb_program.c @@ -36,7 +36,6 @@ #include "shader/prog_instruction.h" #include "shader/prog_parameter.h" #include "shader/program.h" -#include "shader/programopt.h" #include "shader/shader_api.h" #include "cso_cache/cso_context.h" -- cgit v1.1 From a9f625543169e0919c507966889d82ecf9db4c5f Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Fri, 15 Jan 2010 18:20:56 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_feedback.c. --- src/mesa/state_tracker/st_cb_feedback.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_feedback.c b/src/mesa/state_tracker/st_cb_feedback.c index 93f7145..17261f8 100644 --- a/src/mesa/state_tracker/st_cb_feedback.c +++ b/src/mesa/state_tracker/st_cb_feedback.c @@ -45,14 +45,11 @@ #include "vbo/vbo.h" #include "st_context.h" -#include "st_atom.h" #include "st_draw.h" #include "st_cb_feedback.h" -#include "st_cb_bufferobjects.h" #include "pipe/p_context.h" #include "pipe/p_defines.h" -#include "cso_cache/cso_cache.h" #include "draw/draw_context.h" #include "draw/draw_pipe.h" -- cgit v1.1 From 56cd5806e89fea9598e296ce656dfe550bf2b96e Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Fri, 15 Jan 2010 18:24:12 -0800 Subject: st/mesa: Remove unnecessary header from st_cb_fbo.c. --- src/mesa/state_tracker/st_cb_fbo.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_fbo.c b/src/mesa/state_tracker/st_cb_fbo.c index 65ce12c..9cdff53 100644 --- a/src/mesa/state_tracker/st_cb_fbo.c +++ b/src/mesa/state_tracker/st_cb_fbo.c @@ -44,7 +44,6 @@ #include "pipe/p_screen.h" #include "st_context.h" #include "st_cb_fbo.h" -#include "st_cb_texture.h" #include "st_format.h" #include "st_public.h" #include "st_texture.h" -- cgit v1.1 From 114ab07aee9cc3f007a22ae4642e5c4302900d2f Mon Sep 17 00:00:00 2001 From: Alex Deucher Date: Fri, 15 Jan 2010 20:53:53 -0500 Subject: r600: fix typo in SQ setup --- src/mesa/drivers/dri/r600/r700_state.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/r600/r700_state.c b/src/mesa/drivers/dri/r600/r700_state.c index 16b05d5..82bd48b 100644 --- a/src/mesa/drivers/dri/r600/r700_state.c +++ b/src/mesa/drivers/dri/r600/r700_state.c @@ -1576,9 +1576,9 @@ static void r700InitSQConfig(GLcontext * ctx) SETbit(r700->sq_config.SQ_CONFIG.u32All, DX9_CONSTS_bit); SETbit(r700->sq_config.SQ_CONFIG.u32All, ALU_INST_PREFER_VECTOR_bit); SETfield(r700->sq_config.SQ_CONFIG.u32All, ps_prio, PS_PRIO_shift, PS_PRIO_mask); - SETfield(r700->sq_config.SQ_CONFIG.u32All, ps_prio, VS_PRIO_shift, VS_PRIO_mask); - SETfield(r700->sq_config.SQ_CONFIG.u32All, ps_prio, GS_PRIO_shift, GS_PRIO_mask); - SETfield(r700->sq_config.SQ_CONFIG.u32All, ps_prio, ES_PRIO_shift, ES_PRIO_mask); + SETfield(r700->sq_config.SQ_CONFIG.u32All, vs_prio, VS_PRIO_shift, VS_PRIO_mask); + SETfield(r700->sq_config.SQ_CONFIG.u32All, gs_prio, GS_PRIO_shift, GS_PRIO_mask); + SETfield(r700->sq_config.SQ_CONFIG.u32All, es_prio, ES_PRIO_shift, ES_PRIO_mask); r700->sq_config.SQ_GPR_RESOURCE_MGMT_1.u32All = 0; SETfield(r700->sq_config.SQ_GPR_RESOURCE_MGMT_1.u32All, num_ps_gprs, NUM_PS_GPRS_shift, NUM_PS_GPRS_mask); -- cgit v1.1 From 81eed59a2c6add1d1514574bf7c3b29b1bf6e8c0 Mon Sep 17 00:00:00 2001 From: Alex Deucher Date: Fri, 15 Jan 2010 20:54:12 -0500 Subject: r600: set tiling correctly for texturing from depth buffer --- src/mesa/drivers/dri/r600/r600_texstate.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/r600/r600_texstate.c b/src/mesa/drivers/dri/r600/r600_texstate.c index fb5abdc..61c9730 100644 --- a/src/mesa/drivers/dri/r600/r600_texstate.c +++ b/src/mesa/drivers/dri/r600/r600_texstate.c @@ -85,6 +85,7 @@ static GLboolean r600GetTexFormat(struct gl_texture_object *tObj, gl_format mesa CLEARfield(t->SQ_TEX_RESOURCE4, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_mask); CLEARfield(t->SQ_TEX_RESOURCE4, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_mask); CLEARfield(t->SQ_TEX_RESOURCE4, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_mask); + CLEARbit(t->SQ_TEX_RESOURCE4, SQ_TEX_RESOURCE_WORD4_0__FORCE_DEGAMMA_bit); SETfield(t->SQ_TEX_RESOURCE4, SQ_FORMAT_COMP_UNSIGNED, FORMAT_COMP_X_shift, FORMAT_COMP_X_mask); @@ -95,6 +96,11 @@ static GLboolean r600GetTexFormat(struct gl_texture_object *tObj, gl_format mesa SETfield(t->SQ_TEX_RESOURCE4, SQ_FORMAT_COMP_UNSIGNED, FORMAT_COMP_W_shift, FORMAT_COMP_W_mask); + CLEARbit(t->SQ_TEX_RESOURCE0, TILE_TYPE_bit); + SETfield(t->SQ_TEX_RESOURCE0, ARRAY_LINEAR_GENERAL, + SQ_TEX_RESOURCE_WORD0_0__TILE_MODE_shift, + SQ_TEX_RESOURCE_WORD0_0__TILE_MODE_mask); + switch (mesa_format) /* This is mesa format. */ { case MESA_FORMAT_RGBA8888: @@ -515,6 +521,10 @@ static GLboolean r600GetTexFormat(struct gl_texture_object *tObj, gl_format mesa case MESA_FORMAT_Z24_S8: case MESA_FORMAT_Z32: case MESA_FORMAT_S8: + SETbit(t->SQ_TEX_RESOURCE0, TILE_TYPE_bit); + SETfield(t->SQ_TEX_RESOURCE0, ARRAY_1D_TILED_THIN1, + SQ_TEX_RESOURCE_WORD0_0__TILE_MODE_shift, + SQ_TEX_RESOURCE_WORD0_0__TILE_MODE_mask); switch (mesa_format) { case MESA_FORMAT_Z16: SETfield(t->SQ_TEX_RESOURCE1, FMT_16, -- cgit v1.1 From adcde22952bb94dd73785bf5971a317e929fbec9 Mon Sep 17 00:00:00 2001 From: Alex Deucher Date: Fri, 15 Jan 2010 22:23:40 -0500 Subject: r600: fill in some missing XRGB tex formats --- src/mesa/drivers/dri/r600/r600_texstate.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/r600/r600_texstate.c b/src/mesa/drivers/dri/r600/r600_texstate.c index 61c9730..8fdca0b 100644 --- a/src/mesa/drivers/dri/r600/r600_texstate.c +++ b/src/mesa/drivers/dri/r600/r600_texstate.c @@ -164,6 +164,32 @@ static GLboolean r600GetTexFormat(struct gl_texture_object *tObj, gl_format mesa SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_W, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_mask); break; + case MESA_FORMAT_XRGB8888: + SETfield(t->SQ_TEX_RESOURCE1, FMT_8_8_8_8, + SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_shift, SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_mask); + + SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_Z, + SQ_TEX_RESOURCE_WORD4_0__DST_SEL_X_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_X_mask); + SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_Y, + SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_mask); + SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_X, + SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_mask); + SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_1, + SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_mask); + break; + case MESA_FORMAT_XRGB8888_REV: + SETfield(t->SQ_TEX_RESOURCE1, FMT_8_8_8_8, + SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_shift, SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_mask); + + SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_1, + SQ_TEX_RESOURCE_WORD4_0__DST_SEL_X_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_X_mask); + SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_Z, + SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_mask); + SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_W, + SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_mask); + SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_X, + SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_mask); + break; case MESA_FORMAT_ARGB8888_REV: SETfield(t->SQ_TEX_RESOURCE1, FMT_8_8_8_8, SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_shift, SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_mask); -- cgit v1.1 From 668d871d95e74862953c90e04e4f04ed02526421 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Fri, 15 Jan 2010 22:55:47 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_drawpixels.c. --- src/mesa/state_tracker/st_cb_drawpixels.c | 5 ----- 1 file changed, 5 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_drawpixels.c b/src/mesa/state_tracker/st_cb_drawpixels.c index 1d33e81..fe9a11d 100644 --- a/src/mesa/state_tracker/st_cb_drawpixels.c +++ b/src/mesa/state_tracker/st_cb_drawpixels.c @@ -36,24 +36,19 @@ #include "main/macros.h" #include "main/texformat.h" #include "main/texstore.h" -#include "main/state.h" #include "shader/program.h" -#include "shader/prog_parameter.h" #include "shader/prog_print.h" #include "st_debug.h" #include "st_context.h" #include "st_atom.h" #include "st_atom_constbuf.h" -#include "st_draw.h" #include "st_program.h" #include "st_cb_drawpixels.h" #include "st_cb_readpixels.h" #include "st_cb_fbo.h" -#include "st_cb_texture.h" #include "st_draw.h" #include "st_format.h" -#include "st_mesa_to_tgsi.h" #include "st_texture.h" #include "st_inlines.h" -- cgit v1.1 From 6906bf08cc0ca43cd4fd1a2c6f841ad87c232ece Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Fri, 15 Jan 2010 23:02:07 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_clear.c. --- src/mesa/state_tracker/st_cb_clear.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_clear.c b/src/mesa/state_tracker/st_cb_clear.c index e83b6c9..7c0d74a 100644 --- a/src/mesa/state_tracker/st_cb_clear.c +++ b/src/mesa/state_tracker/st_cb_clear.c @@ -42,17 +42,14 @@ #include "st_cb_accum.h" #include "st_cb_clear.h" #include "st_cb_fbo.h" -#include "st_draw.h" #include "st_program.h" #include "st_public.h" -#include "st_mesa_to_tgsi.h" #include "st_inlines.h" #include "pipe/p_context.h" #include "pipe/p_inlines.h" #include "pipe/p_state.h" #include "pipe/p_defines.h" -#include "util/u_pack_color.h" #include "util/u_simple_shaders.h" #include "util/u_draw_quad.h" -- cgit v1.1 From cc770c8409b31dd2dff7dd80cf441f90f191a048 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Fri, 15 Jan 2010 23:17:00 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_blit.c. --- src/mesa/state_tracker/st_cb_blit.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_blit.c b/src/mesa/state_tracker/st_cb_blit.c index 563615e..65aa2a2 100644 --- a/src/mesa/state_tracker/st_cb_blit.c +++ b/src/mesa/state_tracker/st_cb_blit.c @@ -33,14 +33,10 @@ #include "main/imports.h" #include "main/image.h" #include "main/macros.h" -#include "main/texformat.h" #include "shader/program.h" -#include "shader/prog_parameter.h" -#include "shader/prog_print.h" #include "st_context.h" #include "st_texture.h" -#include "st_program.h" #include "st_cb_blit.h" #include "st_cb_fbo.h" -- cgit v1.1 From e1d4781cd49cd6df2fed171ad6e034f576f219a8 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 00:08:54 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_bitmap.c. --- src/mesa/state_tracker/st_cb_bitmap.c | 5 ----- 1 file changed, 5 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_bitmap.c b/src/mesa/state_tracker/st_cb_bitmap.c index 1960d17..4b85bf2 100644 --- a/src/mesa/state_tracker/st_cb_bitmap.c +++ b/src/mesa/state_tracker/st_cb_bitmap.c @@ -34,9 +34,7 @@ #include "main/image.h" #include "main/bufferobj.h" #include "main/macros.h" -#include "main/texformat.h" #include "shader/program.h" -#include "shader/prog_parameter.h" #include "shader/prog_print.h" #include "st_context.h" @@ -44,15 +42,12 @@ #include "st_atom_constbuf.h" #include "st_program.h" #include "st_cb_bitmap.h" -#include "st_cb_program.h" -#include "st_mesa_to_tgsi.h" #include "st_texture.h" #include "st_inlines.h" #include "pipe/p_context.h" #include "pipe/p_defines.h" #include "pipe/p_inlines.h" -#include "util/u_tile.h" #include "util/u_draw_quad.h" #include "util/u_simple_shaders.h" #include "shader/prog_instruction.h" -- cgit v1.1 From cc2f2268f5fcfbc7d942fab82a1bb00ac496fc23 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 00:30:25 -0800 Subject: st/mesa: Remove unnecessary headers from st_cb_accum.c. --- src/mesa/state_tracker/st_cb_accum.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_accum.c b/src/mesa/state_tracker/st_cb_accum.c index a6b9765..6625dfb 100644 --- a/src/mesa/state_tracker/st_cb_accum.c +++ b/src/mesa/state_tracker/st_cb_accum.c @@ -38,9 +38,7 @@ #include "st_context.h" #include "st_cb_accum.h" #include "st_cb_fbo.h" -#include "st_draw.h" #include "st_public.h" -#include "st_format.h" #include "st_texture.h" #include "st_inlines.h" #include "pipe/p_context.h" -- cgit v1.1 From 227fc5a3083290bf8c494f1f08e911eed6e4cfcc Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 00:36:31 -0800 Subject: st/mesa: Remove unnecessary header from st_atom_shader.c. --- src/mesa/state_tracker/st_atom_shader.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_atom_shader.c b/src/mesa/state_tracker/st_atom_shader.c index 9208f3f..9fad58a 100644 --- a/src/mesa/state_tracker/st_atom_shader.c +++ b/src/mesa/state_tracker/st_atom_shader.c @@ -53,7 +53,6 @@ #include "st_atom.h" #include "st_program.h" #include "st_atom_shader.h" -#include "st_mesa_to_tgsi.h" /** -- cgit v1.1 From bc639f291bd6127730845f9e6208e48e51cb83ff Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 00:45:36 -0800 Subject: st/mesa: Remove unnecessary header from st_atom_sampler.c. --- src/mesa/state_tracker/st_atom_sampler.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_atom_sampler.c b/src/mesa/state_tracker/st_atom_sampler.c index 6611956..7b1734c 100644 --- a/src/mesa/state_tracker/st_atom_sampler.c +++ b/src/mesa/state_tracker/st_atom_sampler.c @@ -37,7 +37,6 @@ #include "st_context.h" #include "st_cb_texture.h" #include "st_atom.h" -#include "st_program.h" #include "pipe/p_context.h" #include "pipe/p_defines.h" -- cgit v1.1 From 3eb85bf7d941aff1c72e0e0e2d8af18b8b7e496a Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 00:52:34 -0800 Subject: st/mesa: Remove unnecessary header from st_atom_pixeltransfer.c. --- src/mesa/state_tracker/st_atom_pixeltransfer.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_atom_pixeltransfer.c b/src/mesa/state_tracker/st_atom_pixeltransfer.c index babfcc8..8300300 100644 --- a/src/mesa/state_tracker/st_atom_pixeltransfer.c +++ b/src/mesa/state_tracker/st_atom_pixeltransfer.c @@ -43,7 +43,6 @@ #include "st_context.h" #include "st_format.h" -#include "st_program.h" #include "st_texture.h" #include "st_inlines.h" -- cgit v1.1 From 533b6e8deb3443719bd82c57c79ec106e5473589 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 01:39:04 -0800 Subject: st/mesa: Remove unnecessary header from st_atom_framebuffer.c. --- src/mesa/state_tracker/st_atom_framebuffer.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_atom_framebuffer.c b/src/mesa/state_tracker/st_atom_framebuffer.c index e18c0f6..1e18497 100644 --- a/src/mesa/state_tracker/st_atom_framebuffer.c +++ b/src/mesa/state_tracker/st_atom_framebuffer.c @@ -37,7 +37,6 @@ #include "st_public.h" #include "st_texture.h" #include "pipe/p_context.h" -#include "pipe/p_inlines.h" #include "cso_cache/cso_context.h" #include "util/u_rect.h" -- cgit v1.1 From 10bd931949d8dd3c63fe8bcc00899875d7dde105 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 01:50:08 -0800 Subject: glsl: Remove unnecessary header from slang_log.c. --- src/mesa/shader/slang/slang_log.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/slang/slang_log.c b/src/mesa/shader/slang/slang_log.c index d7d2b4f..4f6b854 100644 --- a/src/mesa/shader/slang/slang_log.c +++ b/src/mesa/shader/slang/slang_log.c @@ -24,7 +24,6 @@ */ #include "main/imports.h" -#include "main/context.h" #include "slang_log.h" #include "slang_utility.h" -- cgit v1.1 From 1d3bdc20908f860316e0bfeaa54dc8fa6d344d0c Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 02:02:49 -0800 Subject: glsl: Remove unnecessary header from slang_link.c. --- src/mesa/shader/slang/slang_link.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/slang/slang_link.c b/src/mesa/shader/slang/slang_link.c index 0a2bc49..e9f1ee4 100644 --- a/src/mesa/shader/slang/slang_link.c +++ b/src/mesa/shader/slang/slang_link.c @@ -31,7 +31,6 @@ #include "main/imports.h" #include "main/context.h" -#include "main/hash.h" #include "main/macros.h" #include "shader/program.h" #include "shader/prog_instruction.h" -- cgit v1.1 From 535084996b050a75f230dc10c15bd6239e2aa08a Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 02:16:24 -0800 Subject: glsl: Remove unnecessary headers from slang_compile.c. --- src/mesa/shader/slang/slang_compile.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/slang/slang_compile.c b/src/mesa/shader/slang/slang_compile.c index 57e3555..6a91d0f 100644 --- a/src/mesa/shader/slang/slang_compile.c +++ b/src/mesa/shader/slang/slang_compile.c @@ -40,14 +40,11 @@ #include "slang_compile.h" #include "slang_preprocess.h" #include "slang_storage.h" -#include "slang_emit.h" #include "slang_log.h" #include "slang_mem.h" #include "slang_vartable.h" #include "slang_simplify.h" -#include "slang_print.h" - /* * This is a straightforward implementation of the slang front-end * compiler. Lots of error-checking functionality is missing but -- cgit v1.1 From 59db91e2eec1e755de71deba87227a647845b1c9 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 02:20:51 -0800 Subject: glsl: Remove unnecessary header from slang_builtin.c. --- src/mesa/shader/slang/slang_builtin.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/slang/slang_builtin.c b/src/mesa/shader/slang/slang_builtin.c index e580950..0a9f0b9 100644 --- a/src/mesa/shader/slang/slang_builtin.c +++ b/src/mesa/shader/slang/slang_builtin.c @@ -36,7 +36,6 @@ #include "shader/prog_parameter.h" #include "shader/prog_statevars.h" #include "shader/slang/slang_ir.h" -#include "shader/slang/slang_emit.h" #include "shader/slang/slang_builtin.h" -- cgit v1.1 From 89950fbe24a351fbb10330b6695d653c9f2d6887 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 13:29:15 -0800 Subject: st/mesa: Remove unnecessary header from st_cb_drawpixels.c. --- src/mesa/state_tracker/st_cb_drawpixels.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_drawpixels.c b/src/mesa/state_tracker/st_cb_drawpixels.c index fe9a11d..23db3f1 100644 --- a/src/mesa/state_tracker/st_cb_drawpixels.c +++ b/src/mesa/state_tracker/st_cb_drawpixels.c @@ -47,7 +47,6 @@ #include "st_cb_drawpixels.h" #include "st_cb_readpixels.h" #include "st_cb_fbo.h" -#include "st_draw.h" #include "st_format.h" #include "st_texture.h" #include "st_inlines.h" -- cgit v1.1 From 1f7762f62bb082fceb579434a4ca78f13d78da49 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 15:00:29 -0800 Subject: glsl: Remove unnecessary header from slang_emit.c. --- src/mesa/shader/slang/slang_emit.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/slang/slang_emit.c b/src/mesa/shader/slang/slang_emit.c index c0e4b27..f812a3f 100644 --- a/src/mesa/shader/slang/slang_emit.c +++ b/src/mesa/shader/slang/slang_emit.c @@ -38,7 +38,6 @@ #include "main/imports.h" #include "main/context.h" -#include "main/macros.h" #include "shader/program.h" #include "shader/prog_instruction.h" #include "shader/prog_parameter.h" -- cgit v1.1 From 0d622420826ccbf35eed80b663994ffb918dc9a1 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 15:35:56 -0800 Subject: glsl: Remove unnecessary headers from shader_api.c. --- src/mesa/shader/shader_api.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/shader_api.c b/src/mesa/shader/shader_api.c index 453cd39..e522d70 100644 --- a/src/mesa/shader/shader_api.c +++ b/src/mesa/shader/shader_api.c @@ -39,10 +39,8 @@ #include "main/glheader.h" #include "main/context.h" #include "main/hash.h" -#include "main/macros.h" #include "shader/program.h" #include "shader/prog_parameter.h" -#include "shader/prog_print.h" #include "shader/prog_statevars.h" #include "shader/prog_uniform.h" #include "shader/shader_api.h" -- cgit v1.1 From 148498d8cc897d70c54e9ddc09e957a855a597d4 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 15:51:52 -0800 Subject: glsl: Remove unnecessary header from prog_statevars.c. --- src/mesa/shader/prog_statevars.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/prog_statevars.c b/src/mesa/shader/prog_statevars.c index 058d4bb..3a446fd 100644 --- a/src/mesa/shader/prog_statevars.c +++ b/src/mesa/shader/prog_statevars.c @@ -31,7 +31,6 @@ #include "main/glheader.h" #include "main/context.h" -#include "main/hash.h" #include "main/imports.h" #include "main/macros.h" #include "main/mtypes.h" -- cgit v1.1 From 5a4d5b694c0fa92b613bd73138d32f68b966a56c Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 16:06:58 -0800 Subject: glsl: Remove unnecessary header from prog_execute.c. --- src/mesa/shader/prog_execute.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/prog_execute.c b/src/mesa/shader/prog_execute.c index 192d39a..1ef801a 100644 --- a/src/mesa/shader/prog_execute.c +++ b/src/mesa/shader/prog_execute.c @@ -38,7 +38,6 @@ #include "main/glheader.h" #include "main/colormac.h" #include "main/context.h" -#include "program.h" #include "prog_execute.h" #include "prog_instruction.h" #include "prog_parameter.h" -- cgit v1.1 From 97fc7ae69f4e620a5b14a3dbe574c4810741293c Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 16:15:37 -0800 Subject: mesa: Remove unnecessary header from nvvertparse.c. --- src/mesa/shader/nvvertparse.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/nvvertparse.c b/src/mesa/shader/nvvertparse.c index 8574016..baff765 100644 --- a/src/mesa/shader/nvvertparse.c +++ b/src/mesa/shader/nvvertparse.c @@ -40,7 +40,6 @@ #include "main/glheader.h" #include "main/context.h" #include "main/imports.h" -#include "main/macros.h" #include "nvprogram.h" #include "nvvertparse.h" #include "prog_instruction.h" -- cgit v1.1 From 97e44cde17ce508fd3708d391f7701e1919352fb Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 16 Jan 2010 23:41:05 -0800 Subject: mesa: Remove unnecessary headers from arbprogparse.c. --- src/mesa/shader/arbprogparse.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/shader/arbprogparse.c b/src/mesa/shader/arbprogparse.c index dd732b6..a33f510 100644 --- a/src/mesa/shader/arbprogparse.c +++ b/src/mesa/shader/arbprogparse.c @@ -54,11 +54,8 @@ having three separate program parameter arrays. #include "main/glheader.h" #include "main/imports.h" #include "main/context.h" -#include "main/macros.h" #include "main/mtypes.h" -#include "shader/grammar/grammar_mesa.h" #include "arbprogparse.h" -#include "program.h" #include "programopt.h" #include "prog_parameter.h" #include "prog_statevars.h" -- cgit v1.1 From ae943f8e202fc3791bd56ac863e5493cd17bb44c Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sun, 17 Jan 2010 01:49:16 -0800 Subject: mesa: Remove unnecessary headers from vtxfmt.c. --- src/mesa/main/vtxfmt.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/vtxfmt.c b/src/mesa/main/vtxfmt.c index c9eea8a..0dd3e5e 100644 --- a/src/mesa/main/vtxfmt.c +++ b/src/mesa/main/vtxfmt.c @@ -28,11 +28,9 @@ #include "glheader.h" #include "api_arrayelt.h" -#include "api_loopback.h" #include "context.h" #include "imports.h" #include "mtypes.h" -#include "state.h" #include "vtxfmt.h" #include "eval.h" #include "dlist.h" -- cgit v1.1 From 6b6ac9aca08603fb0e3f91bf53fd6d49a1701e2a Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sun, 17 Jan 2010 15:48:39 -0800 Subject: mesa: Use preprocessor to comment out code. --- src/mesa/main/texstore.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/texstore.c b/src/mesa/main/texstore.c index 792c831..fcd0a56 100644 --- a/src/mesa/main/texstore.c +++ b/src/mesa/main/texstore.c @@ -263,7 +263,7 @@ compute_component_mapping(GLenum inFormat, GLenum outFormat, map[ZERO] = ZERO; map[ONE] = ONE; -/* +#if 0 _mesa_printf("from %x/%s to %x/%s map %d %d %d %d %d %d\n", inFormat, _mesa_lookup_enum_by_nr(inFormat), outFormat, _mesa_lookup_enum_by_nr(outFormat), @@ -273,7 +273,7 @@ compute_component_mapping(GLenum inFormat, GLenum outFormat, map[3], map[4], map[5]); -*/ +#endif } -- cgit v1.1 From 3e876431d01c50b5672d0ad28f7f8dbd20670616 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sun, 17 Jan 2010 16:08:59 -0800 Subject: mesa: Remove unnecessary headers from texstate.c. --- src/mesa/main/texstate.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/texstate.c b/src/mesa/main/texstate.c index c735e18..25333d8 100644 --- a/src/mesa/main/texstate.c +++ b/src/mesa/main/texstate.c @@ -35,11 +35,9 @@ #include "context.h" #include "enums.h" #include "macros.h" -#include "texcompress.h" #include "texobj.h" #include "teximage.h" #include "texstate.h" -#include "texenvprogram.h" #include "mtypes.h" -- cgit v1.1 From 59eed7a2015cf301ea20392febc0de6b8d1ee0b1 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sun, 17 Jan 2010 16:21:11 -0800 Subject: mesa: Remove unnecessary header from texparam.c. --- src/mesa/main/texparam.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/texparam.c b/src/mesa/main/texparam.c index 9e1a889..93c5d6c 100644 --- a/src/mesa/main/texparam.c +++ b/src/mesa/main/texparam.c @@ -33,7 +33,6 @@ #include "main/glheader.h" #include "main/colormac.h" #include "main/context.h" -#include "main/enums.h" #include "main/formats.h" #include "main/macros.h" #include "main/texcompress.h" -- cgit v1.1 From c847e7d07b3f43d5c05a920cf6326b89b31ed92b Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sun, 17 Jan 2010 20:50:15 -0800 Subject: mesa: Remove unnecessary header from texobj.c. --- src/mesa/main/texobj.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/texobj.c b/src/mesa/main/texobj.c index 237b6eb..7f62557 100644 --- a/src/mesa/main/texobj.c +++ b/src/mesa/main/texobj.c @@ -38,7 +38,6 @@ #include "imports.h" #include "macros.h" #include "teximage.h" -#include "texstate.h" #include "texobj.h" #include "mtypes.h" #include "shader/prog_instruction.h" -- cgit v1.1 From 6938dccf1ac0955026ac68794a03f49bc370fd44 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sun, 17 Jan 2010 22:31:53 -0800 Subject: mesa: Remove unnecessary header from teximage.c. --- src/mesa/main/teximage.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index b946f3c..76273b0 100644 --- a/src/mesa/main/teximage.c +++ b/src/mesa/main/teximage.c @@ -46,7 +46,6 @@ #include "texfetch.h" #include "teximage.h" #include "texstate.h" -#include "texstore.h" #include "mtypes.h" -- cgit v1.1 From 39824945fa738666b4bb804382904b0537322878 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 00:14:51 -0800 Subject: mesa: Remove unnecessary headers from texgetimage.c. --- src/mesa/main/texgetimage.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/texgetimage.c b/src/mesa/main/texgetimage.c index ac467c4..0cc6a56 100644 --- a/src/mesa/main/texgetimage.c +++ b/src/mesa/main/texgetimage.c @@ -35,10 +35,8 @@ #include "context.h" #include "formats.h" #include "image.h" -#include "texcompress.h" #include "texgetimage.h" #include "teximage.h" -#include "texstate.h" -- cgit v1.1 From d773f28ff29a0abbb9f856cb4a3c60fcaeea1d3b Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 00:47:56 -0800 Subject: mesa: Remove unnecessary headers from texformat.c. --- src/mesa/main/texformat.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/texformat.c b/src/mesa/main/texformat.c index 1a374e7..096945a 100644 --- a/src/mesa/main/texformat.c +++ b/src/mesa/main/texformat.c @@ -35,8 +35,6 @@ #include "context.h" #include "texcompress.h" -#include "texcompress_fxt1.h" -#include "texcompress_s3tc.h" #include "texformat.h" -- cgit v1.1 From 28576c9ac5a3b6459d94822f333d2e3fbefe5003 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Mon, 18 Jan 2010 11:26:55 -0700 Subject: st/mesa: change instruction count assertion to > 0 Shaders should at least have an END instruction. --- src/mesa/state_tracker/st_atom_shader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_atom_shader.c b/src/mesa/state_tracker/st_atom_shader.c index 9fad58a..4c106eb 100644 --- a/src/mesa/state_tracker/st_atom_shader.c +++ b/src/mesa/state_tracker/st_atom_shader.c @@ -146,7 +146,7 @@ find_translated_vp(struct st_context *st, stfp->num_input_slots = numIn; - assert(stfp->Base.Base.NumInstructions > 1); + assert(stfp->Base.Base.NumInstructions > 0); st_translate_fragment_program(st, stfp, stfp->input_to_slot); } -- cgit v1.1 From ec29ba12a687c8a08ecba002216bbd9f56facef0 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 18:52:24 -0800 Subject: mesa: Remove unnecessary headers from texcompress.c. --- src/mesa/main/texcompress.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/texcompress.c b/src/mesa/main/texcompress.c index a4f1926..cff6de8 100644 --- a/src/mesa/main/texcompress.c +++ b/src/mesa/main/texcompress.c @@ -35,10 +35,7 @@ #include "colormac.h" #include "context.h" #include "formats.h" -#include "image.h" -#include "mipmap.h" #include "texcompress.h" -#include "texstore.h" /** -- cgit v1.1 From 66035503532a17110e36d1d1053e98a1595d03d9 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 18:54:54 -0800 Subject: mesa: Remove unnecessary header from state.c. --- src/mesa/main/state.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/state.c b/src/mesa/main/state.c index f10e6b0..904ad01 100644 --- a/src/mesa/main/state.c +++ b/src/mesa/main/state.c @@ -48,7 +48,6 @@ #include "texenvprogram.h" #include "texobj.h" #include "texstate.h" -#include "viewport.h" static void -- cgit v1.1 From 80ea879cfa63354ec1312a107f63934c1e6c7824 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 19:03:54 -0800 Subject: mesa: Remove unnecessary header from polygon.c. --- src/mesa/main/polygon.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/polygon.c b/src/mesa/main/polygon.c index 376a87a..dcde675 100644 --- a/src/mesa/main/polygon.c +++ b/src/mesa/main/polygon.c @@ -34,7 +34,6 @@ #include "context.h" #include "image.h" #include "enums.h" -#include "macros.h" #include "polygon.h" #include "mtypes.h" -- cgit v1.1 From 419ae5a48339795d369a41d66312246b2e19f201 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 19:10:05 -0800 Subject: mesa: Remove unnecessary header from points.c. --- src/mesa/main/points.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/points.c b/src/mesa/main/points.c index dcaeccd..e743a2e 100644 --- a/src/mesa/main/points.c +++ b/src/mesa/main/points.c @@ -32,7 +32,6 @@ #include "context.h" #include "macros.h" #include "points.h" -#include "texstate.h" #include "mtypes.h" -- cgit v1.1 From 2f83948370c686d1f5f0b1e0d23b5286169e850d Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 19:14:23 -0800 Subject: mesa: Remove unnecessary headers from pixelstore.c. --- src/mesa/main/pixelstore.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/pixelstore.c b/src/mesa/main/pixelstore.c index 6a641f8..ec585ef 100644 --- a/src/mesa/main/pixelstore.c +++ b/src/mesa/main/pixelstore.c @@ -30,10 +30,7 @@ #include "glheader.h" #include "bufferobj.h" -#include "colormac.h" #include "context.h" -#include "image.h" -#include "macros.h" #include "pixelstore.h" #include "mtypes.h" -- cgit v1.1 From ed5a116eb411aed2a2f1986a1effbb8a426b0065 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 19:20:56 -0800 Subject: mesa: Remove unnecessary header from pixel.c. --- src/mesa/main/pixel.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/pixel.c b/src/mesa/main/pixel.c index 3820ebd..f6f9c11 100644 --- a/src/mesa/main/pixel.c +++ b/src/mesa/main/pixel.c @@ -32,7 +32,6 @@ #include "bufferobj.h" #include "colormac.h" #include "context.h" -#include "image.h" #include "macros.h" #include "pixel.h" #include "mtypes.h" -- cgit v1.1 From d0125e3c29942ae7a81a66748ea53b402114993d Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 19:23:47 -0800 Subject: mesa: Remove unnecessary header from mipmap.c. --- src/mesa/main/mipmap.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/mipmap.c b/src/mesa/main/mipmap.c index 7350c7a..77cd1d4 100644 --- a/src/mesa/main/mipmap.c +++ b/src/mesa/main/mipmap.c @@ -30,7 +30,6 @@ #include "imports.h" #include "formats.h" #include "mipmap.h" -#include "texcompress.h" #include "teximage.h" #include "texstore.h" #include "image.h" -- cgit v1.1 From ebd10755984d582fa65c71b58bc20015e2ea9caf Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 19:32:51 -0800 Subject: mesa: Remove unnecessary headers from lines.c. --- src/mesa/main/lines.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/lines.c b/src/mesa/main/lines.c index 81d0d33..cc63a75 100644 --- a/src/mesa/main/lines.c +++ b/src/mesa/main/lines.c @@ -25,10 +25,8 @@ #include "glheader.h" #include "context.h" -#include "depth.h" #include "lines.h" #include "macros.h" -#include "texstate.h" #include "mtypes.h" -- cgit v1.1 From 8fb92e96e90a8cb57da78444fd3395aba424cb0a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Fonseca?= Date: Mon, 18 Jan 2010 19:32:36 -0800 Subject: mesa: Handle PIPE_FORMAT_B8G8R8X8_UNORM. --- src/mesa/state_tracker/st_format.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_format.c b/src/mesa/state_tracker/st_format.c index 6b1c499..d2bc0dc 100644 --- a/src/mesa/state_tracker/st_format.c +++ b/src/mesa/state_tracker/st_format.c @@ -293,6 +293,8 @@ st_pipe_format_to_mesa_format(enum pipe_format pipeFormat) return MESA_FORMAT_XRGB8888; case PIPE_FORMAT_B8G8R8A8_UNORM: return MESA_FORMAT_ARGB8888_REV; + case PIPE_FORMAT_B8G8R8X8_UNORM: + return MESA_FORMAT_XRGB8888_REV; case PIPE_FORMAT_A1R5G5B5_UNORM: return MESA_FORMAT_ARGB1555; case PIPE_FORMAT_A4R4G4B4_UNORM: -- cgit v1.1 From 2cbc3e0a206b701780c893cf96507778ab1fb5a1 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:02:19 -0800 Subject: mesa: Remove unnecessary header from image.c. --- src/mesa/main/image.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/image.c b/src/mesa/main/image.c index 3b685cb..1dfcc48 100644 --- a/src/mesa/main/image.c +++ b/src/mesa/main/image.c @@ -36,7 +36,6 @@ #include "image.h" #include "imports.h" #include "macros.h" -#include "pixel.h" /** -- cgit v1.1 From b6dce54214c804e46aab05acd03a64c35a9baa63 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:07:53 -0800 Subject: mesa: Remove unnecessary header from formats.c. --- src/mesa/main/formats.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/formats.c b/src/mesa/main/formats.c index 5983f00..d0c9c00 100644 --- a/src/mesa/main/formats.c +++ b/src/mesa/main/formats.c @@ -27,7 +27,6 @@ #include "imports.h" #include "formats.h" #include "config.h" -#include "texstore.h" /** -- cgit v1.1 From 536e3c9168c315651210ca853eb8cb4423f9f71c Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:14:04 -0800 Subject: mesa: Remove unnecessary headers from fbobject.c. --- src/mesa/main/fbobject.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 7b3599f..56e8065 100644 --- a/src/mesa/main/fbobject.c +++ b/src/mesa/main/fbobject.c @@ -40,13 +40,10 @@ #include "framebuffer.h" #include "hash.h" #include "macros.h" -#include "mipmap.h" #include "renderbuffer.h" #include "state.h" #include "teximage.h" #include "texobj.h" -#include "texstore.h" -#include "texstate.h" /** Set this to 1 to help debug FBO incompleteness problems */ -- cgit v1.1 From 0b3109aa053539b2e07ec16da980615f16dd8c2b Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:17:45 -0800 Subject: mesa: Remove unnecessary header from enable.c. --- src/mesa/main/enable.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/enable.c b/src/mesa/main/enable.c index 12ce14c..1573bc2 100644 --- a/src/mesa/main/enable.c +++ b/src/mesa/main/enable.c @@ -32,7 +32,6 @@ #include "context.h" #include "enable.h" #include "light.h" -#include "macros.h" #include "simple_list.h" #include "mtypes.h" #include "enums.h" -- cgit v1.1 From 7395ab042aedb3ef29d3c5d974138bc4430cb772 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:22:47 -0800 Subject: mesa: Remove unnecessary header from drawpix.c. --- src/mesa/main/drawpix.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/drawpix.c b/src/mesa/main/drawpix.c index 5d4b53a..0afd47b 100644 --- a/src/mesa/main/drawpix.c +++ b/src/mesa/main/drawpix.c @@ -30,7 +30,6 @@ #include "enums.h" #include "feedback.h" #include "framebuffer.h" -#include "image.h" #include "readpix.h" #include "state.h" #include "glapi/dispatch.h" -- cgit v1.1 From 2660511ea94c2d3abe8495258f7ea693cae3759e Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:31:02 -0800 Subject: mesa: Remove unnecessary headers from dlist.c. --- src/mesa/main/dlist.c | 21 --------------------- 1 file changed, 21 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/dlist.c b/src/mesa/main/dlist.c index b692c33..a90bb6c 100644 --- a/src/mesa/main/dlist.c +++ b/src/mesa/main/dlist.c @@ -35,46 +35,25 @@ #include "api_loopback.h" #include "config.h" #include "mfeatures.h" -#include "attrib.h" -#include "blend.h" -#include "buffers.h" #if FEATURE_ARB_vertex_buffer_object #include "bufferobj.h" #endif #include "arrayobj.h" -#include "clip.h" -#include "colortab.h" #include "context.h" -#include "convolve.h" -#include "depth.h" #include "dlist.h" -#include "enable.h" #include "enums.h" #include "eval.h" -#include "extensions.h" -#include "feedback.h" #include "framebuffer.h" -#include "get.h" #include "glapi/glapi.h" #include "hash.h" -#include "histogram.h" #include "image.h" #include "light.h" -#include "lines.h" #include "dlist.h" #include "macros.h" -#include "matrix.h" -#include "pixel.h" -#include "points.h" -#include "polygon.h" #include "queryobj.h" -#include "state.h" -#include "texobj.h" #include "teximage.h" -#include "texstate.h" #include "mtypes.h" #include "varray.h" -#include "vtxfmt.h" #if FEATURE_ARB_vertex_program || FEATURE_ARB_fragment_program #include "shader/arbprogram.h" #include "shader/program.h" -- cgit v1.1 From 6deb8c9831c60ed5ae93966b5a37d1215b8682a4 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:34:25 -0800 Subject: mesa: Remove unnecessary header from depthstencil.c. --- src/mesa/main/depthstencil.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/depthstencil.c b/src/mesa/main/depthstencil.c index 193c7f8..49946a6 100644 --- a/src/mesa/main/depthstencil.c +++ b/src/mesa/main/depthstencil.c @@ -25,7 +25,6 @@ #include "glheader.h" #include "imports.h" #include "context.h" -#include "fbobject.h" #include "formats.h" #include "mtypes.h" #include "depthstencil.h" -- cgit v1.1 From b36b85f9d0c721188582e6daa3328ab9766f85c0 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:37:18 -0800 Subject: mesa: Remove unnecessary headers from debug.c. --- src/mesa/main/debug.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/debug.c b/src/mesa/main/debug.c index a42113e..d4d099a 100644 --- a/src/mesa/main/debug.c +++ b/src/mesa/main/debug.c @@ -26,7 +26,6 @@ #include "mtypes.h" #include "attrib.h" #include "colormac.h" -#include "context.h" #include "enums.h" #include "formats.h" #include "hash.h" @@ -35,7 +34,6 @@ #include "get.h" #include "pixelstore.h" #include "readpix.h" -#include "texgetimage.h" #include "texobj.h" -- cgit v1.1 From 08063ba4499c47c9b55c80878a668050c6272c30 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:41:31 -0800 Subject: mesa: Fix typo of 'unknown' in debug.c. --- src/mesa/main/debug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/debug.c b/src/mesa/main/debug.c index d4d099a..9bad834 100644 --- a/src/mesa/main/debug.c +++ b/src/mesa/main/debug.c @@ -52,7 +52,7 @@ const char *_mesa_prim_name[GL_POLYGON+4] = { "GL_QUAD_STRIP", "GL_POLYGON", "outside begin/end", - "inside unkown primitive", + "inside unknown primitive", "unknown state" }; -- cgit v1.1 From 7366d8e7d20efc673702d7c6c9603d507edcf06d Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 21:56:58 -0800 Subject: mesa: Remove unnecessary header from convolve.c. --- src/mesa/main/convolve.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/convolve.c b/src/mesa/main/convolve.c index 8db3e79..5ed93e0 100644 --- a/src/mesa/main/convolve.c +++ b/src/mesa/main/convolve.c @@ -38,7 +38,6 @@ #include "context.h" #include "image.h" #include "mtypes.h" -#include "pixel.h" #include "state.h" #include "glapi/dispatch.h" -- cgit v1.1 From c4ad036ce145ab04677b6e40c18315906b897a31 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 22:17:03 -0800 Subject: mesa: Remove unnecessary headers from buffers.c. --- src/mesa/main/buffers.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/buffers.c b/src/mesa/main/buffers.c index 97f0659..fb30b59 100644 --- a/src/mesa/main/buffers.c +++ b/src/mesa/main/buffers.c @@ -35,8 +35,6 @@ #include "colormac.h" #include "context.h" #include "enums.h" -#include "fbobject.h" -#include "state.h" #define BAD_MASK ~0u -- cgit v1.1 From 2613fa815abd7d794ec7144f0ad19ef4f65da991 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 22:45:23 -0800 Subject: mesa: Remove unnecessary header from blend.c. --- src/mesa/main/blend.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/blend.c b/src/mesa/main/blend.c index 830e3b2..0b6ff1a 100644 --- a/src/mesa/main/blend.c +++ b/src/mesa/main/blend.c @@ -35,7 +35,6 @@ #include "enums.h" #include "macros.h" #include "mtypes.h" -#include "glapi/glapitable.h" /** -- cgit v1.1 From 45a27eacd6301078c6f62682193dda3141088fe2 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 18 Jan 2010 22:50:08 -0800 Subject: mesa: Remove unnecessary header from attrib.c. --- src/mesa/main/attrib.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/main/attrib.c b/src/mesa/main/attrib.c index a14f71c..7adb2e2 100644 --- a/src/mesa/main/attrib.c +++ b/src/mesa/main/attrib.c @@ -33,7 +33,6 @@ #include "bufferobj.h" #include "clear.h" #include "colormac.h" -#include "colortab.h" #include "context.h" #include "depth.h" #include "enable.h" -- cgit v1.1 From faa99dd31de7dad4e9851b12f7f788adb6fce0fc Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Tue, 19 Jan 2010 00:45:16 -0800 Subject: unichrome: Remove unnecessary headers. --- src/mesa/drivers/dri/unichrome/via_context.c | 3 --- src/mesa/drivers/dri/unichrome/via_ioctl.c | 1 - src/mesa/drivers/dri/unichrome/via_render.c | 1 - src/mesa/drivers/dri/unichrome/via_screen.c | 4 ---- src/mesa/drivers/dri/unichrome/via_state.c | 3 --- src/mesa/drivers/dri/unichrome/via_tex.c | 2 -- src/mesa/drivers/dri/unichrome/via_texcombine.c | 1 - 7 files changed, 15 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/unichrome/via_context.c b/src/mesa/drivers/dri/unichrome/via_context.c index 0524bec..ff666a3 100644 --- a/src/mesa/drivers/dri/unichrome/via_context.c +++ b/src/mesa/drivers/dri/unichrome/via_context.c @@ -33,10 +33,7 @@ #include "main/glheader.h" #include "main/context.h" #include "main/formats.h" -#include "main/matrix.h" -#include "main/state.h" #include "main/simple_list.h" -#include "main/extensions.h" #include "main/framebuffer.h" #include "main/renderbuffer.h" diff --git a/src/mesa/drivers/dri/unichrome/via_ioctl.c b/src/mesa/drivers/dri/unichrome/via_ioctl.c index 91c94fa..69eac44 100644 --- a/src/mesa/drivers/dri/unichrome/via_ioctl.c +++ b/src/mesa/drivers/dri/unichrome/via_ioctl.c @@ -34,7 +34,6 @@ #include "via_context.h" #include "via_tris.h" #include "via_ioctl.h" -#include "via_state.h" #include "via_fb.h" #include "via_3d_reg.h" diff --git a/src/mesa/drivers/dri/unichrome/via_render.c b/src/mesa/drivers/dri/unichrome/via_render.c index f676cc1..896c43d 100644 --- a/src/mesa/drivers/dri/unichrome/via_render.c +++ b/src/mesa/drivers/dri/unichrome/via_render.c @@ -37,7 +37,6 @@ #include "via_context.h" #include "via_tris.h" -#include "via_state.h" #include "via_ioctl.h" /* diff --git a/src/mesa/drivers/dri/unichrome/via_screen.c b/src/mesa/drivers/dri/unichrome/via_screen.c index e0bf58c..115d3fb 100644 --- a/src/mesa/drivers/dri/unichrome/via_screen.c +++ b/src/mesa/drivers/dri/unichrome/via_screen.c @@ -30,17 +30,13 @@ #include "main/context.h" #include "main/framebuffer.h" #include "main/renderbuffer.h" -#include "main/matrix.h" #include "main/simple_list.h" #include "vblank.h" #include "via_state.h" #include "via_tex.h" #include "via_span.h" -#include "via_tris.h" -#include "via_ioctl.h" #include "via_screen.h" -#include "via_fb.h" #include "via_dri.h" #include "GL/internal/dri_interface.h" diff --git a/src/mesa/drivers/dri/unichrome/via_state.c b/src/mesa/drivers/dri/unichrome/via_state.c index 840e4e4..e65f5fd 100644 --- a/src/mesa/drivers/dri/unichrome/via_state.c +++ b/src/mesa/drivers/dri/unichrome/via_state.c @@ -35,7 +35,6 @@ #include "via_context.h" #include "via_state.h" #include "via_tex.h" -#include "via_tris.h" #include "via_ioctl.h" #include "via_3d_reg.h" @@ -44,8 +43,6 @@ #include "tnl/tnl.h" #include "swrast_setup/swrast_setup.h" -#include "tnl/t_pipeline.h" - static GLuint ROP[16] = { HC_HROP_BLACK, /* GL_CLEAR 0 */ diff --git a/src/mesa/drivers/dri/unichrome/via_tex.c b/src/mesa/drivers/dri/unichrome/via_tex.c index 24924d2..917f975 100644 --- a/src/mesa/drivers/dri/unichrome/via_tex.c +++ b/src/mesa/drivers/dri/unichrome/via_tex.c @@ -37,14 +37,12 @@ #include "main/mipmap.h" #include "main/mm.h" #include "main/simple_list.h" -#include "main/texcompress.h" #include "main/texobj.h" #include "main/texstore.h" #include "via_context.h" #include "via_fb.h" #include "via_tex.h" -#include "via_state.h" #include "via_ioctl.h" #include "via_3d_reg.h" diff --git a/src/mesa/drivers/dri/unichrome/via_texcombine.c b/src/mesa/drivers/dri/unichrome/via_texcombine.c index b646897..f87ba07 100644 --- a/src/mesa/drivers/dri/unichrome/via_texcombine.c +++ b/src/mesa/drivers/dri/unichrome/via_texcombine.c @@ -38,7 +38,6 @@ #include "main/enums.h" #include "via_context.h" -#include "via_state.h" #include "via_tex.h" #include "via_3d_reg.h" -- cgit v1.1 From 116a02be2264807dafb5fdfd4e3c913bb728c11f Mon Sep 17 00:00:00 2001 From: Ben Skeggs Date: Mon, 11 Jan 2010 11:41:47 +1000 Subject: st/dri: update dri2 drawables when viewport is changed Fixes gnome-shell on nouveau, as well as window resize with various other applications. Signed-off-by: Ben Skeggs --- src/mesa/state_tracker/st_cb_viewport.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_viewport.c b/src/mesa/state_tracker/st_cb_viewport.c index 9450b3a..d8bd244 100644 --- a/src/mesa/state_tracker/st_cb_viewport.c +++ b/src/mesa/state_tracker/st_cb_viewport.c @@ -40,8 +40,8 @@ static void st_viewport(GLcontext * ctx, GLint x, GLint y, { struct st_context *st = ctx->st; - if (st->pipe->winsys && st->pipe->winsys->update_buffer) - st->pipe->winsys->update_buffer( st->pipe->winsys, + if (st->pipe->screen && st->pipe->screen->update_buffer) + st->pipe->screen->update_buffer( st->pipe->screen, st->pipe->priv ); } -- cgit v1.1 From 65d2a266375cf32fd90c7fb77fb87993d3a652ea Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Wed, 20 Jan 2010 08:03:46 -0700 Subject: st/mesa: fix format logic in compatible_src_dst_formats() We need to consider the user-requested formats, not the actual device- chosen formats. See code comments for more details. --- src/mesa/state_tracker/st_cb_texture.c | 56 ++++++++++++++++++++++++++-------- 1 file changed, 44 insertions(+), 12 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c index e9c30cb..a0dc016 100644 --- a/src/mesa/state_tracker/st_cb_texture.c +++ b/src/mesa/state_tracker/st_cb_texture.c @@ -31,6 +31,7 @@ #include "main/convolve.h" #endif #include "main/enums.h" +#include "main/fbobject.h" #include "main/formats.h" #include "main/image.h" #include "main/imports.h" @@ -1352,33 +1353,64 @@ fallback_copy_texsubimage(GLcontext *ctx, GLenum target, GLint level, } + +/** + * If the format of the src renderbuffer and the format of the dest + * texture are compatible (in terms of blitting), return a TGSI writemask + * to be used during the blit. + * If the src/dest are incompatible, return 0. + */ static unsigned -compatible_src_dst_formats(const struct gl_renderbuffer *src, +compatible_src_dst_formats(GLcontext *ctx, + const struct gl_renderbuffer *src, const struct gl_texture_image *dst) { - const GLenum srcFormat = _mesa_get_format_base_format(src->Format); - const GLenum dstLogicalFormat = _mesa_get_format_base_format(dst->TexFormat); + /* Get logical base formats for the src and dest. + * That is, use the user-requested formats and not the actual, device- + * chosen formats. + * For example, the user may have requested an A8 texture but the + * driver may actually be using an RGBA texture format. When we + * copy/blit to that texture, we only want to copy the Alpha channel + * and not the RGB channels. + * + * Similarly, when the src FBO was created an RGB format may have been + * requested but the driver actually chose an RGBA format. In that case, + * we don't want to copy the undefined Alpha channel to the dest texture + * (it should be 1.0). + */ + const GLenum srcFormat = _mesa_base_fbo_format(ctx, src->InternalFormat); + const GLenum dstFormat = _mesa_base_tex_format(ctx, dst->InternalFormat); - if (srcFormat == dstLogicalFormat) { + /** + * XXX when we have red-only and red/green renderbuffers we'll need + * to add more cases here (or implement a general-purpose routine that + * queries the existance of the R,G,B,A channels in the src and dest). + */ + if (srcFormat == dstFormat) { /* This is the same as matching_base_formats, which should * always pass, as it did previously. */ return TGSI_WRITEMASK_XYZW; } - else if (srcFormat == GL_RGBA && - dstLogicalFormat == GL_RGB) { - /* Add a single special case to cope with RGBA->RGB transfers, - * setting A to 1.0 to cope with situations where the RGB - * destination is actually stored as RGBA. + else if (srcFormat == GL_RGB && dstFormat == GL_RGBA) { + /* Make sure that A in the dest is 1. The actual src format + * may be RGBA and have undefined A values. + */ + return TGSI_WRITEMASK_XYZ; + } + else if (srcFormat == GL_RGBA && dstFormat == GL_RGB) { + /* Make sure that A in the dest is 1. The actual dst format + * may be RGBA and will need A=1 to provide proper alpha values + * when sampled later. */ - return TGSI_WRITEMASK_XYZ; /* A ==> 1.0 */ + return TGSI_WRITEMASK_XYZ; } else { if (ST_DEBUG & DEBUG_FALLBACK) debug_printf("%s failed for src %s, dst %s\n", __FUNCTION__, _mesa_lookup_enum_by_nr(srcFormat), - _mesa_lookup_enum_by_nr(dstLogicalFormat)); + _mesa_lookup_enum_by_nr(dstFormat)); /* Otherwise fail. */ @@ -1489,7 +1521,7 @@ st_copy_texsubimage(GLcontext *ctx, matching_base_formats = (_mesa_get_format_base_format(strb->Base.Format) == _mesa_get_format_base_format(texImage->TexFormat)); - format_writemask = compatible_src_dst_formats(&strb->Base, texImage); + format_writemask = compatible_src_dst_formats(ctx, &strb->Base, texImage); if (ctx->_ImageTransferState == 0x0) { -- cgit v1.1 From 0bc2cbf82a20c0fa5b160605eb7e8118791f5fdd Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Wed, 20 Jan 2010 16:27:44 -0800 Subject: ffb: Remove unnecessary headers. --- src/mesa/drivers/dri/ffb/ffb_bitmap.c | 1 - src/mesa/drivers/dri/ffb/ffb_clear.c | 3 --- src/mesa/drivers/dri/ffb/ffb_dd.c | 4 ---- src/mesa/drivers/dri/ffb/ffb_depth.c | 1 - src/mesa/drivers/dri/ffb/ffb_lines.c | 4 ---- src/mesa/drivers/dri/ffb/ffb_points.c | 2 -- src/mesa/drivers/dri/ffb/ffb_span.c | 2 -- src/mesa/drivers/dri/ffb/ffb_state.c | 5 ----- src/mesa/drivers/dri/ffb/ffb_stencil.c | 2 -- src/mesa/drivers/dri/ffb/ffb_vb.c | 2 -- src/mesa/drivers/dri/ffb/ffb_xmesa.c | 2 -- 11 files changed, 28 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/ffb/ffb_bitmap.c b/src/mesa/drivers/dri/ffb/ffb_bitmap.c index f89c041..1240f1c 100644 --- a/src/mesa/drivers/dri/ffb/ffb_bitmap.c +++ b/src/mesa/drivers/dri/ffb/ffb_bitmap.c @@ -30,7 +30,6 @@ #include "ffb_lock.h" #include "ffb_bitmap.h" #include "swrast/swrast.h" -#include "main/image.h" #include "main/macros.h" /* Compute ceiling of integer quotient of A divided by B: */ diff --git a/src/mesa/drivers/dri/ffb/ffb_clear.c b/src/mesa/drivers/dri/ffb/ffb_clear.c index 776fb48..6239a4e 100644 --- a/src/mesa/drivers/dri/ffb/ffb_clear.c +++ b/src/mesa/drivers/dri/ffb/ffb_clear.c @@ -26,15 +26,12 @@ */ #include "main/mtypes.h" -#include "main/extensions.h" #include "main/mm.h" #include "ffb_dd.h" #include "ffb_span.h" -#include "ffb_depth.h" #include "ffb_context.h" #include "ffb_vb.h" -#include "ffb_tris.h" #include "ffb_clear.h" #include "ffb_lock.h" diff --git a/src/mesa/drivers/dri/ffb/ffb_dd.c b/src/mesa/drivers/dri/ffb/ffb_dd.c index cf83b91..91b6d31 100644 --- a/src/mesa/drivers/dri/ffb/ffb_dd.c +++ b/src/mesa/drivers/dri/ffb/ffb_dd.c @@ -27,13 +27,9 @@ #include "main/mtypes.h" #include "main/mm.h" -#include "main/extensions.h" #include "ffb_dd.h" #include "ffb_span.h" -#include "ffb_depth.h" #include "ffb_context.h" -#include "ffb_vb.h" -#include "ffb_tris.h" #include "ffb_clear.h" #include "ffb_lock.h" diff --git a/src/mesa/drivers/dri/ffb/ffb_depth.c b/src/mesa/drivers/dri/ffb/ffb_depth.c index 71f204d..e82c241 100644 --- a/src/mesa/drivers/dri/ffb/ffb_depth.c +++ b/src/mesa/drivers/dri/ffb/ffb_depth.c @@ -26,7 +26,6 @@ */ #include "main/mtypes.h" -#include "swrast/swrast.h" #include "ffb_dd.h" #include "ffb_span.h" #include "ffb_context.h" diff --git a/src/mesa/drivers/dri/ffb/ffb_lines.c b/src/mesa/drivers/dri/ffb/ffb_lines.c index 19dff50..6dca4ed 100644 --- a/src/mesa/drivers/dri/ffb/ffb_lines.c +++ b/src/mesa/drivers/dri/ffb/ffb_lines.c @@ -27,15 +27,11 @@ #include "main/mtypes.h" #include "main/mm.h" -#include "main/extensions.h" #include "ffb_dd.h" #include "ffb_span.h" -#include "ffb_depth.h" #include "ffb_context.h" #include "ffb_vb.h" #include "ffb_lines.h" -#include "ffb_tris.h" -#include "ffb_lock.h" #undef FFB_LINE_TRACE diff --git a/src/mesa/drivers/dri/ffb/ffb_points.c b/src/mesa/drivers/dri/ffb/ffb_points.c index 9c37a47..5bf4f8f 100644 --- a/src/mesa/drivers/dri/ffb/ffb_points.c +++ b/src/mesa/drivers/dri/ffb/ffb_points.c @@ -30,8 +30,6 @@ #include "ffb_context.h" #include "ffb_vb.h" #include "ffb_points.h" -#include "ffb_tris.h" -#include "ffb_lock.h" #undef FFB_POINT_TRACE diff --git a/src/mesa/drivers/dri/ffb/ffb_span.c b/src/mesa/drivers/dri/ffb/ffb_span.c index 0d3d604..c4cb386 100644 --- a/src/mesa/drivers/dri/ffb/ffb_span.c +++ b/src/mesa/drivers/dri/ffb/ffb_span.c @@ -31,8 +31,6 @@ #include "ffb_context.h" #include "ffb_lock.h" -#include "swrast/swrast.h" - #define DBG 0 #define HW_LOCK() \ diff --git a/src/mesa/drivers/dri/ffb/ffb_state.c b/src/mesa/drivers/dri/ffb/ffb_state.c index 5eb8f41..81341cb 100644 --- a/src/mesa/drivers/dri/ffb/ffb_state.c +++ b/src/mesa/drivers/dri/ffb/ffb_state.c @@ -27,8 +27,6 @@ #include "main/mtypes.h" #include "main/colormac.h" -#include "main/mm.h" -#include "main/extensions.h" #include "main/enums.h" #include "vbo/vbo.h" @@ -39,12 +37,9 @@ #include "ffb_dd.h" #include "ffb_span.h" -#include "ffb_depth.h" #include "ffb_context.h" -#include "ffb_vb.h" #include "ffb_tris.h" #include "ffb_state.h" -#include "ffb_lock.h" #undef STATE_TRACE diff --git a/src/mesa/drivers/dri/ffb/ffb_stencil.c b/src/mesa/drivers/dri/ffb/ffb_stencil.c index 921a83d..2be5a40 100644 --- a/src/mesa/drivers/dri/ffb/ffb_stencil.c +++ b/src/mesa/drivers/dri/ffb/ffb_stencil.c @@ -32,8 +32,6 @@ #include "ffb_stencil.h" #include "ffb_lock.h" -#include "swrast/swrast.h" - #undef STENCIL_TRACE static void FFBWriteStencilSpan( GLcontext *ctx, diff --git a/src/mesa/drivers/dri/ffb/ffb_vb.c b/src/mesa/drivers/dri/ffb/ffb_vb.c index f9c6fd1..ca8ffb2 100644 --- a/src/mesa/drivers/dri/ffb/ffb_vb.c +++ b/src/mesa/drivers/dri/ffb/ffb_vb.c @@ -30,8 +30,6 @@ #include "ffb_vb.h" #include "main/imports.h" #include "tnl/t_context.h" -#include "swrast_setup/swrast_setup.h" -#include "math/m_translate.h" #undef VB_DEBUG diff --git a/src/mesa/drivers/dri/ffb/ffb_xmesa.c b/src/mesa/drivers/dri/ffb/ffb_xmesa.c index 09cc26d..28f8e53 100644 --- a/src/mesa/drivers/dri/ffb/ffb_xmesa.c +++ b/src/mesa/drivers/dri/ffb/ffb_xmesa.c @@ -28,7 +28,6 @@ #include "ffb_xmesa.h" #include "main/context.h" #include "main/framebuffer.h" -#include "main/matrix.h" #include "main/renderbuffer.h" #include "main/simple_list.h" #include "main/imports.h" @@ -52,7 +51,6 @@ #include "ffb_lines.h" #include "ffb_points.h" #include "ffb_state.h" -#include "ffb_tex.h" #include "ffb_lock.h" #include "ffb_vtxfmt.h" #include "ffb_bitmap.h" -- cgit v1.1 From 7c66211b7dcf302685b8cc3f80a4d90b73d7d62d Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Wed, 20 Jan 2010 22:02:51 -0800 Subject: i810: Remove unnecessary headers. --- src/mesa/drivers/dri/i810/i810context.c | 3 --- src/mesa/drivers/dri/i810/i810render.c | 1 - src/mesa/drivers/dri/i810/i810screen.c | 4 ---- src/mesa/drivers/dri/i810/i810state.c | 2 -- src/mesa/drivers/dri/i810/i810tex.c | 2 -- src/mesa/drivers/dri/i810/i810texmem.c | 1 - src/mesa/drivers/dri/i810/i810vb.c | 1 - 7 files changed, 14 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/i810/i810context.c b/src/mesa/drivers/dri/i810/i810context.c index 7311b2e..350c2e3 100644 --- a/src/mesa/drivers/dri/i810/i810context.c +++ b/src/mesa/drivers/dri/i810/i810context.c @@ -34,10 +34,7 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "main/glheader.h" #include "main/context.h" -#include "main/matrix.h" #include "main/simple_list.h" -#include "main/extensions.h" -#include "main/framebuffer.h" #include "main/imports.h" #include "main/points.h" diff --git a/src/mesa/drivers/dri/i810/i810render.c b/src/mesa/drivers/dri/i810/i810render.c index 1d98e00..b543d4f 100644 --- a/src/mesa/drivers/dri/i810/i810render.c +++ b/src/mesa/drivers/dri/i810/i810render.c @@ -44,7 +44,6 @@ #include "i810context.h" #include "i810tris.h" -#include "i810state.h" #include "i810vb.h" #include "i810ioctl.h" diff --git a/src/mesa/drivers/dri/i810/i810screen.c b/src/mesa/drivers/dri/i810/i810screen.c index 2f6b863..b653958 100644 --- a/src/mesa/drivers/dri/i810/i810screen.c +++ b/src/mesa/drivers/dri/i810/i810screen.c @@ -36,8 +36,6 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "main/imports.h" #include "main/context.h" #include "main/framebuffer.h" -#include "main/fbobject.h" -#include "main/matrix.h" #include "main/renderbuffer.h" #include "main/simple_list.h" #include "utils.h" @@ -48,8 +46,6 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "i810state.h" #include "i810tex.h" #include "i810span.h" -#include "i810tris.h" -#include "i810ioctl.h" #include "GL/internal/dri_interface.h" diff --git a/src/mesa/drivers/dri/i810/i810state.c b/src/mesa/drivers/dri/i810/i810state.c index 1e7a6cf..a4b1477 100644 --- a/src/mesa/drivers/dri/i810/i810state.c +++ b/src/mesa/drivers/dri/i810/i810state.c @@ -20,8 +20,6 @@ #include "i810context.h" #include "i810state.h" #include "i810tex.h" -#include "i810vb.h" -#include "i810tris.h" #include "i810ioctl.h" diff --git a/src/mesa/drivers/dri/i810/i810tex.c b/src/mesa/drivers/dri/i810/i810tex.c index 2f6978f..5c53032 100644 --- a/src/mesa/drivers/dri/i810/i810tex.c +++ b/src/mesa/drivers/dri/i810/i810tex.c @@ -33,7 +33,6 @@ #include "main/colormac.h" #include "main/texobj.h" #include "main/mm.h" -#include "swrast/swrast.h" #include "texmem.h" @@ -42,7 +41,6 @@ #include "i810context.h" #include "i810tex.h" -#include "i810state.h" #include "i810ioctl.h" diff --git a/src/mesa/drivers/dri/i810/i810texmem.c b/src/mesa/drivers/dri/i810/i810texmem.c index d93afbf..bb426a4 100644 --- a/src/mesa/drivers/dri/i810/i810texmem.c +++ b/src/mesa/drivers/dri/i810/i810texmem.c @@ -35,7 +35,6 @@ #include "i810_dri.h" #include "i810context.h" #include "i810tex.h" -#include "i810state.h" #include "i810ioctl.h" diff --git a/src/mesa/drivers/dri/i810/i810vb.c b/src/mesa/drivers/dri/i810/i810vb.c index 30890dc..09a7722 100644 --- a/src/mesa/drivers/dri/i810/i810vb.c +++ b/src/mesa/drivers/dri/i810/i810vb.c @@ -38,7 +38,6 @@ #include "i810context.h" #include "i810vb.h" #include "i810ioctl.h" -#include "i810tris.h" #include "i810state.h" -- cgit v1.1 From e19b3c01f4442e2c85c6df19847368ecb7b2451f Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Wed, 20 Jan 2010 22:52:49 -0800 Subject: mach64: Remove unnecessary headers. --- src/mesa/drivers/dri/mach64/mach64_context.c | 2 -- src/mesa/drivers/dri/mach64/mach64_dd.c | 3 --- src/mesa/drivers/dri/mach64/mach64_lock.c | 1 - src/mesa/drivers/dri/mach64/mach64_screen.c | 2 -- src/mesa/drivers/dri/mach64/mach64_span.c | 1 - src/mesa/drivers/dri/mach64/mach64_state.c | 3 --- src/mesa/drivers/dri/mach64/mach64_tex.c | 5 ----- src/mesa/drivers/dri/mach64/mach64_texmem.c | 3 --- src/mesa/drivers/dri/mach64/mach64_texstate.c | 2 -- src/mesa/drivers/dri/mach64/mach64_vb.c | 1 - 10 files changed, 23 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/mach64/mach64_context.c b/src/mesa/drivers/dri/mach64/mach64_context.c index 2bca293..37cea9d 100644 --- a/src/mesa/drivers/dri/mach64/mach64_context.c +++ b/src/mesa/drivers/dri/mach64/mach64_context.c @@ -33,8 +33,6 @@ #include "main/context.h" #include "main/simple_list.h" #include "main/imports.h" -#include "main/matrix.h" -#include "main/extensions.h" #include "swrast/swrast.h" #include "swrast_setup/swrast_setup.h" diff --git a/src/mesa/drivers/dri/mach64/mach64_dd.c b/src/mesa/drivers/dri/mach64/mach64_dd.c index e400e9a..ca713e2 100644 --- a/src/mesa/drivers/dri/mach64/mach64_dd.c +++ b/src/mesa/drivers/dri/mach64/mach64_dd.c @@ -31,12 +31,9 @@ #include "mach64_context.h" #include "mach64_ioctl.h" -#include "mach64_state.h" -#include "mach64_vb.h" #include "mach64_dd.h" #include "main/context.h" -#include "main/framebuffer.h" #include "utils.h" diff --git a/src/mesa/drivers/dri/mach64/mach64_lock.c b/src/mesa/drivers/dri/mach64/mach64_lock.c index d018ba4..f7ef4da 100644 --- a/src/mesa/drivers/dri/mach64/mach64_lock.c +++ b/src/mesa/drivers/dri/mach64/mach64_lock.c @@ -32,7 +32,6 @@ #include "mach64_context.h" #include "mach64_state.h" #include "mach64_lock.h" -#include "mach64_tex.h" #include "drirenderbuffer.h" #if DEBUG_LOCKING diff --git a/src/mesa/drivers/dri/mach64/mach64_screen.c b/src/mesa/drivers/dri/mach64/mach64_screen.c index 3b19cf5..61e1745 100644 --- a/src/mesa/drivers/dri/mach64/mach64_screen.c +++ b/src/mesa/drivers/dri/mach64/mach64_screen.c @@ -31,8 +31,6 @@ #include "mach64_context.h" #include "mach64_ioctl.h" -#include "mach64_tris.h" -#include "mach64_vb.h" #include "mach64_span.h" #include "main/context.h" diff --git a/src/mesa/drivers/dri/mach64/mach64_span.c b/src/mesa/drivers/dri/mach64/mach64_span.c index 500319e..d9d1244 100644 --- a/src/mesa/drivers/dri/mach64/mach64_span.c +++ b/src/mesa/drivers/dri/mach64/mach64_span.c @@ -31,7 +31,6 @@ #include "mach64_context.h" #include "mach64_ioctl.h" -#include "mach64_state.h" #include "mach64_span.h" #include "swrast/swrast.h" diff --git a/src/mesa/drivers/dri/mach64/mach64_state.c b/src/mesa/drivers/dri/mach64/mach64_state.c index 3a02318..754ed86 100644 --- a/src/mesa/drivers/dri/mach64/mach64_state.c +++ b/src/mesa/drivers/dri/mach64/mach64_state.c @@ -36,7 +36,6 @@ #include "mach64_vb.h" #include "mach64_tex.h" -#include "main/context.h" #include "main/enums.h" #include "main/colormac.h" #include "swrast/swrast.h" @@ -44,8 +43,6 @@ #include "tnl/tnl.h" #include "swrast_setup/swrast_setup.h" -#include "tnl/t_pipeline.h" - /* ============================================================= * Alpha blending diff --git a/src/mesa/drivers/dri/mach64/mach64_tex.c b/src/mesa/drivers/dri/mach64/mach64_tex.c index a757362..2e85336 100644 --- a/src/mesa/drivers/dri/mach64/mach64_tex.c +++ b/src/mesa/drivers/dri/mach64/mach64_tex.c @@ -31,13 +31,8 @@ #include "mach64_context.h" #include "mach64_ioctl.h" -#include "mach64_state.h" -#include "mach64_vb.h" -#include "mach64_tris.h" #include "mach64_tex.h" -#include "main/context.h" -#include "main/macros.h" #include "main/simple_list.h" #include "main/enums.h" #include "main/texstore.h" diff --git a/src/mesa/drivers/dri/mach64/mach64_texmem.c b/src/mesa/drivers/dri/mach64/mach64_texmem.c index b97e9ee..46cee43 100644 --- a/src/mesa/drivers/dri/mach64/mach64_texmem.c +++ b/src/mesa/drivers/dri/mach64/mach64_texmem.c @@ -37,10 +37,7 @@ #include "main/imports.h" #include "mach64_context.h" -#include "mach64_state.h" #include "mach64_ioctl.h" -#include "mach64_vb.h" -#include "mach64_tris.h" #include "mach64_tex.h" diff --git a/src/mesa/drivers/dri/mach64/mach64_texstate.c b/src/mesa/drivers/dri/mach64/mach64_texstate.c index df0a09a..adf774e 100644 --- a/src/mesa/drivers/dri/mach64/mach64_texstate.c +++ b/src/mesa/drivers/dri/mach64/mach64_texstate.c @@ -36,8 +36,6 @@ #include "mach64_context.h" #include "mach64_ioctl.h" -#include "mach64_state.h" -#include "mach64_vb.h" #include "mach64_tris.h" #include "mach64_tex.h" diff --git a/src/mesa/drivers/dri/mach64/mach64_vb.c b/src/mesa/drivers/dri/mach64/mach64_vb.c index e58812e..00da835 100644 --- a/src/mesa/drivers/dri/mach64/mach64_vb.c +++ b/src/mesa/drivers/dri/mach64/mach64_vb.c @@ -42,7 +42,6 @@ #include "mach64_vb.h" #include "mach64_ioctl.h" #include "mach64_tris.h" -#include "mach64_state.h" #define MACH64_TEX1_BIT 0x1 -- cgit v1.1 From 2cf8164065b8704e2f32d77af14cde9e7979435c Mon Sep 17 00:00:00 2001 From: Roland Scheidegger Date: Thu, 21 Jan 2010 17:30:16 -0500 Subject: r200: fix CS section size mismatch Partial fix for fdo bug 25544 The tex handling will still need CS drm changes, see bug 25544 for more. --- src/mesa/drivers/dri/r200/r200_state_init.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/r200/r200_state_init.c b/src/mesa/drivers/dri/r200/r200_state_init.c index 6c5a0b7..80b08dc 100644 --- a/src/mesa/drivers/dri/r200/r200_state_init.c +++ b/src/mesa/drivers/dri/r200/r200_state_init.c @@ -698,7 +698,8 @@ static void tex_emit_mm(GLcontext *ctx, struct radeon_state_atom *atom) uint32_t dwords = atom->check(ctx, atom); int i = atom->idx; radeonTexObj *t = r200->state.texture.unit[i].texobj; - if (!r200->state.texture.unit[i].unitneeded) + + if (!r200->state.texture.unit[i].unitneeded && !(dwords <= atom->cmd_size)) dwords -= 4; BEGIN_BATCH_NO_AUTOSTATE(dwords); -- cgit v1.1 From 8410f7cde30cc1170ae266cf3a0eb7e0e37c454a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Fonseca?= Date: Thu, 21 Jan 2010 09:42:05 -0800 Subject: mesa: Use pipe_buffer_write_nooverlap where appropriate. --- src/mesa/state_tracker/st_cb_bitmap.c | 10 +++++----- src/mesa/state_tracker/st_cb_clear.c | 8 ++++---- src/mesa/state_tracker/st_inlines.h | 10 ++++++++++ 3 files changed, 19 insertions(+), 9 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_bitmap.c b/src/mesa/state_tracker/st_cb_bitmap.c index 4b85bf2..8602f6d 100644 --- a/src/mesa/state_tracker/st_cb_bitmap.c +++ b/src/mesa/state_tracker/st_cb_bitmap.c @@ -386,11 +386,11 @@ setup_bitmap_vertex_data(struct st_context *st, } /* put vertex data into vbuf */ - st_no_flush_pipe_buffer_write(st, - st->bitmap.vbuf, - st->bitmap.vbuf_slot * sizeof st->bitmap.vertices, - sizeof st->bitmap.vertices, - st->bitmap.vertices); + st_no_flush_pipe_buffer_write_nooverlap(st, + st->bitmap.vbuf, + st->bitmap.vbuf_slot * sizeof st->bitmap.vertices, + sizeof st->bitmap.vertices, + st->bitmap.vertices); return st->bitmap.vbuf_slot++ * sizeof st->bitmap.vertices; } diff --git a/src/mesa/state_tracker/st_cb_clear.c b/src/mesa/state_tracker/st_cb_clear.c index 7c0d74a..3aa4b03 100644 --- a/src/mesa/state_tracker/st_cb_clear.c +++ b/src/mesa/state_tracker/st_cb_clear.c @@ -162,10 +162,10 @@ draw_quad(GLcontext *ctx, } /* put vertex data into vbuf */ - st_no_flush_pipe_buffer_write(st, st->clear.vbuf, - st->clear.vbuf_slot * sizeof(st->clear.vertices), - sizeof(st->clear.vertices), - st->clear.vertices); + st_no_flush_pipe_buffer_write_nooverlap(st, st->clear.vbuf, + st->clear.vbuf_slot * sizeof(st->clear.vertices), + sizeof(st->clear.vertices), + st->clear.vertices); /* draw */ util_draw_vertex_buffer(pipe, diff --git a/src/mesa/state_tracker/st_inlines.h b/src/mesa/state_tracker/st_inlines.h index a41cfeb..dccc46f 100644 --- a/src/mesa/state_tracker/st_inlines.h +++ b/src/mesa/state_tracker/st_inlines.h @@ -126,6 +126,16 @@ st_no_flush_pipe_buffer_write(struct st_context *st, } static INLINE void +st_no_flush_pipe_buffer_write_nooverlap(struct st_context *st, + struct pipe_buffer *buf, + unsigned int offset, + unsigned int size, + const void * data) +{ + pipe_buffer_write_nooverlap(st->pipe->screen, buf, offset, size, data); +} + +static INLINE void st_cond_flush_pipe_buffer_read(struct st_context *st, struct pipe_buffer *buf, unsigned int offset, -- cgit v1.1 From 3f6d732bfbe36b87f735d4f2287b21ad2ddd7535 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 21 Jan 2010 23:41:57 -0800 Subject: st/mesa: Remove unnecessary header from st_cb_viewport.c. --- src/mesa/state_tracker/st_cb_viewport.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_viewport.c b/src/mesa/state_tracker/st_cb_viewport.c index d8bd244..b29191a 100644 --- a/src/mesa/state_tracker/st_cb_viewport.c +++ b/src/mesa/state_tracker/st_cb_viewport.c @@ -32,7 +32,6 @@ #include "pipe/p_context.h" #include "pipe/p_state.h" #include "pipe/p_defines.h" -#include "pipe/internal/p_winsys_screen.h" static void st_viewport(GLcontext * ctx, GLint x, GLint y, -- cgit v1.1 From 96280c2a41e5fda570ba37ff5fca87f2cde59234 Mon Sep 17 00:00:00 2001 From: Ruediger Oertel Date: Fri, 22 Jan 2010 06:53:27 -0800 Subject: Fix PowerPC related typo in spantmp2.h Signed-off-by: Matthias Hopf Signed-off-by: Brian Paul --- src/mesa/drivers/dri/common/spantmp2.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/common/spantmp2.h b/src/mesa/drivers/dri/common/spantmp2.h index 447f3d1..c152226 100644 --- a/src/mesa/drivers/dri/common/spantmp2.h +++ b/src/mesa/drivers/dri/common/spantmp2.h @@ -400,7 +400,7 @@ # define READ_RGBA( rgba, _x, _y ) \ do { \ GLuint p = GET_VALUE(_x, _y); \ - *((uint32_t *) rgba) = (t << 8) | 0xff; \ + *((uint32_t *) rgba) = (p << 8) | 0xff; \ } while (0) # else # define READ_RGBA( rgba, _x, _y ) \ -- cgit v1.1