summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/i965
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/i965')
-rw-r--r--src/gallium/drivers/i965/brw_batchbuffer.c2
-rw-r--r--src/gallium/drivers/i965/brw_batchbuffer.h4
-rw-r--r--src/gallium/drivers/i965/brw_cc.c1
-rw-r--r--src/gallium/drivers/i965/brw_clip.c1
-rw-r--r--src/gallium/drivers/i965/brw_clip_line.c1
-rw-r--r--src/gallium/drivers/i965/brw_clip_point.c1
-rw-r--r--src/gallium/drivers/i965/brw_clip_tri.c1
-rw-r--r--src/gallium/drivers/i965/brw_clip_util.c1
-rw-r--r--src/gallium/drivers/i965/brw_context.c1
-rw-r--r--src/gallium/drivers/i965/brw_curbe.c2
-rw-r--r--src/gallium/drivers/i965/brw_draw.c1
-rw-r--r--src/gallium/drivers/i965/brw_gs.c1
-rw-r--r--src/gallium/drivers/i965/brw_gs_emit.c1
-rw-r--r--src/gallium/drivers/i965/brw_pipe_blend.c22
-rw-r--r--src/gallium/drivers/i965/brw_pipe_fb.c1
-rw-r--r--src/gallium/drivers/i965/brw_pipe_sampler.c1
-rw-r--r--src/gallium/drivers/i965/brw_screen.c9
-rw-r--r--src/gallium/drivers/i965/brw_sf.c1
-rw-r--r--src/gallium/drivers/i965/brw_sf_emit.c1
-rw-r--r--src/gallium/drivers/i965/brw_state_cache.c1
-rw-r--r--src/gallium/drivers/i965/brw_util.c2
-rw-r--r--src/gallium/drivers/i965/brw_vs.c2
-rw-r--r--src/gallium/drivers/i965/brw_vs_surface_state.c1
-rw-r--r--src/gallium/drivers/i965/brw_wm_fp.c1
-rw-r--r--src/gallium/drivers/i965/brw_wm_surface_state.c1
25 files changed, 23 insertions, 38 deletions
diff --git a/src/gallium/drivers/i965/brw_batchbuffer.c b/src/gallium/drivers/i965/brw_batchbuffer.c
index 22607dc6083..003b1fd5bf0 100644
--- a/src/gallium/drivers/i965/brw_batchbuffer.c
+++ b/src/gallium/drivers/i965/brw_batchbuffer.c
@@ -155,7 +155,7 @@ _brw_batchbuffer_flush(struct brw_batchbuffer *batch,
enum pipe_error
brw_batchbuffer_emit_reloc(struct brw_batchbuffer *batch,
struct brw_winsys_buffer *buffer,
- uint32_t usage,
+ enum brw_buffer_usage usage,
uint32_t delta)
{
int ret;
diff --git a/src/gallium/drivers/i965/brw_batchbuffer.h b/src/gallium/drivers/i965/brw_batchbuffer.h
index 7473f5bea4d..6ca9f617f5e 100644
--- a/src/gallium/drivers/i965/brw_batchbuffer.h
+++ b/src/gallium/drivers/i965/brw_batchbuffer.h
@@ -64,12 +64,12 @@ brw_batchbuffer_reset(struct brw_batchbuffer *batch);
* Consider it a convenience function wrapping multple
* intel_buffer_dword() calls.
*/
-int brw_batchbuffer_data(struct brw_batchbuffer *batch,
+enum pipe_error brw_batchbuffer_data(struct brw_batchbuffer *batch,
const void *data, GLuint bytes,
enum cliprect_mode cliprect_mode);
-int brw_batchbuffer_emit_reloc(struct brw_batchbuffer *batch,
+enum pipe_error brw_batchbuffer_emit_reloc(struct brw_batchbuffer *batch,
struct brw_winsys_buffer *buffer,
enum brw_buffer_usage usage,
uint32_t offset);
diff --git a/src/gallium/drivers/i965/brw_cc.c b/src/gallium/drivers/i965/brw_cc.c
index 3e070f5591a..4a543276f54 100644
--- a/src/gallium/drivers/i965/brw_cc.c
+++ b/src/gallium/drivers/i965/brw_cc.c
@@ -32,7 +32,6 @@
#include "brw_context.h"
#include "brw_state.h"
-#include "brw_defines.h"
static enum pipe_error prepare_cc_vp( struct brw_context *brw )
diff --git a/src/gallium/drivers/i965/brw_clip.c b/src/gallium/drivers/i965/brw_clip.c
index d67a1a62633..ccba205e8c7 100644
--- a/src/gallium/drivers/i965/brw_clip.c
+++ b/src/gallium/drivers/i965/brw_clip.c
@@ -38,7 +38,6 @@
#include "brw_defines.h"
#include "brw_context.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_state.h"
#include "brw_pipe_rast.h"
#include "brw_clip.h"
diff --git a/src/gallium/drivers/i965/brw_clip_line.c b/src/gallium/drivers/i965/brw_clip_line.c
index 54282d975ed..66caadc4d53 100644
--- a/src/gallium/drivers/i965/brw_clip_line.c
+++ b/src/gallium/drivers/i965/brw_clip_line.c
@@ -33,7 +33,6 @@
#include "brw_defines.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_clip.h"
diff --git a/src/gallium/drivers/i965/brw_clip_point.c b/src/gallium/drivers/i965/brw_clip_point.c
index e0a5330556d..124156c1b50 100644
--- a/src/gallium/drivers/i965/brw_clip_point.c
+++ b/src/gallium/drivers/i965/brw_clip_point.c
@@ -31,7 +31,6 @@
#include "brw_defines.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_clip.h"
diff --git a/src/gallium/drivers/i965/brw_clip_tri.c b/src/gallium/drivers/i965/brw_clip_tri.c
index 4cde7294ea0..069524bc14f 100644
--- a/src/gallium/drivers/i965/brw_clip_tri.c
+++ b/src/gallium/drivers/i965/brw_clip_tri.c
@@ -31,7 +31,6 @@
#include "brw_defines.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_clip.h"
static void release_tmps( struct brw_clip_compile *c )
diff --git a/src/gallium/drivers/i965/brw_clip_util.c b/src/gallium/drivers/i965/brw_clip_util.c
index 97a57103105..23e51ee9bcd 100644
--- a/src/gallium/drivers/i965/brw_clip_util.c
+++ b/src/gallium/drivers/i965/brw_clip_util.c
@@ -32,7 +32,6 @@
#include "brw_defines.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_clip.h"
diff --git a/src/gallium/drivers/i965/brw_context.c b/src/gallium/drivers/i965/brw_context.c
index e67551882dc..d60b7b99b6e 100644
--- a/src/gallium/drivers/i965/brw_context.c
+++ b/src/gallium/drivers/i965/brw_context.c
@@ -34,7 +34,6 @@
#include "util/u_simple_list.h"
#include "brw_context.h"
-#include "brw_defines.h"
#include "brw_draw.h"
#include "brw_state.h"
#include "brw_batchbuffer.h"
diff --git a/src/gallium/drivers/i965/brw_curbe.c b/src/gallium/drivers/i965/brw_curbe.c
index 3f031577d5a..4b215a001c4 100644
--- a/src/gallium/drivers/i965/brw_curbe.c
+++ b/src/gallium/drivers/i965/brw_curbe.c
@@ -36,9 +36,7 @@
#include "brw_context.h"
#include "brw_defines.h"
#include "brw_state.h"
-#include "brw_util.h"
#include "brw_debug.h"
-#include "brw_screen.h"
/**
diff --git a/src/gallium/drivers/i965/brw_draw.c b/src/gallium/drivers/i965/brw_draw.c
index ea8d39adaf0..1b5cd23995b 100644
--- a/src/gallium/drivers/i965/brw_draw.c
+++ b/src/gallium/drivers/i965/brw_draw.c
@@ -34,7 +34,6 @@
#include "brw_context.h"
#include "brw_state.h"
#include "brw_debug.h"
-#include "brw_screen.h"
#include "brw_batchbuffer.h"
diff --git a/src/gallium/drivers/i965/brw_gs.c b/src/gallium/drivers/i965/brw_gs.c
index 921b201bae2..06826635a8a 100644
--- a/src/gallium/drivers/i965/brw_gs.c
+++ b/src/gallium/drivers/i965/brw_gs.c
@@ -34,7 +34,6 @@
#include "brw_defines.h"
#include "brw_context.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_state.h"
#include "brw_gs.h"
diff --git a/src/gallium/drivers/i965/brw_gs_emit.c b/src/gallium/drivers/i965/brw_gs_emit.c
index fd8e2accedd..9b58773b3bd 100644
--- a/src/gallium/drivers/i965/brw_gs_emit.c
+++ b/src/gallium/drivers/i965/brw_gs_emit.c
@@ -35,7 +35,6 @@
#include "brw_defines.h"
#include "brw_context.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_gs.h"
static void brw_gs_alloc_regs( struct brw_gs_compile *c,
diff --git a/src/gallium/drivers/i965/brw_pipe_blend.c b/src/gallium/drivers/i965/brw_pipe_blend.c
index b759a910b63..21f786f8715 100644
--- a/src/gallium/drivers/i965/brw_pipe_blend.c
+++ b/src/gallium/drivers/i965/brw_pipe_blend.c
@@ -118,14 +118,14 @@ static void *brw_create_blend_state( struct pipe_context *pipe,
blend->cc2.logicop_enable = 1;
blend->cc5.logicop_func = translate_logicop(templ->logicop_func);
}
- else if (templ->blend_enable) {
- blend->cc6.dest_blend_factor = translate_blend_factor(templ->rgb_dst_factor);
- blend->cc6.src_blend_factor = translate_blend_factor(templ->rgb_src_factor);
- blend->cc6.blend_function = translate_blend_equation(templ->rgb_func);
+ else if (templ->rt[0].blend_enable) {
+ blend->cc6.dest_blend_factor = translate_blend_factor(templ->rt[0].rgb_dst_factor);
+ blend->cc6.src_blend_factor = translate_blend_factor(templ->rt[0].rgb_src_factor);
+ blend->cc6.blend_function = translate_blend_equation(templ->rt[0].rgb_func);
- blend->cc5.ia_dest_blend_factor = translate_blend_factor(templ->alpha_dst_factor);
- blend->cc5.ia_src_blend_factor = translate_blend_factor(templ->alpha_src_factor);
- blend->cc5.ia_blend_function = translate_blend_equation(templ->alpha_func);
+ blend->cc5.ia_dest_blend_factor = translate_blend_factor(templ->rt[0].alpha_dst_factor);
+ blend->cc5.ia_src_blend_factor = translate_blend_factor(templ->rt[0].alpha_src_factor);
+ blend->cc5.ia_blend_function = translate_blend_equation(templ->rt[0].alpha_func);
blend->cc3.blend_enable = 1;
blend->cc3.ia_blend_enable =
@@ -146,10 +146,10 @@ static void *brw_create_blend_state( struct pipe_context *pipe,
/* Per-surface color mask -- just follow global state:
*/
- blend->ss0.writedisable_red = (templ->colormask & PIPE_MASK_R) ? 0 : 1;
- blend->ss0.writedisable_green = (templ->colormask & PIPE_MASK_G) ? 0 : 1;
- blend->ss0.writedisable_blue = (templ->colormask & PIPE_MASK_B) ? 0 : 1;
- blend->ss0.writedisable_alpha = (templ->colormask & PIPE_MASK_A) ? 0 : 1;
+ blend->ss0.writedisable_red = (templ->rt[0].colormask & PIPE_MASK_R) ? 0 : 1;
+ blend->ss0.writedisable_green = (templ->rt[0].colormask & PIPE_MASK_G) ? 0 : 1;
+ blend->ss0.writedisable_blue = (templ->rt[0].colormask & PIPE_MASK_B) ? 0 : 1;
+ blend->ss0.writedisable_alpha = (templ->rt[0].colormask & PIPE_MASK_A) ? 0 : 1;
return (void *)blend;
}
diff --git a/src/gallium/drivers/i965/brw_pipe_fb.c b/src/gallium/drivers/i965/brw_pipe_fb.c
index 5d4e5025f97..c1f049272ac 100644
--- a/src/gallium/drivers/i965/brw_pipe_fb.c
+++ b/src/gallium/drivers/i965/brw_pipe_fb.c
@@ -3,7 +3,6 @@
#include "pipe/p_state.h"
#include "brw_context.h"
-#include "brw_debug.h"
/**
* called from intelDrawBuffer()
diff --git a/src/gallium/drivers/i965/brw_pipe_sampler.c b/src/gallium/drivers/i965/brw_pipe_sampler.c
index 81712798a5d..ef6c1bb3155 100644
--- a/src/gallium/drivers/i965/brw_pipe_sampler.c
+++ b/src/gallium/drivers/i965/brw_pipe_sampler.c
@@ -7,7 +7,6 @@
#include "brw_context.h"
#include "brw_defines.h"
-#include "brw_debug.h"
diff --git a/src/gallium/drivers/i965/brw_screen.c b/src/gallium/drivers/i965/brw_screen.c
index 0ecacac9a3a..a8f9892d71d 100644
--- a/src/gallium/drivers/i965/brw_screen.c
+++ b/src/gallium/drivers/i965/brw_screen.c
@@ -138,6 +138,9 @@ brw_get_name(struct pipe_screen *screen)
case PCI_CHIP_ILM_G:
chipset = "ILM_G";
break;
+ default:
+ chipset = "unknown";
+ break;
}
util_snprintf(buffer, sizeof(buffer), "i965 (chipset: %s)", chipset);
@@ -172,6 +175,12 @@ brw_get_param(struct pipe_screen *screen, int param)
return 8; /* max 128x128x128 */
case PIPE_CAP_MAX_TEXTURE_CUBE_LEVELS:
return 11; /* max 1024x1024 */
+ case PIPE_CAP_TGSI_FS_COORD_ORIGIN_UPPER_LEFT:
+ case PIPE_CAP_TGSI_FS_COORD_PIXEL_CENTER_HALF_INTEGER:
+ return 1;
+ case PIPE_CAP_TGSI_FS_COORD_ORIGIN_LOWER_LEFT:
+ case PIPE_CAP_TGSI_FS_COORD_PIXEL_CENTER_INTEGER:
+ return 0;
default:
return 0;
}
diff --git a/src/gallium/drivers/i965/brw_sf.c b/src/gallium/drivers/i965/brw_sf.c
index e1986a9dbbd..6e99eaa09d8 100644
--- a/src/gallium/drivers/i965/brw_sf.c
+++ b/src/gallium/drivers/i965/brw_sf.c
@@ -36,7 +36,6 @@
#include "brw_context.h"
#include "brw_pipe_rast.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_sf.h"
#include "brw_state.h"
diff --git a/src/gallium/drivers/i965/brw_sf_emit.c b/src/gallium/drivers/i965/brw_sf_emit.c
index 3b85725e368..497634ec9ed 100644
--- a/src/gallium/drivers/i965/brw_sf_emit.c
+++ b/src/gallium/drivers/i965/brw_sf_emit.c
@@ -35,7 +35,6 @@
#include "brw_defines.h"
#include "brw_context.h"
#include "brw_eu.h"
-#include "brw_util.h"
#include "brw_sf.h"
diff --git a/src/gallium/drivers/i965/brw_state_cache.c b/src/gallium/drivers/i965/brw_state_cache.c
index 16b643ceb28..85c20076fb8 100644
--- a/src/gallium/drivers/i965/brw_state_cache.c
+++ b/src/gallium/drivers/i965/brw_state_cache.c
@@ -59,7 +59,6 @@
#include "brw_debug.h"
#include "brw_state.h"
-#include "brw_batchbuffer.h"
/* XXX: Fixme - have to include these to get the sizes of the prog_key
* structs:
diff --git a/src/gallium/drivers/i965/brw_util.c b/src/gallium/drivers/i965/brw_util.c
index 458058d668d..1fd2e297137 100644
--- a/src/gallium/drivers/i965/brw_util.c
+++ b/src/gallium/drivers/i965/brw_util.c
@@ -30,8 +30,6 @@
*/
-#include "brw_util.h"
-#include "brw_defines.h"
diff --git a/src/gallium/drivers/i965/brw_vs.c b/src/gallium/drivers/i965/brw_vs.c
index e3ea5a3a135..ca8ee79550d 100644
--- a/src/gallium/drivers/i965/brw_vs.c
+++ b/src/gallium/drivers/i965/brw_vs.c
@@ -33,9 +33,7 @@
#include "brw_context.h"
#include "brw_vs.h"
-#include "brw_util.h"
#include "brw_state.h"
-#include "brw_pipe_rast.h"
diff --git a/src/gallium/drivers/i965/brw_vs_surface_state.c b/src/gallium/drivers/i965/brw_vs_surface_state.c
index 177a5170d23..004e3cb4e6f 100644
--- a/src/gallium/drivers/i965/brw_vs_surface_state.c
+++ b/src/gallium/drivers/i965/brw_vs_surface_state.c
@@ -31,7 +31,6 @@
#include "brw_context.h"
#include "brw_state.h"
-#include "brw_defines.h"
#include "brw_winsys.h"
/* XXX: disabled true constant buffer functionality
diff --git a/src/gallium/drivers/i965/brw_wm_fp.c b/src/gallium/drivers/i965/brw_wm_fp.c
index 9c5b527f897..9c67759ad0b 100644
--- a/src/gallium/drivers/i965/brw_wm_fp.c
+++ b/src/gallium/drivers/i965/brw_wm_fp.c
@@ -41,7 +41,6 @@
#include "tgsi/tgsi_util.h"
#include "brw_wm.h"
-#include "brw_util.h"
#include "brw_debug.h"
diff --git a/src/gallium/drivers/i965/brw_wm_surface_state.c b/src/gallium/drivers/i965/brw_wm_surface_state.c
index f92b8198ed3..b01a7f194b7 100644
--- a/src/gallium/drivers/i965/brw_wm_surface_state.c
+++ b/src/gallium/drivers/i965/brw_wm_surface_state.c
@@ -34,7 +34,6 @@
#include "brw_batchbuffer.h"
#include "brw_context.h"
#include "brw_state.h"
-#include "brw_defines.h"
#include "brw_screen.h"