mesa: Remove the Initialized field from framebuffers. 28/7128/1
authorEric Anholt <eric@anholt.net>
Thu, 20 Jun 2013 16:41:10 +0000 (09:41 -0700)
committerEric Anholt <eric@anholt.net>
Wed, 26 Jun 2013 02:19:20 +0000 (19:19 -0700)
This existed to tell the core not to call GetBufferSize, except that even
if you didn't set it nothing happened because nobody had a GetBufferSize.

v2: Remove two more instances of setting the field (from Brian)

Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/intel/intel_fbo.c
src/mesa/drivers/dri/radeon/radeon_common.c
src/mesa/drivers/dri/radeon/radeon_fbo.c
src/mesa/drivers/osmesa/osmesa.c
src/mesa/drivers/x11/xm_api.c
src/mesa/main/mtypes.h
src/mesa/state_tracker/st_manager.c

index 5fe3dc7..32d1797 100644 (file)
@@ -339,8 +339,6 @@ intel_resize_buffers(struct gl_context *ctx, struct gl_framebuffer *fb,
 
    _mesa_resize_framebuffer(ctx, fb, width, height);
 
-   fb->Initialized = true; /* XXX remove someday */
-
    if (_mesa_is_user_fbo(fb)) {
       return;
    }
index 0cf656b..0f0945d 100644 (file)
@@ -85,7 +85,6 @@ void radeonSetCliprects(radeonContextPtr radeon)
            (draw_rfb->base.Height != drawable->h)) {
                _mesa_resize_framebuffer(&radeon->glCtx, &draw_rfb->base,
                                         drawable->w, drawable->h);
-               draw_rfb->base.Initialized = GL_TRUE;
        }
 
        if (drawable != readable) {
@@ -93,7 +92,6 @@ void radeonSetCliprects(radeonContextPtr radeon)
                    (read_rfb->base.Height != readable->h)) {
                        _mesa_resize_framebuffer(&radeon->glCtx, &read_rfb->base,
                                                 readable->w, readable->h);
-                       read_rfb->base.Initialized = GL_TRUE;
                }
        }
 
index 63bc7e8..29a6d79 100644 (file)
@@ -635,8 +635,6 @@ radeon_resize_buffers(struct gl_context *ctx, struct gl_framebuffer *fb,
 
    _mesa_resize_framebuffer(ctx, fb, width, height);
 
-   fb->Initialized = GL_TRUE; /* XXX remove someday */
-
    if (fb->Name != 0) {
       return;
    }
index 241e74f..deb0b93 100644 (file)
@@ -916,7 +916,6 @@ OSMesaMakeCurrent( OSMesaContext osmesa, void *buffer, GLenum type,
     * osmesa_renderbuffer_storage() function to get called.
     */
    _mesa_resize_framebuffer(&osmesa->mesa, osmesa->gl_buffer, width, height);
-   osmesa->gl_buffer->Initialized = GL_TRUE; /* XXX TEMPORARY? */
 
    _mesa_make_current( &osmesa->mesa, osmesa->gl_buffer, osmesa->gl_buffer );
 
index 6455889..b7c94aa 100644 (file)
@@ -1193,7 +1193,6 @@ xmesa_check_and_update_buffer_size(XMesaContext xmctx, XMesaBuffer drawBuffer)
       struct gl_context *ctx = xmctx ? &xmctx->mesa : NULL;
       _mesa_resize_framebuffer(ctx, &(drawBuffer->mesa_buffer), width, height);
    }
-   drawBuffer->mesa_buffer.Initialized = GL_TRUE; /* XXX TEMPORARY? */
 }
 
 
index 0002da5..5d5b534 100644 (file)
@@ -2680,8 +2680,6 @@ struct gl_framebuffer
     */
    struct gl_config Visual;
 
-   GLboolean Initialized;
-
    GLuint Width, Height;       /**< size of frame buffer in pixels */
 
    /** \name  Drawing bounds (Intersection of buffer size and scissor box) */
index ec87608..9c2b4d2 100644 (file)
@@ -431,8 +431,6 @@ st_framebuffer_create(struct st_framebuffer_iface *stfbi)
    stfb->stamp = 0;
    st_framebuffer_update_attachments(stfb);
 
-   stfb->Base.Initialized = GL_TRUE;
-
    return stfb;
 }