[Mesa-dev] [PATCH 2/7] gallium/util: remove util_draw_range_elements helper
Ilia Mirkin
imirkin at alum.mit.edu
Fri Apr 14 15:48:26 UTC 2017
On Fri, Apr 14, 2017 at 11:07 AM, Marek Olšák <maraeo at gmail.com> wrote:
> From: Marek Olšák <marek.olsak at amd.com>
>
> min/max_index are typically hints for the u_vbuf module, not the driver.
nv30, nv50, and nvc0 all use them to configure vbo limits to prevent
out-of-bounds reads.
That said, if nothing uses this function (which appears to be the
case), then whatever.
Reviewed-by: Ilia Mirkin <imirkin at alum.mit.edu>
> ---
> src/gallium/auxiliary/util/u_draw.h | 23 -----------------------
> 1 file changed, 23 deletions(-)
>
> diff --git a/src/gallium/auxiliary/util/u_draw.h b/src/gallium/auxiliary/util/u_draw.h
> index b16f106..b6ea3de 100644
> --- a/src/gallium/auxiliary/util/u_draw.h
> +++ b/src/gallium/auxiliary/util/u_draw.h
> @@ -122,43 +122,20 @@ util_draw_elements_instanced(struct pipe_context *pipe,
> info.mode = mode;
> info.start = start;
> info.count = count;
> info.index_bias = index_bias;
> info.start_instance = start_instance;
> info.instance_count = instance_count;
>
> pipe->draw_vbo(pipe, &info);
> }
>
> -static inline void
> -util_draw_range_elements(struct pipe_context *pipe,
> - int index_bias,
> - uint min_index,
> - uint max_index,
> - enum pipe_prim_type mode,
> - uint start,
> - uint count)
> -{
> - struct pipe_draw_info info;
> -
> - util_draw_init_info(&info);
> - info.indexed = TRUE;
> - info.mode = mode;
> - info.start = start;
> - info.count = count;
> - info.index_bias = index_bias;
> - info.min_index = min_index;
> - info.max_index = max_index;
> -
> - pipe->draw_vbo(pipe, &info);
> -}
> -
>
> /* This converts an indirect draw into a direct draw by mapping the indirect
> * buffer, extracting its arguments, and calling pipe->draw_vbo.
> */
> void
> util_draw_indirect(struct pipe_context *pipe,
> const struct pipe_draw_info *info);
>
>
> unsigned
> --
> 2.7.4
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list