From 2c994ad3cb91288966bdc028b0afa9935a51a971 Mon Sep 17 00:00:00 2001 From: Thomas Hellstrom Date: Tue, 28 Apr 2009 14:43:41 +0200 Subject: gallium dri st: Propagate the drawable info when we bind to new drawables. Signed-off-by: Thomas Hellstrom --- src/gallium/state_trackers/dri/dri_context.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'src/gallium/state_trackers/dri') diff --git a/src/gallium/state_trackers/dri/dri_context.c b/src/gallium/state_trackers/dri/dri_context.c index 54d2a563565..45eaec4ed39 100644 --- a/src/gallium/state_trackers/dri/dri_context.c +++ b/src/gallium/state_trackers/dri/dri_context.c @@ -158,9 +158,14 @@ dri_make_current(__DRIcontextPrivate * cPriv, */ screen->dummyContext = ctx; - /* used in dri_flush_frontbuffer */ - ctx->dPriv = driDrawPriv; - ctx->rPriv = driReadPriv; + if (ctx->dPriv != driDrawPriv) { + ctx->dPriv = driDrawPriv; + ctx->d_stamp = driDrawPriv->lastStamp - 1; + } + if (ctx->rPriv != driReadPriv) { + ctx->rPriv = driReadPriv; + ctx->r_stamp = driReadPriv->lastStamp - 1; + } st_make_current(ctx->st, draw->stfb, read->stfb); -- cgit v1.2.3