vkd3d-shader/ir: Allow controlling FFP point size clamping through vkd3d-shader parameters.

This commit is contained in:
Elizabeth Figura
2024-10-03 17:55:24 -05:00
committed by Henri Verbeet
parent ec53e325b6
commit 1e3c1392bd
Notes: Henri Verbeet 2024-10-10 23:00:15 +02:00
Approved-by: Henri Verbeet (@hverbeet)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1146
2 changed files with 160 additions and 4 deletions

View File

@ -667,6 +667,39 @@ enum vkd3d_shader_parameter_name
* \since 1.14
*/
VKD3D_SHADER_PARAMETER_NAME_POINT_SIZE,
/**
* Minimum point size.
*
* When this parameter is provided to a vertex, tessellation, or geometry
* shader, and the source shader writes point size or uses the
* VKD3D_SHADER_PARAMETER_NAME_POINT_SIZE parameter, the point size will
* be clamped to the provided minimum value.
* If point size is not written in one of these ways,
* this parameter is ignored.
* If this parameter is not provided, the point size will not be clamped
* to a minimum size by vkd3d-shader.
*
* This parameter can be used to implement fixed function point size, as
* present in Direct3D versions 8 and 9, if the target environment does not
* support point size as part of its own fixed-function API (as Vulkan and
* core OpenGL).
*
* The data type for this parameter must be
* VKD3D_SHADER_PARAMETER_DATA_TYPE_FLOAT32.
*
* \since 1.14
*/
VKD3D_SHADER_PARAMETER_NAME_POINT_SIZE_MIN,
/**
* Maximum point size.
*
* This parameter has identical behaviour to
* VKD3D_SHADER_PARAMETER_NAME_POINT_SIZE_MIN, except that it provides
* the maximum size rather than the minimum.
*
* \since 1.14
*/
VKD3D_SHADER_PARAMETER_NAME_POINT_SIZE_MAX,
VKD3D_FORCE_32_BIT_ENUM(VKD3D_SHADER_PARAMETER_NAME),
};