gallium/u_blitter: remove useless parameter from blitter_default_dst_texture
authorMarek Olšák <maraeo@gmail.com>
Wed, 19 Dec 2012 21:25:22 +0000 (22:25 +0100)
committerMarek Olšák <maraeo@gmail.com>
Fri, 4 Jan 2013 13:05:40 +0000 (14:05 +0100)
Reviewed-by: Brian Paul <brianp@vmware.com>
src/gallium/auxiliary/util/u_blitter.c
src/gallium/auxiliary/util/u_blitter.h
src/gallium/drivers/r300/r300_blit.c
src/gallium/drivers/r600/r600_blit.c

index 7c7e062194c8a92cd0ebf99a6cdb1056717e0513..b6eca3e61305cd91a0a6fddf687e21b6949ed07a 100644 (file)
@@ -1056,14 +1056,13 @@ void util_blitter_custom_clear_depth(struct blitter_context *blitter,
 void util_blitter_default_dst_texture(struct pipe_surface *dst_templ,
                                       struct pipe_resource *dst,
                                       unsigned dstlevel,
-                                      unsigned dstz,
-                                      const struct pipe_box *srcbox)
+                                      unsigned dstz)
 {
     memset(dst_templ, 0, sizeof(*dst_templ));
     dst_templ->format = util_format_linear(dst->format);
     dst_templ->u.tex.level = dstlevel;
     dst_templ->u.tex.first_layer = dstz;
-    dst_templ->u.tex.last_layer = dstz + srcbox->depth - 1;
+    dst_templ->u.tex.last_layer = dstz;
 }
 
 void util_blitter_default_src_texture(struct pipe_sampler_view *src_templ,
@@ -1181,7 +1180,7 @@ void util_blitter_copy_texture(struct blitter_context *blitter,
    assert(src->target < PIPE_MAX_TEXTURE_TYPES);
 
    /* Initialize the surface. */
-   util_blitter_default_dst_texture(&dst_templ, dst, dst_level, dstz, srcbox);
+   util_blitter_default_dst_texture(&dst_templ, dst, dst_level, dstz);
    dst_view = pipe->create_surface(pipe, dst, &dst_templ);
 
    /* Initialize the sampler view. */
@@ -1419,7 +1418,7 @@ util_blitter_blit(struct blitter_context *blitter,
 
    /* Initialize the surface. */
    util_blitter_default_dst_texture(&dst_templ, dst, info->dst.level,
-                                    info->dst.box.z, &info->src.box);
+                                    info->dst.box.z);
    dst_templ.format = info->dst.format;
    dst_view = pipe->create_surface(pipe, dst, &dst_templ);
 
index 0b5e4aa45dccc59db3d2b355e308a01c89a095fe..162f436de7918f647662fa8835ebcd317962d633 100644 (file)
@@ -255,8 +255,7 @@ void util_blitter_blit(struct blitter_context *blitter,
 void util_blitter_default_dst_texture(struct pipe_surface *dst_templ,
                                       struct pipe_resource *dst,
                                       unsigned dstlevel,
-                                      unsigned dstz,
-                                      const struct pipe_box *srcbox);
+                                      unsigned dstz);
 
 /**
  * Helper function to initialize a view for copy_texture_view.
index b4df3f2b0c1329dae610d9232338eb737c0a865f..70b81e64231a9e65a982205150c069371a14f8b7 100644 (file)
@@ -482,7 +482,7 @@ static void r300_resource_copy_region(struct pipe_context *pipe,
      * on hardware. E.g. depth-stencil surfaces are copied as RGBA
      * colorbuffers. */
 
-    util_blitter_default_dst_texture(&dst_templ, dst, dst_level, dstz, src_box);
+    util_blitter_default_dst_texture(&dst_templ, dst, dst_level, dstz);
     util_blitter_default_src_texture(&src_templ, src, src_level);
 
     layout = util_format_description(dst_templ.format)->layout;
index 87b90ac444ea5cdccb696de40d7f9cbd302870c1..b4e9136416c0b2af279a49bc951d35dff3baefde 100644 (file)
@@ -569,7 +569,7 @@ static void r600_resource_copy_region(struct pipe_context *ctx,
        src_widthFL = rsrc->surface.level[src_level].npix_x;
        src_heightFL = rsrc->surface.level[src_level].npix_y;
 
-       util_blitter_default_dst_texture(&dst_templ, dst, dst_level, dstz, src_box);
+       util_blitter_default_dst_texture(&dst_templ, dst, dst_level, dstz);
        util_blitter_default_src_texture(&src_templ, src, src_level);
 
        if (util_format_is_compressed(src->format)) {