mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
vkd3d-shader/hlsl: Track bind count according to usage for uniforms.
Where bind count means the number of registers required to include all dereferences to the variable within the shader as in hlsl_ir_var.bind_count[].
This commit is contained in:
committed by
Alexandre Julliard
parent
e0a801e796
commit
573d511344
Notes:
Alexandre Julliard
2024-05-13 22:57:39 +02:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Henri Verbeet (@hverbeet) Approved-by: Elizabeth Figura (@zfigura) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/851
@@ -447,9 +447,10 @@ struct hlsl_ir_var
|
||||
enum hlsl_sampler_dim sampler_dim;
|
||||
struct vkd3d_shader_location first_sampler_dim_loc;
|
||||
} *objects_usage[HLSL_REGSET_LAST_OBJECT + 1];
|
||||
/* Minimum number of binds required to include all object components actually used in the shader.
|
||||
* It may be less than the allocation size, e.g. for texture arrays. */
|
||||
unsigned int bind_count[HLSL_REGSET_LAST_OBJECT + 1];
|
||||
/* Minimum number of binds required to include all components actually used in the shader.
|
||||
* It may be less than the allocation size, e.g. for texture arrays.
|
||||
* The bind_count for HLSL_REGSET_NUMERIC is only used in uniforms for now. */
|
||||
unsigned int bind_count[HLSL_REGSET_LAST + 1];
|
||||
|
||||
/* Whether the shader performs dereferences with non-constant offsets in the variable. */
|
||||
bool indexable;
|
||||
|
Reference in New Issue
Block a user