vkd3d: vkd3d_shader_parameter1 Struct Reference

vkd3d 1.19 The vkd3d 3D Graphics Library

Loading...
Searching...
No Matches
vkd3d_shader_parameter1 Struct Reference

An individual shader parameter. More...

`#include <vkd3d_shader.h>`

## Data Fields
enum vkd3d_shader_parameter_name | name
| The builtin parameter to be mapped.
enum vkd3d_shader_parameter_type | type
| How the parameter will be provided to the shader.
enum vkd3d_shader_parameter_data_type | data_type
| The data type of the supplied parameter, which determines how it is to be interpreted.
union { |
struct vkd3d_shader_parameter_immediate_constant1 immediate_constant |
| Additional information if type is VKD3D_SHADER_PARAMETER_TYPE_IMMEDIATE_CONSTANT.
struct vkd3d_shader_parameter_specialization_constant specialization_constant |
| Additional information if type is VKD3D_SHADER_PARAMETER_TYPE_SPECIALIZATION_CONSTANT.
struct vkd3d_shader_parameter_buffer buffer |
| Additional information if type is VKD3D_SHADER_PARAMETER_TYPE_BUFFER.
void * _pointer_pad |
uint32_t _pad [4] |
} | u

## Detailed Description

An individual shader parameter.

This structure is used in struct vkd3d_shader_parameter_info; see there for explanation of shader parameters.

For example, to specify the rasterizer sample count to the shader via an unsigned integer specialization constant with ID 3, set the following members:

- name = VKD3D_SHADER_PARAMETER_NAME_RASTERIZER_SAMPLE_COUNT
- type = VKD3D_SHADER_PARAMETER_TYPE_SPECIALIZATION_CONSTANT
- data_type = VKD3D_SHADER_PARAMETER_DATA_TYPE_UINT32
- u.specialization_constant.id = 3

This structure is an extended version of struct vkd3d_shader_parameter.

The documentation for this struct was generated from the following file:

- include/vkd3d_shader.h