diff options
author | Christian König <[email protected]> | 2010-12-03 18:57:23 +0100 |
---|---|---|
committer | Christian König <[email protected]> | 2010-12-03 19:04:01 +0100 |
commit | 9af3c243d958dd5b9802dda321ab980c83cb8cb8 (patch) | |
tree | 1888934754e3e55ca82cb99517d61047e74cdec9 /src/gallium/auxiliary/vl/vl_vertex_buffers.h | |
parent | 29840040af128fe3f3542defd9448e1f66c23f03 (diff) |
move empty block handling back into mc for testing
Diffstat (limited to 'src/gallium/auxiliary/vl/vl_vertex_buffers.h')
-rw-r--r-- | src/gallium/auxiliary/vl/vl_vertex_buffers.h | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/src/gallium/auxiliary/vl/vl_vertex_buffers.h b/src/gallium/auxiliary/vl/vl_vertex_buffers.h index 43ddc342d3d..fa4ec1dedd8 100644 --- a/src/gallium/auxiliary/vl/vl_vertex_buffers.h +++ b/src/gallium/auxiliary/vl/vl_vertex_buffers.h @@ -41,31 +41,17 @@ struct pipe_vertex_buffer vl_vb_upload_quads(struct pipe_context *pipe, unsigned bool vl_vb_init(struct vl_vertex_buffer *buffer, unsigned max_blocks); -static inline bool -vl_vb_add_block(struct vl_vertex_buffer *buffer, bool allow_merge, signed x, signed y) +static inline void +vl_vb_add_block(struct vl_vertex_buffer *buffer, signed x, signed y) { struct quadf *quad; assert(buffer); - allow_merge &= buffer->num_blocks > 0; - if (allow_merge) { - - quad = buffer->blocks + buffer->num_blocks - 1; - if(quad->tr.x == (x - 1) && quad->br.x == (x - 1) && - quad->tr.y == y && quad->br.y == y) { - - quad->tr.x = quad->br.x = x; - quad->tr.y = quad->br.y = y; - return true; - } - } - quad = buffer->blocks + buffer->num_blocks; quad->bl.x = quad->tl.x = quad->tr.x = quad->br.x = x; quad->bl.y = quad->tl.y = quad->tr.y = quad->br.y = y; buffer->num_blocks++; - return false; } unsigned vl_vb_upload(struct vl_vertex_buffer *buffer, struct quadf *dst); |