summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@bitplanet.net>2010-01-01 21:37:41 -0500
committerKristian Høgsberg <krh@bitplanet.net>2010-01-04 11:48:02 -0500
commit5bc4b886e412e01260af9cf9c8bd7c01f1dece19 (patch)
treea10b86764b5d88f2e2e521ed966bbb68a03163c5 /src/mesa
parent5203b7227ccb6b618fa42f08434d4a3cf123dca2 (diff)
intel: Drop intelWindowMoved()
Everything this functions does under DRI2 is also taken care of by intel_draw_buffer(), which is always called where intelWindowMoved() is called.
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/intel/intel_context.c2
-rw-r--r--src/mesa/drivers/dri/intel/intel_swapbuffers.c79
2 files changed, 0 insertions, 81 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_context.c b/src/mesa/drivers/dri/intel/intel_context.c
index f03d1141da..4a17711cfe 100644
--- a/src/mesa/drivers/dri/intel/intel_context.c
+++ b/src/mesa/drivers/dri/intel/intel_context.c
@@ -412,7 +412,6 @@ intel_viewport(GLcontext *ctx, GLint x, GLint y, GLsizei w, GLsizei h)
old_viewport = ctx->Driver.Viewport;
ctx->Driver.Viewport = NULL;
intel->driDrawable = driContext->driDrawablePriv;
- intelWindowMoved(intel);
intel_draw_buffer(ctx, intel->ctx.DrawBuffer);
ctx->Driver.Viewport = old_viewport;
}
@@ -929,7 +928,6 @@ intelMakeCurrent(__DRIcontext * driContextPriv,
}
}
intel->driDrawable = driDrawPriv;
- intelWindowMoved(intel);
}
intel_draw_buffer(&intel->ctx, &intel_fb->Base);
diff --git a/src/mesa/drivers/dri/intel/intel_swapbuffers.c b/src/mesa/drivers/dri/intel/intel_swapbuffers.c
index 9f563e7c1d..65441495a7 100644
--- a/src/mesa/drivers/dri/intel/intel_swapbuffers.c
+++ b/src/mesa/drivers/dri/intel/intel_swapbuffers.c
@@ -79,82 +79,3 @@ intelFixupVblank(struct intel_context *intel, __DRIdrawable *dPriv)
return dPriv->vblFlags & ~VBLANK_FLAG_SECONDARY;
}
}
-
-/**
- * This will be called whenever the currently bound window is moved/resized.
- * XXX: actually, it seems to NOT be called when the window is only moved (BP).
- */
-void
-intelWindowMoved(struct intel_context *intel)
-{
- GLcontext *ctx = &intel->ctx;
- __DRIdrawable *dPriv = intel->driDrawable;
- struct intel_framebuffer *intel_fb = dPriv->driverPrivate;
-
- if (!intel->intelScreen->driScrnPriv->dri2.enabled &&
- intel->intelScreen->driScrnPriv->ddx_version.minor >= 7) {
- GLuint flags = intelFixupVblank(intel, dPriv);
-
- /* Check to see if we changed pipes */
- if (flags != dPriv->vblFlags && dPriv->vblFlags &&
- !(dPriv->vblFlags & VBLANK_FLAG_NO_IRQ)) {
- int64_t count;
- drmVBlank vbl;
- int i;
-
- /*
- * Deal with page flipping
- */
- vbl.request.type = DRM_VBLANK_ABSOLUTE;
-
- if ( dPriv->vblFlags & VBLANK_FLAG_SECONDARY ) {
- vbl.request.type |= DRM_VBLANK_SECONDARY;
- }
-
- for (i = 0; i < 2; i++) {
- if (!intel_fb->color_rb[i] ||
- (intel_fb->vbl_waited - intel_fb->color_rb[i]->vbl_pending) <=
- (1<<23))
- continue;
-
- vbl.request.sequence = intel_fb->color_rb[i]->vbl_pending;
- drmWaitVBlank(intel->driFd, &vbl);
- }
-
- /*
- * Update msc_base from old pipe
- */
- driDrawableGetMSC32(dPriv->driScreenPriv, dPriv, &count);
- dPriv->msc_base = count;
- /*
- * Then get new vblank_base and vblSeq values
- */
- dPriv->vblFlags = flags;
- driGetCurrentVBlank(dPriv);
- dPriv->vblank_base = dPriv->vblSeq;
-
- intel_fb->vbl_waited = dPriv->vblSeq;
-
- for (i = 0; i < 2; i++) {
- if (intel_fb->color_rb[i])
- intel_fb->color_rb[i]->vbl_pending = intel_fb->vbl_waited;
- }
- }
- } else {
- dPriv->vblFlags &= ~VBLANK_FLAG_SECONDARY;
- }
-
- /* Update Mesa's notion of window size */
- driUpdateFramebufferSize(ctx, dPriv);
- intel_fb->Base.Initialized = GL_TRUE; /* XXX remove someday */
-
- /* Update hardware scissor */
- if (ctx->Driver.Scissor != NULL) {
- ctx->Driver.Scissor(ctx, ctx->Scissor.X, ctx->Scissor.Y,
- ctx->Scissor.Width, ctx->Scissor.Height);
- }
-
- /* Re-calculate viewport related state */
- if (ctx->Driver.DepthRange != NULL)
- ctx->Driver.DepthRange( ctx, ctx->Viewport.Near, ctx->Viewport.Far );
-}