mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-20 09:30:13 +01:00
iris: add struct iris_scissor_state because pipe_scissor_state will be changed
to use 32-bit integer. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38587>
This commit is contained in:
parent
5c63446b94
commit
193e494e6a
2 changed files with 8 additions and 4 deletions
|
|
@ -832,6 +832,10 @@ enum iris_context_priority {
|
||||||
IRIS_CONTEXT_HIGH_PRIORITY
|
IRIS_CONTEXT_HIGH_PRIORITY
|
||||||
};
|
};
|
||||||
|
|
||||||
|
struct iris_scissor_state {
|
||||||
|
uint16_t minx, miny, maxx, maxy;
|
||||||
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The API context (derived from pipe_context).
|
* The API context (derived from pipe_context).
|
||||||
*
|
*
|
||||||
|
|
@ -1005,7 +1009,7 @@ struct iris_context {
|
||||||
struct pipe_blend_color blend_color;
|
struct pipe_blend_color blend_color;
|
||||||
struct pipe_poly_stipple poly_stipple;
|
struct pipe_poly_stipple poly_stipple;
|
||||||
struct pipe_viewport_state viewports[IRIS_MAX_VIEWPORTS];
|
struct pipe_viewport_state viewports[IRIS_MAX_VIEWPORTS];
|
||||||
struct pipe_scissor_state scissors[IRIS_MAX_VIEWPORTS];
|
struct iris_scissor_state scissors[IRIS_MAX_VIEWPORTS];
|
||||||
struct pipe_stencil_ref stencil_ref;
|
struct pipe_stencil_ref stencil_ref;
|
||||||
PIPE_FB_SURFACES; //STOP USING THIS
|
PIPE_FB_SURFACES; //STOP USING THIS
|
||||||
struct pipe_framebuffer_state framebuffer;
|
struct pipe_framebuffer_state framebuffer;
|
||||||
|
|
|
||||||
|
|
@ -3726,11 +3726,11 @@ iris_set_scissor_states(struct pipe_context *ctx,
|
||||||
* a min > max scissor inside the bounds, which produces the expected
|
* a min > max scissor inside the bounds, which produces the expected
|
||||||
* no rendering.
|
* no rendering.
|
||||||
*/
|
*/
|
||||||
ice->state.scissors[start_slot + i] = (struct pipe_scissor_state) {
|
ice->state.scissors[start_slot + i] = (struct iris_scissor_state) {
|
||||||
.minx = 1, .maxx = 0, .miny = 1, .maxy = 0,
|
.minx = 1, .maxx = 0, .miny = 1, .maxy = 0,
|
||||||
};
|
};
|
||||||
} else {
|
} else {
|
||||||
ice->state.scissors[start_slot + i] = (struct pipe_scissor_state) {
|
ice->state.scissors[start_slot + i] = (struct iris_scissor_state) {
|
||||||
.minx = rects[i].minx, .miny = rects[i].miny,
|
.minx = rects[i].minx, .miny = rects[i].miny,
|
||||||
.maxx = rects[i].maxx - 1, .maxy = rects[i].maxy - 1,
|
.maxx = rects[i].maxx - 1, .maxy = rects[i].maxy - 1,
|
||||||
};
|
};
|
||||||
|
|
@ -10784,7 +10784,7 @@ genX(init_state)(struct iris_context *ice)
|
||||||
|
|
||||||
/* Default all scissor rectangles to be empty regions. */
|
/* Default all scissor rectangles to be empty regions. */
|
||||||
for (int i = 0; i < IRIS_MAX_VIEWPORTS; i++) {
|
for (int i = 0; i < IRIS_MAX_VIEWPORTS; i++) {
|
||||||
ice->state.scissors[i] = (struct pipe_scissor_state) {
|
ice->state.scissors[i] = (struct iris_scissor_state) {
|
||||||
.minx = 1, .maxx = 0, .miny = 1, .maxy = 0,
|
.minx = 1, .maxx = 0, .miny = 1, .maxy = 0,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue