From: Thomas Hellstrom Date: Tue, 28 Apr 2009 12:43:41 +0000 (+0200) Subject: gallium dri st: Propagate the drawable info when we bind to new drawables. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=2c994ad3cb91288966bdc028b0afa9935a51a971;p=mesa.git gallium dri st: Propagate the drawable info when we bind to new drawables. Signed-off-by: Thomas Hellstrom --- 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);