mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-04 22:49:13 +02:00
vulkan/runtime: add helper to name dirty states
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24536>
This commit is contained in:
parent
44656f98d5
commit
8d66ff01b1
2 changed files with 74 additions and 0 deletions
|
|
@ -2882,3 +2882,74 @@ vk_common_CmdSetDepthBias2EXT(
|
|||
rs.depth_bias.exact, false);
|
||||
}
|
||||
}
|
||||
|
||||
const char *
|
||||
vk_dynamic_graphic_state_to_str(enum mesa_vk_dynamic_graphics_state state)
|
||||
{
|
||||
#define NAME(name) \
|
||||
case MESA_VK_DYNAMIC_##name: return #name
|
||||
|
||||
switch (state) {
|
||||
NAME(VI);
|
||||
NAME(VI_BINDINGS_VALID);
|
||||
NAME(VI_BINDING_STRIDES);
|
||||
NAME(IA_PRIMITIVE_TOPOLOGY);
|
||||
NAME(IA_PRIMITIVE_RESTART_ENABLE);
|
||||
NAME(TS_PATCH_CONTROL_POINTS);
|
||||
NAME(TS_DOMAIN_ORIGIN);
|
||||
NAME(VP_VIEWPORT_COUNT);
|
||||
NAME(VP_VIEWPORTS);
|
||||
NAME(VP_SCISSOR_COUNT);
|
||||
NAME(VP_SCISSORS);
|
||||
NAME(VP_DEPTH_CLIP_NEGATIVE_ONE_TO_ONE);
|
||||
NAME(DR_RECTANGLES);
|
||||
NAME(DR_MODE);
|
||||
NAME(DR_ENABLE);
|
||||
NAME(RS_RASTERIZER_DISCARD_ENABLE);
|
||||
NAME(RS_DEPTH_CLAMP_ENABLE);
|
||||
NAME(RS_DEPTH_CLIP_ENABLE);
|
||||
NAME(RS_POLYGON_MODE);
|
||||
NAME(RS_CULL_MODE);
|
||||
NAME(RS_FRONT_FACE);
|
||||
NAME(RS_CONSERVATIVE_MODE);
|
||||
NAME(RS_EXTRA_PRIMITIVE_OVERESTIMATION_SIZE);
|
||||
NAME(RS_RASTERIZATION_ORDER_AMD);
|
||||
NAME(RS_PROVOKING_VERTEX);
|
||||
NAME(RS_RASTERIZATION_STREAM);
|
||||
NAME(RS_DEPTH_BIAS_ENABLE);
|
||||
NAME(RS_DEPTH_BIAS_FACTORS);
|
||||
NAME(RS_LINE_WIDTH);
|
||||
NAME(RS_LINE_MODE);
|
||||
NAME(RS_LINE_STIPPLE_ENABLE);
|
||||
NAME(RS_LINE_STIPPLE);
|
||||
NAME(FSR);
|
||||
NAME(MS_RASTERIZATION_SAMPLES);
|
||||
NAME(MS_SAMPLE_MASK);
|
||||
NAME(MS_ALPHA_TO_COVERAGE_ENABLE);
|
||||
NAME(MS_ALPHA_TO_ONE_ENABLE);
|
||||
NAME(MS_SAMPLE_LOCATIONS_ENABLE);
|
||||
NAME(MS_SAMPLE_LOCATIONS);
|
||||
NAME(DS_DEPTH_TEST_ENABLE);
|
||||
NAME(DS_DEPTH_WRITE_ENABLE);
|
||||
NAME(DS_DEPTH_COMPARE_OP);
|
||||
NAME(DS_DEPTH_BOUNDS_TEST_ENABLE);
|
||||
NAME(DS_DEPTH_BOUNDS_TEST_BOUNDS);
|
||||
NAME(DS_STENCIL_TEST_ENABLE);
|
||||
NAME(DS_STENCIL_OP);
|
||||
NAME(DS_STENCIL_COMPARE_MASK);
|
||||
NAME(DS_STENCIL_WRITE_MASK);
|
||||
NAME(DS_STENCIL_REFERENCE);
|
||||
NAME(CB_LOGIC_OP_ENABLE);
|
||||
NAME(CB_LOGIC_OP);
|
||||
NAME(CB_ATTACHMENT_COUNT);
|
||||
NAME(CB_COLOR_WRITE_ENABLES);
|
||||
NAME(CB_BLEND_ENABLES);
|
||||
NAME(CB_BLEND_EQUATIONS);
|
||||
NAME(CB_WRITE_MASKS);
|
||||
NAME(CB_BLEND_CONSTANTS);
|
||||
NAME(ATTACHMENT_FEEDBACK_LOOP_ENABLE);
|
||||
default: unreachable("Invalid state");
|
||||
}
|
||||
|
||||
#undef NAME
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1119,6 +1119,9 @@ void
|
|||
vk_cmd_set_cb_attachment_count(struct vk_command_buffer *cmd,
|
||||
uint32_t attachment_count);
|
||||
|
||||
const char *
|
||||
vk_dynamic_graphic_state_to_str(enum mesa_vk_dynamic_graphics_state state);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue