summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2012-02-24 02:25:25 +0100
committerMarek Olšák <[email protected]>2012-02-24 02:28:59 +0100
commita0a9e56cfed1ab81c1068cffbfd9299f77c7e187 (patch)
tree11333dae27973ffc2a4a9d92ee626d8c54d9ec0a /src/gallium
parent59fbd8c6bea1a6420b6fe3bb75d1ea64c054a8b3 (diff)
u_blitter: decrease minimum buffer range alignment to 4 for copy_buffer
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/auxiliary/util/u_blitter.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gallium/auxiliary/util/u_blitter.c b/src/gallium/auxiliary/util/u_blitter.c
index be420ec1556..48808ae084d 100644
--- a/src/gallium/auxiliary/util/u_blitter.c
+++ b/src/gallium/auxiliary/util/u_blitter.c
@@ -241,7 +241,7 @@ struct blitter_context *util_blitter_create(struct pipe_context *pipe)
}
if (ctx->has_stream_out) {
- velem[0].src_format = PIPE_FORMAT_R32G32B32A32_FLOAT;
+ velem[0].src_format = PIPE_FORMAT_R32_UINT;
ctx->velem_state_readbuf = pipe->create_vertex_elements_state(pipe, 1, &velem[0]);
}
@@ -263,8 +263,8 @@ struct blitter_context *util_blitter_create(struct pipe_context *pipe)
memset(&so, 0, sizeof(so));
so.num_outputs = 1;
- so.output[0].num_components = 4;
- so.stride[0] = 4;
+ so.output[0].num_components = 1;
+ so.stride[0] = 1;
ctx->vs_pos_only =
util_make_vertex_passthrough_shader_with_so(pipe, 1, semantic_names,
@@ -1263,7 +1263,7 @@ void util_blitter_copy_buffer(struct blitter_context *blitter,
assert(ctx->has_stream_out);
/* Some alignment is required. */
- if (srcx % 4 != 0 || dstx % 4 != 0 || size % 16 != 0 ||
+ if (srcx % 4 != 0 || dstx % 4 != 0 || size % 4 != 0 ||
!ctx->has_stream_out) {
struct pipe_box box;
u_box_1d(srcx, size, &box);
@@ -1288,7 +1288,7 @@ void util_blitter_copy_buffer(struct blitter_context *blitter,
so_target = pipe->create_stream_output_target(pipe, dst, dstx, size);
pipe->set_stream_output_targets(pipe, 1, &so_target, 0);
- util_draw_arrays(pipe, PIPE_PRIM_POINTS, 0, size / 16);
+ util_draw_arrays(pipe, PIPE_PRIM_POINTS, 0, size / 4);
blitter_restore_vertex_states(ctx);
blitter_unset_running_flag(ctx);