Mesa (mesa_7_5_branch): util: reformatting and comments

Brian Paul brianp at kemper.freedesktop.org
Wed Aug 5 19:50:51 UTC 2009


Module: Mesa
Branch: mesa_7_5_branch
Commit: 854ea483d4debcbff56c5a5a8e90c3dcce51f350
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=854ea483d4debcbff56c5a5a8e90c3dcce51f350

Author: Brian Paul <brianp at vmware.com>
Date:   Wed Aug  5 12:40:50 2009 -0600

util: reformatting and comments

---

 src/gallium/auxiliary/util/u_blit.c |   13 ++++++++++---
 1 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/src/gallium/auxiliary/util/u_blit.c b/src/gallium/auxiliary/util/u_blit.c
index 414cf91..261a9b6 100644
--- a/src/gallium/auxiliary/util/u_blit.c
+++ b/src/gallium/auxiliary/util/u_blit.c
@@ -155,7 +155,11 @@ util_destroy_blit(struct blit_state *ctx)
 }
 
 
-static unsigned get_next_slot( struct blit_state *ctx )
+/**
+ * Get offset of next free slot in vertex buffer for quad vertices.
+ */
+static unsigned
+get_next_slot( struct blit_state *ctx )
 {
    const unsigned max_slots = 4096 / sizeof ctx->vertices;
 
@@ -173,7 +177,6 @@ static unsigned get_next_slot( struct blit_state *ctx )
 }
                                
 
-
 /**
  * Setup vertex data for the textured quad we'll draw.
  * Note: y=0=top
@@ -260,6 +263,8 @@ setup_vertex_data_tex(struct blit_state *ctx,
 
    return offset;
 }
+
+
 /**
  * Copy pixel block from src surface to dst surface.
  * Overlapping regions are acceptable.
@@ -308,7 +313,9 @@ util_blit_pixels(struct blit_state *ctx,
    assert(screen->is_format_supported(screen, dst->format, PIPE_TEXTURE_2D,
                                       PIPE_TEXTURE_USAGE_SAMPLER, 0));
 
-   if(dst->format == src->format && (dstX1 - dstX0) == srcW && (dstY1 - dstY0) == srcH) {
+   if (dst->format == src->format &&
+       (dstX1 - dstX0) == srcW &&
+       (dstY1 - dstY0) == srcH) {
       /* FIXME: this will most surely fail for overlapping rectangles */
       pipe->surface_copy(pipe,
 			 dst, dstX0, dstY0,   /* dest */




More information about the mesa-commit mailing list