summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/brw_clip_state.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_clip_state.c')
-rw-r--r--src/mesa/drivers/dri/i965/brw_clip_state.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_clip_state.c b/src/mesa/drivers/dri/i965/brw_clip_state.c
index a0bdb43..021acc8 100644
--- a/src/mesa/drivers/dri/i965/brw_clip_state.c
+++ b/src/mesa/drivers/dri/i965/brw_clip_state.c
@@ -43,8 +43,8 @@ upload_clip_vp(struct brw_context *brw)
sizeof(*vp), 32, &brw->clip.vp_offset);
const float maximum_post_clamp_delta = 4096;
- float gbx = maximum_post_clamp_delta / (float) ctx->Viewport.Width;
- float gby = maximum_post_clamp_delta / (float) ctx->Viewport.Height;
+ float gbx = maximum_post_clamp_delta / ctx->Viewport.Width;
+ float gby = maximum_post_clamp_delta / ctx->Viewport.Height;
vp->xmin = -gbx;
vp->xmax = gbx;
@@ -127,8 +127,8 @@ brw_upload_clip_unit(struct brw_context *brw)
/* enable guardband clipping if we can */
if (ctx->Viewport.X == 0 &&
ctx->Viewport.Y == 0 &&
- ctx->Viewport.Width == fb->Width &&
- ctx->Viewport.Height == fb->Height)
+ ctx->Viewport.Width == (float) fb->Width &&
+ ctx->Viewport.Height == (float) fb->Height)
{
clip->clip5.guard_band_enable = 1;
clip->clip6.clipper_viewport_state_ptr =