mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
vkd3d-shader/hlsl: Return an hlsl_ir_node pointer from hlsl_new_float_constant().
This commit is contained in:
committed by
Alexandre Julliard
parent
b23ef3ca3b
commit
dc7514afc9
Notes:
Alexandre Julliard
2023-04-18 22:35:06 +02:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Henri Verbeet (@hverbeet) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/153
@@ -1138,7 +1138,7 @@ struct hlsl_ir_node *hlsl_new_bool_constant(struct hlsl_ctx *ctx, bool b, const
|
||||
return &c->node;
|
||||
}
|
||||
|
||||
struct hlsl_ir_constant *hlsl_new_float_constant(struct hlsl_ctx *ctx, float f,
|
||||
struct hlsl_ir_node *hlsl_new_float_constant(struct hlsl_ctx *ctx, float f,
|
||||
const struct vkd3d_shader_location *loc)
|
||||
{
|
||||
struct hlsl_ir_constant *c;
|
||||
@@ -1146,7 +1146,7 @@ struct hlsl_ir_constant *hlsl_new_float_constant(struct hlsl_ctx *ctx, float f,
|
||||
if ((c = hlsl_new_constant(ctx, hlsl_get_scalar_type(ctx, HLSL_TYPE_FLOAT), loc)))
|
||||
c->value[0].f = f;
|
||||
|
||||
return c;
|
||||
return &c->node;
|
||||
}
|
||||
|
||||
struct hlsl_ir_constant *hlsl_new_int_constant(struct hlsl_ctx *ctx, int n,
|
||||
|
Reference in New Issue
Block a user