diff options
Diffstat (limited to 'src/mesa/drivers/dri/r200/r200_context.c')
-rw-r--r-- | src/mesa/drivers/dri/r200/r200_context.c | 23 |
1 files changed, 7 insertions, 16 deletions
diff --git a/src/mesa/drivers/dri/r200/r200_context.c b/src/mesa/drivers/dri/r200/r200_context.c index 06b2a152d9..bb7a16c932 100644 --- a/src/mesa/drivers/dri/r200/r200_context.c +++ b/src/mesa/drivers/dri/r200/r200_context.c @@ -87,21 +87,6 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. int R200_DEBUG = (0); #endif - -/* Return the width and height of the given buffer. - */ -static void r200GetBufferSize( GLframebuffer *buffer, - GLuint *width, GLuint *height ) -{ - GET_CURRENT_CONTEXT(ctx); - r200ContextPtr rmesa = R200_CONTEXT(ctx); - - LOCK_HARDWARE( rmesa ); - *width = rmesa->dri.drawable->w; - *height = rmesa->dri.drawable->h; - UNLOCK_HARDWARE( rmesa ); -} - /* Return various strings for glGetString(). */ static const GLubyte *r200GetString( GLcontext *ctx, GLenum name ) @@ -233,7 +218,7 @@ static const struct tnl_pipeline_stage *r200_pipeline[] = { */ static void r200InitDriverFuncs( struct dd_function_table *functions ) { - functions->GetBufferSize = r200GetBufferSize; + functions->GetBufferSize = NULL; /* OBSOLETE */ functions->GetString = r200GetString; } @@ -700,7 +685,13 @@ r200MakeCurrent( __DRIcontextPrivate *driContextPriv, if ( newCtx->dri.drawable != driDrawPriv ) { driDrawableInitVBlank( driDrawPriv, newCtx->vblank_flags, &newCtx->vbl_seq ); + } + + if ( newCtx->dri.drawable != driDrawPriv || + newCtx->dri.readable != driReadPriv ) { newCtx->dri.drawable = driDrawPriv; + newCtx->dri.readable = driReadPriv; + r200UpdateWindow( newCtx->glCtx ); r200UpdateViewportOffset( newCtx->glCtx ); } |