diff options
author | Brian Paul <[email protected]> | 2012-11-30 10:04:48 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2012-11-30 12:08:06 -0700 |
commit | c73245882c7ff1277b190b97f093f7b423a22f10 (patch) | |
tree | cc42fc6cc7cd175407d511e845f75c49383936fc /src/mesa/main/shared.c | |
parent | ca3ed3e024864e91ca3cccc59fb96950e1d079b5 (diff) |
mesa: pass context parameter to gl_renderbuffer::Delete()
We sometimes need a rendering context when deleting renderbuffers.
Pass it explicitly instead of trying to grab a current context
(which might be NULL). The next patch will make use of this.
Note: this is a candidate for the stable branches.
Reviewed-by: Jose Fonseca <[email protected]>
Diffstat (limited to 'src/mesa/main/shared.c')
-rw-r--r-- | src/mesa/main/shared.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/main/shared.c b/src/mesa/main/shared.c index ba82628f3eb..eaf9f8de1b1 100644 --- a/src/mesa/main/shared.c +++ b/src/mesa/main/shared.c @@ -253,10 +253,11 @@ delete_framebuffer_cb(GLuint id, void *data, void *userData) static void delete_renderbuffer_cb(GLuint id, void *data, void *userData) { + struct gl_context *ctx = (struct gl_context *) userData; struct gl_renderbuffer *rb = (struct gl_renderbuffer *) data; rb->RefCount = 0; /* see comment for FBOs above */ if (rb->Delete) - rb->Delete(rb); + rb->Delete(ctx, rb); } |