gallium: Add PIPE_CAP_COMPUTE_SHADER_DERIVATIVES

To enable NV_compute_shader_derivatives, which allows derivatives (and
texture lookups with implicit derivatives) in compute shaders.
Reviewed-by: Kenneth Graunke's avatarKenneth Graunke <kenneth@whitecape.org>
Reviewed-by: default avatarIan Romanick <ian.d.romanick@intel.com>
parent c9d15696
......@@ -348,6 +348,9 @@ u_pipe_screen_get_param_defaults(struct pipe_screen *pscreen,
case PIPE_CAP_COMPUTE_GRID_INFO_LAST_BLOCK:
return 0;
case PIPE_CAP_COMPUTE_SHADER_DERIVATIVES:
return 0;
default:
unreachable("bad PIPE_CAP_*");
}
......
......@@ -503,6 +503,7 @@ The integer capabilities:
cases may be a smaller number.
* ``PIPE_CAP_COMPUTE_GRID_INFO_LAST_BLOCK``: Whether pipe_grid_info::last_block
is implemented by the driver. See struct pipe_grid_info for more details.
* ``PIPE_CAP_COMPUTE_SHADER_DERIVATIVE``: True if the driver supports derivatives (and texture lookups with implicit derivatives) in compute shaders.
.. _pipe_capf:
......
......@@ -865,6 +865,7 @@ enum pipe_cap
PIPE_CAP_NIR_COMPACT_ARRAYS,
PIPE_CAP_MAX_VARYINGS,
PIPE_CAP_COMPUTE_GRID_INFO_LAST_BLOCK,
PIPE_CAP_COMPUTE_SHADER_DERIVATIVES,
};
/**
......
......@@ -772,6 +772,7 @@ void st_init_extensions(struct pipe_screen *screen,
{ o(AMD_seamless_cubemap_per_texture), PIPE_CAP_SEAMLESS_CUBE_MAP_PER_TEXTURE },
{ o(ATI_texture_mirror_once), PIPE_CAP_TEXTURE_MIRROR_CLAMP },
{ o(MESA_tile_raster_order), PIPE_CAP_TILE_RASTER_ORDER },
{ o(NV_compute_shader_derivatives), PIPE_CAP_COMPUTE_SHADER_DERIVATIVES },
{ o(NV_conditional_render), PIPE_CAP_CONDITIONAL_RENDER },
{ o(NV_fill_rectangle), PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE },
{ o(NV_primitive_restart), PIPE_CAP_PRIMITIVE_RESTART },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment