diff options
author | Brian Paul <[email protected]> | 2009-01-29 14:57:31 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2009-01-29 14:57:31 -0700 |
commit | 5c38801f8e36fdb4a16ed33c26454b98f3519465 (patch) | |
tree | 38849ed2e1dc74c1432a4c75b6f0fdca74482743 | |
parent | ba3aadf354e197ab56adddc99c3b3335d7e6863e (diff) |
intel: formatting clean-ups
-rw-r--r-- | src/mesa/drivers/dri/intel/intel_fbo.c | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c index 53a74f5c0b3..659d206bc85 100644 --- a/src/mesa/drivers/dri/intel/intel_fbo.c +++ b/src/mesa/drivers/dri/intel/intel_fbo.c @@ -61,6 +61,7 @@ intel_new_framebuffer(GLcontext * ctx, GLuint name) } +/** Called by gl_renderbuffer::Delete() */ static void intel_delete_renderbuffer(struct gl_renderbuffer *rb) { @@ -81,7 +82,6 @@ intel_delete_renderbuffer(struct gl_renderbuffer *rb) } - /** * Return a pointer to a specific pixel in a renderbuffer. */ @@ -96,7 +96,6 @@ intel_get_pointer(GLcontext * ctx, struct gl_renderbuffer *rb, } - /** * Called via glRenderbufferStorageEXT() to set the format and allocate * storage for a user-created renderbuffer. @@ -227,7 +226,6 @@ intel_alloc_renderbuffer_storage(GLcontext * ctx, struct gl_renderbuffer *rb, } - /** * Called for each hardware renderbuffer when a _window_ is resized. * Just update fields. @@ -245,6 +243,7 @@ intel_alloc_window_storage(GLcontext * ctx, struct gl_renderbuffer *rb, return GL_TRUE; } + static void intel_resize_buffers(GLcontext *ctx, struct gl_framebuffer *fb, GLuint width, GLuint height) @@ -271,6 +270,8 @@ intel_resize_buffers(GLcontext *ctx, struct gl_framebuffer *fb, } } + +/** Dummy function for gl_renderbuffer::AllocStorage() */ static GLboolean intel_nop_alloc_storage(GLcontext * ctx, struct gl_renderbuffer *rb, GLenum internalFormat, GLuint width, GLuint height) @@ -292,6 +293,7 @@ intel_renderbuffer_set_region(struct intel_renderbuffer *rb, intel_region_release(&old); } + /** * Create a new intel_renderbuffer which corresponds to an on-screen window, * not a user-created renderbuffer. @@ -434,6 +436,7 @@ intel_framebuffer_renderbuffer(GLcontext * ctx, intel_draw_buffer(ctx, fb); } + static GLboolean intel_update_wrapper(GLcontext *ctx, struct intel_renderbuffer *irb, struct gl_texture_image *texImage) @@ -485,6 +488,7 @@ intel_update_wrapper(GLcontext *ctx, struct intel_renderbuffer *irb, return GL_TRUE; } + /** * When glFramebufferTexture[123]D is called this function sets up the * gl_renderbuffer wrapper around the texture image. @@ -493,7 +497,7 @@ intel_update_wrapper(GLcontext *ctx, struct intel_renderbuffer *irb, static struct intel_renderbuffer * intel_wrap_texture(GLcontext * ctx, struct gl_texture_image *texImage) { - const GLuint name = ~0; /* not significant, but distinct for debugging */ + const GLuint name = ~0; /* not significant, but distinct for debugging */ struct intel_renderbuffer *irb; /* make an intel_renderbuffer to wrap the texture image */ @@ -540,10 +544,11 @@ intel_render_texture(GLcontext * ctx, /* Fallback on drawing to a texture with a border, which won't have a * miptree. */ - _mesa_reference_renderbuffer(&att->Renderbuffer, NULL); - _mesa_render_texture(ctx, fb, att); - return; - } else if (!irb) { + _mesa_reference_renderbuffer(&att->Renderbuffer, NULL); + _mesa_render_texture(ctx, fb, att); + return; + } + else if (!irb) { irb = intel_wrap_texture(ctx, newImage); if (irb) { /* bind the wrapper to the attachment point */ @@ -554,7 +559,9 @@ intel_render_texture(GLcontext * ctx, _mesa_render_texture(ctx, fb, att); return; } - } if (!intel_update_wrapper(ctx, irb, newImage)) { + } + + if (!intel_update_wrapper(ctx, irb, newImage)) { _mesa_reference_renderbuffer(&att->Renderbuffer, NULL); _mesa_render_texture(ctx, fb, att); return; |