mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 06:30:10 +01:00
compiler: Drop now unused gl_varying_slot_name()
There's reuse of values depending on the stage, so a function that just takes the value might produce invalid results. All the codebase was already changed to use the gl_varying_slot_name_for_stage() instead. Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8998>
This commit is contained in:
parent
b5716cadc5
commit
a36d5bf11b
2 changed files with 5 additions and 10 deletions
|
|
@ -155,8 +155,11 @@ gl_vert_attrib_name(gl_vert_attrib attrib)
|
|||
}
|
||||
|
||||
const char *
|
||||
gl_varying_slot_name(gl_varying_slot slot)
|
||||
gl_varying_slot_name_for_stage(gl_varying_slot slot, gl_shader_stage stage)
|
||||
{
|
||||
if (stage != MESA_SHADER_FRAGMENT && slot == VARYING_SLOT_PRIMITIVE_SHADING_RATE)
|
||||
return "VARYING_SLOT_PRIMITIVE_SHADING_RATE";
|
||||
|
||||
static const char *names[] = {
|
||||
ENUM(VARYING_SLOT_POS),
|
||||
ENUM(VARYING_SLOT_COL0),
|
||||
|
|
@ -227,14 +230,6 @@ gl_varying_slot_name(gl_varying_slot slot)
|
|||
return NAME(slot);
|
||||
}
|
||||
|
||||
const char *
|
||||
gl_varying_slot_name_for_stage(gl_varying_slot slot, gl_shader_stage stage)
|
||||
{
|
||||
if (stage != MESA_SHADER_FRAGMENT && slot == VARYING_SLOT_PRIMITIVE_SHADING_RATE)
|
||||
return "VARYING_SLOT_PRIMITIVE_SHADING_RATE";
|
||||
return gl_varying_slot_name(slot);
|
||||
}
|
||||
|
||||
const char *
|
||||
gl_system_value_name(gl_system_value sysval)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -253,6 +253,7 @@ const char *gl_vert_attrib_name(gl_vert_attrib attrib);
|
|||
* - vertResults (in prog_print.c's arb_output_attrib_string())
|
||||
* - fragAttribs (in prog_print.c's arb_input_attrib_string())
|
||||
* - _mesa_varying_slot_in_fs()
|
||||
* - _mesa_varying_slot_name_for_stage()
|
||||
*/
|
||||
typedef enum
|
||||
{
|
||||
|
|
@ -332,7 +333,6 @@ typedef enum
|
|||
#define VARYING_SLOT_TESS_MAX (VARYING_SLOT_PATCH0 + MAX_VARYING)
|
||||
#define MAX_VARYINGS_INCL_PATCH (VARYING_SLOT_TESS_MAX - VARYING_SLOT_VAR0)
|
||||
|
||||
const char *gl_varying_slot_name(gl_varying_slot slot);
|
||||
const char *gl_varying_slot_name_for_stage(gl_varying_slot slot,
|
||||
gl_shader_stage stage);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue