[Mesa-dev] [PATCH v2 06/15] draw: remove unused wideline_stage()

Roland Scheidegger sroland at vmware.com
Tue Apr 11 21:04:49 UTC 2017


You could remove the half_line_width in the struct wideline_stage too
while you're at it - I think the whole reason why the wideline_stage()
function existed in the first place was to have easy access to that
variable.
But either way,
Reviewed-by: Roland Scheidegger <sroland at vmware.com>

Am 11.04.2017 um 21:58 schrieb Samuel Pitoiset:
> Fixes the following Clang warning.
> 
> draw/draw_pipe_wide_line.c:48:38: warning: unused function 'wideline_stage' [-Wunused-function]
> static inline struct wideline_stage *wideline_stage( struct draw_stage *stage )
>                                      ^
> 1 warning generated.
> 
> v2: - remove commented code (Roland Scheidegger)
> 
> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
> ---
>  src/gallium/auxiliary/draw/draw_pipe_wide_line.c | 9 ---------
>  1 file changed, 9 deletions(-)
> 
> diff --git a/src/gallium/auxiliary/draw/draw_pipe_wide_line.c b/src/gallium/auxiliary/draw/draw_pipe_wide_line.c
> index ae4a00eb63..103f080491 100644
> --- a/src/gallium/auxiliary/draw/draw_pipe_wide_line.c
> +++ b/src/gallium/auxiliary/draw/draw_pipe_wide_line.c
> @@ -44,21 +44,12 @@ struct wideline_stage {
>  };
>  
>  
> -
> -static inline struct wideline_stage *wideline_stage( struct draw_stage *stage )
> -{
> -   return (struct wideline_stage *)stage;
> -}
> -
> -
> -
>  /**
>   * Draw a wide line by drawing a quad (two triangles).
>   */
>  static void wideline_line( struct draw_stage *stage,
>                             struct prim_header *header )
>  {
> -   /*const struct wideline_stage *wide = wideline_stage(stage);*/
>     const unsigned pos = draw_current_shader_position_output(stage->draw);
>     const float half_width = 0.5f * stage->draw->rasterizer->line_width;
>  
> 



More information about the mesa-dev mailing list