diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2022-02-24 02:30:08 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2022-02-24 02:30:08 +0000 |
commit | 1d35364040c0ffa99133522fa5ab3bd6131d8bf7 (patch) | |
tree | 0ea3d9ca4ad10692c6477168b67e98cb50ea6bd3 /lib/mesa/src/gallium/drivers/llvmpipe/lp_setup_context.h | |
parent | b24b5b9049e889ee4eb39b565bcc8d48bd45ab48 (diff) |
Merge Mesa 21.3.7
Diffstat (limited to 'lib/mesa/src/gallium/drivers/llvmpipe/lp_setup_context.h')
-rw-r--r-- | lib/mesa/src/gallium/drivers/llvmpipe/lp_setup_context.h | 70 |
1 files changed, 63 insertions, 7 deletions
diff --git a/lib/mesa/src/gallium/drivers/llvmpipe/lp_setup_context.h b/lib/mesa/src/gallium/drivers/llvmpipe/lp_setup_context.h index 82fc14b5e..656a64f40 100644 --- a/lib/mesa/src/gallium/drivers/llvmpipe/lp_setup_context.h +++ b/lib/mesa/src/gallium/drivers/llvmpipe/lp_setup_context.h @@ -96,13 +96,17 @@ struct lp_setup_context struct llvmpipe_query *active_queries[LP_MAX_ACTIVE_BINNED_QUERIES]; unsigned active_binned_queries; - boolean flatshade_first; - boolean ccw_is_frontface; - boolean scissor_test; - boolean point_size_per_vertex; - boolean rasterizer_discard; - boolean multisample; - unsigned cullmode; + unsigned flatshade_first:1; + unsigned ccw_is_frontface:1; + unsigned scissor_test:1; + unsigned point_tri_clip:1; + unsigned point_size_per_vertex:1; + unsigned legacy_points:1; + unsigned rasterizer_discard:1; + unsigned permit_linear_rasterizer:1; + unsigned multisample:1; + unsigned rectangular_lines:1; + unsigned cullmode:2; /**< PIPE_FACE_x */ unsigned bottom_edge_rule; float pixel_offset; float line_width; @@ -115,6 +119,7 @@ struct lp_setup_context struct pipe_framebuffer_state fb; struct u_rect framebuffer; struct u_rect scissors[PIPE_MAX_VIEWPORTS]; + struct u_rect vpwh; struct u_rect draw_regions[PIPE_MAX_VIEWPORTS]; /* intersection of fb & scissor */ struct lp_jit_viewport viewports[PIPE_MAX_VIEWPORTS]; @@ -177,6 +182,15 @@ struct lp_setup_context const float (*v0)[4], const float (*v1)[4], const float (*v2)[4]); + + boolean + (*rect)( struct lp_setup_context *, + const float (*v0)[4], + const float (*v1)[4], + const float (*v2)[4], + const float (*v3)[4], + const float (*v4)[4], + const float (*v5)[4]); }; static inline void @@ -193,10 +207,15 @@ scissor_planes_needed(boolean scis_planes[4], const struct u_rect *bbox, scis_planes[3] = (bbox->y1 > scissor->y1); } +void +lp_setup_add_scissor_planes(const struct u_rect *scissor, + struct lp_rast_plane *plane_s, + boolean s_planes[4], bool multisample); void lp_setup_choose_triangle( struct lp_setup_context *setup ); void lp_setup_choose_line( struct lp_setup_context *setup ); void lp_setup_choose_point( struct lp_setup_context *setup ); +void lp_setup_choose_rect( struct lp_setup_context *setup ); void lp_setup_init_vbuf(struct lp_setup_context *setup); @@ -207,6 +226,15 @@ void lp_setup_destroy( struct lp_setup_context *setup ); boolean lp_setup_flush_and_restart(struct lp_setup_context *setup); +boolean +lp_setup_whole_tile(struct lp_setup_context *setup, + const struct lp_rast_shader_inputs *inputs, + int tx, int ty); + +boolean +lp_setup_is_blit(const struct lp_setup_context *setup, + const struct lp_rast_shader_inputs *inputs); + void lp_setup_print_triangle(struct lp_setup_context *setup, const float (*v0)[4], @@ -218,6 +246,19 @@ lp_setup_print_vertex(struct lp_setup_context *setup, const char *name, const float (*v)[4]); +void +lp_rect_cw(struct lp_setup_context *setup, + const float (*v0)[4], + const float (*v1)[4], + const float (*v2)[4], + boolean frontfacing); + +void +lp_setup_triangle_ccw( struct lp_setup_context *setup, + const float (*v0)[4], + const float (*v1)[4], + const float (*v2)[4], + boolean front ); struct lp_rast_triangle * lp_setup_alloc_triangle(struct lp_scene *scene, @@ -225,6 +266,16 @@ lp_setup_alloc_triangle(struct lp_scene *scene, unsigned nr_planes, unsigned *tri_size); +struct lp_rast_rectangle * +lp_setup_alloc_rectangle(struct lp_scene *scene, + unsigned nr_inputs); + +boolean +lp_setup_analyse_triangles(struct lp_setup_context *setup, + const void *vb, + int stride, + int nr); + boolean lp_setup_bin_triangle(struct lp_setup_context *setup, struct lp_rast_triangle *tri, @@ -233,4 +284,9 @@ lp_setup_bin_triangle(struct lp_setup_context *setup, int nr_planes, unsigned scissor_index); +boolean +lp_setup_bin_rectangle(struct lp_setup_context *setup, + struct lp_rast_rectangle *rect); + + #endif |