mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-12-15 08:03:30 -08:00
vkd3d-shader/hlsl: Add parser support for stream-output object types.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
This commit is contained in:
committed by
Henri Verbeet
parent
13dfccc1c6
commit
1a6409cd5b
Notes:
Henri Verbeet
2024-11-21 19:35:19 +01:00
Approved-by: Elizabeth Figura (@zfigura) Approved-by: Henri Verbeet (@hverbeet) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1254
@@ -104,6 +104,7 @@ enum hlsl_type_class
|
||||
HLSL_CLASS_GEOMETRY_SHADER,
|
||||
HLSL_CLASS_CONSTANT_BUFFER,
|
||||
HLSL_CLASS_BLEND_STATE,
|
||||
HLSL_CLASS_STREAM_OUTPUT,
|
||||
HLSL_CLASS_VOID,
|
||||
HLSL_CLASS_NULL,
|
||||
HLSL_CLASS_ERROR,
|
||||
@@ -141,6 +142,13 @@ enum hlsl_sampler_dim
|
||||
/* NOTE: Remember to update object_methods[] in hlsl.y if this enum is modified. */
|
||||
};
|
||||
|
||||
enum hlsl_so_object_type
|
||||
{
|
||||
HLSL_STREAM_OUTPUT_POINT_STREAM,
|
||||
HLSL_STREAM_OUTPUT_LINE_STREAM,
|
||||
HLSL_STREAM_OUTPUT_TRIANGLE_STREAM,
|
||||
};
|
||||
|
||||
enum hlsl_regset
|
||||
{
|
||||
HLSL_REGSET_SAMPLERS,
|
||||
@@ -219,6 +227,12 @@ struct hlsl_type
|
||||
} resource;
|
||||
/* Additional field to distinguish object types. Currently used only for technique types. */
|
||||
unsigned int version;
|
||||
/* Additional information if type is HLSL_CLASS_STREAM_OUTPUT. */
|
||||
struct
|
||||
{
|
||||
struct hlsl_type *type;
|
||||
enum hlsl_so_object_type so_type;
|
||||
} so;
|
||||
} e;
|
||||
|
||||
/* Number of numeric register components used by one value of this type, for each regset.
|
||||
@@ -1518,6 +1532,8 @@ struct hlsl_ir_node *hlsl_new_if(struct hlsl_ctx *ctx, struct hlsl_ir_node *cond
|
||||
struct hlsl_ir_node *hlsl_new_int_constant(struct hlsl_ctx *ctx, int32_t n, const struct vkd3d_shader_location *loc);
|
||||
struct hlsl_ir_node *hlsl_new_jump(struct hlsl_ctx *ctx,
|
||||
enum hlsl_ir_jump_type type, struct hlsl_ir_node *condition, const struct vkd3d_shader_location *loc);
|
||||
struct hlsl_type *hlsl_new_stream_output_type(struct hlsl_ctx *ctx,
|
||||
enum hlsl_so_object_type so_type, struct hlsl_type *type);
|
||||
struct hlsl_ir_node *hlsl_new_ternary_expr(struct hlsl_ctx *ctx, enum hlsl_ir_expr_op op,
|
||||
struct hlsl_ir_node *arg1, struct hlsl_ir_node *arg2, struct hlsl_ir_node *arg3);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user