summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/util
diff options
context:
space:
mode:
authorJose Fonseca <[email protected]>2015-12-02 17:48:29 +0000
committerJose Fonseca <[email protected]>2015-12-02 17:49:20 +0000
commit4a3d388834dc25c5925301343757ee21ffa26253 (patch)
tree2483632c437c68bb67f94c804dd9f189f220ed84 /src/gallium/auxiliary/util
parentd31065cbf61f0a510c5563263820a8f0a1100ec7 (diff)
util/blitter: Fix "SO C90 forbids mixed declarations and code".
Trivial.
Diffstat (limited to 'src/gallium/auxiliary/util')
-rw-r--r--src/gallium/auxiliary/util/u_blitter.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gallium/auxiliary/util/u_blitter.c b/src/gallium/auxiliary/util/u_blitter.c
index 759c88f97ab..05b4567130e 100644
--- a/src/gallium/auxiliary/util/u_blitter.c
+++ b/src/gallium/auxiliary/util/u_blitter.c
@@ -1825,6 +1825,7 @@ void util_blitter_clear_render_target(struct blitter_context *blitter,
struct blitter_context_priv *ctx = (struct blitter_context_priv*)blitter;
struct pipe_context *pipe = ctx->base.pipe;
struct pipe_framebuffer_state fb_state;
+ unsigned num_layers;
assert(dstsurf->texture);
if (!dstsurf->texture)
@@ -1854,7 +1855,7 @@ void util_blitter_clear_render_target(struct blitter_context *blitter,
blitter_set_dst_dimensions(ctx, dstsurf->width, dstsurf->height);
- unsigned num_layers = dstsurf->u.tex.last_layer - dstsurf->u.tex.first_layer + 1;
+ num_layers = dstsurf->u.tex.last_layer - dstsurf->u.tex.first_layer + 1;
if (num_layers > 1 && ctx->has_layered) {
blitter_set_common_draw_rect_state(ctx, FALSE, TRUE);
blitter_set_clear_color(ctx, color);
@@ -1886,6 +1887,7 @@ void util_blitter_clear_depth_stencil(struct blitter_context *blitter,
struct pipe_context *pipe = ctx->base.pipe;
struct pipe_framebuffer_state fb_state;
struct pipe_stencil_ref sr = { { 0 } };
+ unsigned num_layers;
assert(dstsurf->texture);
if (!dstsurf->texture)
@@ -1931,7 +1933,7 @@ void util_blitter_clear_depth_stencil(struct blitter_context *blitter,
blitter_set_dst_dimensions(ctx, dstsurf->width, dstsurf->height);
- unsigned num_layers = dstsurf->u.tex.last_layer - dstsurf->u.tex.first_layer + 1;
+ num_layers = dstsurf->u.tex.last_layer - dstsurf->u.tex.first_layer + 1;
if (num_layers > 1 && ctx->has_layered) {
blitter_set_common_draw_rect_state(ctx, FALSE, TRUE);
blitter_draw(ctx, dstx, dsty, dstx+width, dsty+height, (float) depth, num_layers);