Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- libs/vkd3d-shader/hlsl_constant_ops.c | 9 ++++++++- tests/arithmetic-float.shader_test | 1 + 2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/libs/vkd3d-shader/hlsl_constant_ops.c b/libs/vkd3d-shader/hlsl_constant_ops.c index 06b957ba..a1551ba1 100644 --- a/libs/vkd3d-shader/hlsl_constant_ops.c +++ b/libs/vkd3d-shader/hlsl_constant_ops.c @@ -18,6 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */
+#include <math.h> + #include "hlsl.h"
static bool fold_cast(struct hlsl_ctx *ctx, struct hlsl_ir_constant *dst, struct hlsl_ir_constant *src) @@ -270,12 +272,17 @@ static bool fold_div(struct hlsl_ctx *ctx, struct hlsl_ir_constant *dst, { case HLSL_TYPE_FLOAT: case HLSL_TYPE_HALF: - if (src2->value[k].f == 0) + if (ctx->profile->major_version >= 4 && src2->value[k].f == 0) { hlsl_warning(ctx, &dst->node.loc, VKD3D_SHADER_WARNING_HLSL_DIVISION_BY_ZERO, "Floating point division by zero"); } dst->value[k].f = src1->value[k].f / src2->value[k].f; + if (ctx->profile->major_version < 4 && isinf(dst->value[k].f)) + { + hlsl_error(ctx, &dst->node.loc, VKD3D_SHADER_ERROR_HLSL_DIVISION_BY_ZERO, + "Infinities are not allowed by the shader model."); + } break;
case HLSL_TYPE_DOUBLE: diff --git a/tests/arithmetic-float.shader_test b/tests/arithmetic-float.shader_test index f99b9728..6824c3f1 100644 --- a/tests/arithmetic-float.shader_test +++ b/tests/arithmetic-float.shader_test @@ -25,6 +25,7 @@ todo draw quad probe all rgba (5.0, 5.0, -5.0, 3.0)
[require] +% Infinities are not allowed in SM1 shader model >= 4.0
[pixel shader]
Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- libs/vkd3d-shader/hlsl_constant_ops.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libs/vkd3d-shader/hlsl_constant_ops.c b/libs/vkd3d-shader/hlsl_constant_ops.c index a1551ba1..2e16577f 100644 --- a/libs/vkd3d-shader/hlsl_constant_ops.c +++ b/libs/vkd3d-shader/hlsl_constant_ops.c @@ -275,7 +275,7 @@ static bool fold_div(struct hlsl_ctx *ctx, struct hlsl_ir_constant *dst, if (ctx->profile->major_version >= 4 && src2->value[k].f == 0) { hlsl_warning(ctx, &dst->node.loc, VKD3D_SHADER_WARNING_HLSL_DIVISION_BY_ZERO, - "Floating point division by zero"); + "Floating point division by zero."); } dst->value[k].f = src1->value[k].f / src2->value[k].f; if (ctx->profile->major_version < 4 && isinf(dst->value[k].f)) @@ -289,7 +289,7 @@ static bool fold_div(struct hlsl_ctx *ctx, struct hlsl_ir_constant *dst, if (src2->value[k].d == 0) { hlsl_warning(ctx, &dst->node.loc, VKD3D_SHADER_WARNING_HLSL_DIVISION_BY_ZERO, - "Floating point division by zero"); + "Floating point division by zero."); } dst->value[k].d = src1->value[k].d / src2->value[k].d; break;
Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- tests/arithmetic-int.shader_test | 13 +++++++++++++ 1 file changed, 13 insertions(+)
diff --git a/tests/arithmetic-int.shader_test b/tests/arithmetic-int.shader_test index c2eee2ba..14bb6a63 100644 --- a/tests/arithmetic-int.shader_test +++ b/tests/arithmetic-int.shader_test @@ -24,6 +24,19 @@ float4 main() : SV_TARGET draw quad probe all rgba (5.0, 5.0, -5.0, 3.0)
+[pixel shader] +float4 main() : SV_TARGET +{ + int x = -2147483648; + int y = -1; + + return x / y; +} + +[test] +draw quad +probe all rgba (-2147483648.0, -2147483648.0, -2147483648.0, -2147483648.0) + [pixel shader fail] float4 main() : SV_TARGET {
Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- libs/vkd3d-shader/hlsl.y | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/libs/vkd3d-shader/hlsl.y b/libs/vkd3d-shader/hlsl.y index 291f8392..ec0e23bb 100644 --- a/libs/vkd3d-shader/hlsl.y +++ b/libs/vkd3d-shader/hlsl.y @@ -588,12 +588,12 @@ static bool add_array_load(struct hlsl_ctx *ctx, struct list *instrs, struct hls struct hlsl_type *data_type; struct hlsl_ir_constant *c; struct hlsl_ir_node *mul; + unsigned int stride;
if (expr_type->type == HLSL_CLASS_ARRAY) { data_type = expr_type->e.array.type; - if (!(c = hlsl_new_uint_constant(ctx, hlsl_type_get_array_element_reg_size(data_type), &loc))) - return false; + stride = hlsl_type_get_array_element_reg_size(data_type); } else if (expr_type->type == HLSL_CLASS_MATRIX) { @@ -604,8 +604,7 @@ static bool add_array_load(struct hlsl_ctx *ctx, struct list *instrs, struct hls else if (expr_type->type == HLSL_CLASS_VECTOR) { data_type = hlsl_get_scalar_type(ctx, expr_type->base_type); - if (!(c = hlsl_new_uint_constant(ctx, 1, &loc))) - return false; + stride = 1; } else { @@ -616,6 +615,8 @@ static bool add_array_load(struct hlsl_ctx *ctx, struct list *instrs, struct hls return false; }
+ if (!(c = hlsl_new_uint_constant(ctx, stride, &loc))) + return false; list_add_tail(instrs, &c->node.entry); if (!(mul = hlsl_new_binary_expr(ctx, HLSL_OP2_MUL, index, &c->node))) return false;
Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- libs/vkd3d-shader/hlsl_codegen.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/libs/vkd3d-shader/hlsl_codegen.c b/libs/vkd3d-shader/hlsl_codegen.c index 73e3b73f..f22841fb 100644 --- a/libs/vkd3d-shader/hlsl_codegen.c +++ b/libs/vkd3d-shader/hlsl_codegen.c @@ -567,8 +567,10 @@ static bool fold_redundant_casts(struct hlsl_ctx *ctx, struct hlsl_ir_node *inst return false; }
-/* Helper for split_array_copies() and split_struct_copies(). Inserts new - * instructions right before "store". */ +/* Copy an element of a complex variable. Helper for + * split_array_copies(), split_struct_copies() and + * split_matrix_copies(). Inserts new instructions right before + * "store". */ static bool split_copy(struct hlsl_ctx *ctx, struct hlsl_ir_store *store, const struct hlsl_ir_load *load, const unsigned int offset, struct hlsl_type *type) {
Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- tests/hlsl-matrix-indexing.shader_test | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-)
diff --git a/tests/hlsl-matrix-indexing.shader_test b/tests/hlsl-matrix-indexing.shader_test index e2103fe2..8057179e 100644 --- a/tests/hlsl-matrix-indexing.shader_test +++ b/tests/hlsl-matrix-indexing.shader_test @@ -47,18 +47,16 @@ todo draw quad probe all rgba (1.0, 5.0, 7.0, 12.0)
[pixel shader] -uniform float4x4 m; +uniform float3x2 m;
float4 main() : SV_TARGET { - float4x4 m2 = m; - return float4(m2[0][0], m2[1][0], m2[1][2], m2[2][3]); + float3x2 m2 = m; + return float4(m2[0][0], m2[2][0], m2[1][1], m2[2][1]); }
[test] -uniform 0 float4 1.0 2.0 3.0 4.0 -uniform 4 float4 5.0 6.0 7.0 8.0 -uniform 8 float4 9.0 10.0 11.0 12.0 -uniform 12 float4 13.0 14.0 15.0 16.0 +uniform 0 float4 1.0 2.0 3.0 0.0 +uniform 4 float4 5.0 6.0 7.0 0.0 todo draw quad -probe all rgba (1.0, 2.0, 10.0, 15.0) +probe all rgba (1.0, 3.0, 6.0, 7.0)
Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- libs/vkd3d-shader/hlsl_codegen.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libs/vkd3d-shader/hlsl_codegen.c b/libs/vkd3d-shader/hlsl_codegen.c index f22841fb..f31bfe9f 100644 --- a/libs/vkd3d-shader/hlsl_codegen.c +++ b/libs/vkd3d-shader/hlsl_codegen.c @@ -676,7 +676,7 @@ static bool split_struct_copies(struct hlsl_ctx *ctx, struct hlsl_ir_node *instr
static unsigned int minor_size(const struct hlsl_type *type) { - if (type->type == HLSL_CLASS_VECTOR || type->modifiers & HLSL_MODIFIER_ROW_MAJOR) + if (type->modifiers & HLSL_MODIFIER_ROW_MAJOR) return type->dimx; else return type->dimy; @@ -684,7 +684,7 @@ static unsigned int minor_size(const struct hlsl_type *type)
static unsigned int major_size(const struct hlsl_type *type) { - if (type->type == HLSL_CLASS_VECTOR || type->modifiers & HLSL_MODIFIER_ROW_MAJOR) + if (type->modifiers & HLSL_MODIFIER_ROW_MAJOR) return type->dimy; else return type->dimx;
Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- v2: * Use "scalar_type" instead of "scal_type" * Use a vkd3d_string_buffer to format the variable's name * Format the variable name with %u instead of %x * Use hlsl_new_var_load() instead of hlsl_new_load() * Rename compute_matrix_offset() to add_compute_matrix_offset() --- libs/vkd3d-shader/hlsl.y | 89 +++++++++++++++++++++++++- tests/hlsl-matrix-indexing.shader_test | 8 +-- 2 files changed, 90 insertions(+), 7 deletions(-)
diff --git a/libs/vkd3d-shader/hlsl.y b/libs/vkd3d-shader/hlsl.y index ec0e23bb..d6d9dda6 100644 --- a/libs/vkd3d-shader/hlsl.y +++ b/libs/vkd3d-shader/hlsl.y @@ -581,6 +581,91 @@ static bool add_record_load(struct hlsl_ctx *ctx, struct list *instrs, struct hl return !!add_load(ctx, instrs, record, &c->node, field->type, loc); }
+static struct hlsl_ir_expr *add_binary_arithmetic_expr(struct hlsl_ctx *ctx, struct list *instrs, + enum hlsl_ir_expr_op op, struct hlsl_ir_node *arg1, struct hlsl_ir_node *arg2, + const struct vkd3d_shader_location *loc); + +static struct hlsl_ir_node *add_compute_matrix_offset(struct hlsl_ctx *ctx, struct list *instrs, + struct hlsl_type *type, struct hlsl_ir_node *x, struct hlsl_ir_node *y, + const struct vkd3d_shader_location *loc) +{ + struct hlsl_ir_node *major, *minor; + struct hlsl_ir_expr *mul, *add; + struct hlsl_ir_constant *four; + + if (type->modifiers & HLSL_MODIFIER_ROW_MAJOR) + { + minor = x; + major = y; + } + else + { + minor = y; + major = x; + } + + if (!(four = hlsl_new_uint_constant(ctx, 4, loc))) + return NULL; + list_add_tail(instrs, &four->node.entry); + + if (!(mul = add_binary_arithmetic_expr(ctx, instrs, HLSL_OP2_MUL, &four->node, major, loc))) + return NULL; + + if (!(add = add_binary_arithmetic_expr(ctx, instrs, HLSL_OP2_ADD, &mul->node, minor, loc))) + return NULL; + + return &add->node; +} + +static bool add_matrix_load(struct hlsl_ctx *ctx, struct list *instrs, + struct hlsl_ir_node *matrix, struct hlsl_ir_node *index, const struct vkd3d_shader_location *loc) +{ + struct hlsl_type *mat_type = matrix->data_type, *ret_type, *scalar_type; + struct vkd3d_string_buffer name; + static unsigned int counter = 0; + struct hlsl_ir_load *load; + struct hlsl_ir_var *var; + unsigned int i; + + ret_type = hlsl_get_vector_type(ctx, mat_type->base_type, mat_type->dimx); + scalar_type = hlsl_get_scalar_type(ctx, mat_type->base_type); + + vkd3d_string_buffer_init(&name); + vkd3d_string_buffer_printf(&name, "<index-%u>", counter++); + var = hlsl_new_synthetic_var(ctx, name.buffer, ret_type, *loc); + vkd3d_string_buffer_cleanup(&name); + if (!var) + return false; + + for (i = 0; i < mat_type->dimx; ++i) + { + struct hlsl_ir_node *offset; + struct hlsl_ir_store *store; + struct hlsl_ir_load *value; + struct hlsl_ir_constant *c; + + if (!(c = hlsl_new_uint_constant(ctx, i, loc))) + return false; + list_add_tail(instrs, &c->node.entry); + + if (!(offset = add_compute_matrix_offset(ctx, instrs, mat_type, &c->node, index, loc))) + return false; + + if (!(value = add_load(ctx, instrs, matrix, offset, scalar_type, *loc))) + return false; + + if (!(store = hlsl_new_store(ctx, var, &c->node, &value->node, 0, *loc))) + return false; + list_add_tail(instrs, &store->node.entry); + } + + if (!(load = hlsl_new_var_load(ctx, var, *loc))) + return false; + list_add_tail(instrs, &load->node.entry); + + return true; +} + static bool add_array_load(struct hlsl_ctx *ctx, struct list *instrs, struct hlsl_ir_node *array, struct hlsl_ir_node *index, const struct vkd3d_shader_location loc) { @@ -597,9 +682,7 @@ static bool add_array_load(struct hlsl_ctx *ctx, struct list *instrs, struct hls } else if (expr_type->type == HLSL_CLASS_MATRIX) { - /* This needs to be lowered now, while we still have type information. */ - FIXME("Index of matrix type.\n"); - return false; + return add_matrix_load(ctx, instrs, array, index, &loc); } else if (expr_type->type == HLSL_CLASS_VECTOR) { diff --git a/tests/hlsl-matrix-indexing.shader_test b/tests/hlsl-matrix-indexing.shader_test index 8057179e..a0a89829 100644 --- a/tests/hlsl-matrix-indexing.shader_test +++ b/tests/hlsl-matrix-indexing.shader_test @@ -11,7 +11,7 @@ uniform 0 float4 1.0 2.0 3.0 4.0 uniform 4 float4 5.0 6.0 7.0 8.0 uniform 8 float4 9.0 10.0 11.0 12.0 uniform 12 float4 13.0 14.0 15.0 16.0 -todo draw quad +draw quad probe all rgba (1.0, 2.0, 10.0, 15.0)
[pixel shader] @@ -27,7 +27,7 @@ uniform 0 float4 1.0 2.0 3.0 4.0 uniform 4 float4 5.0 6.0 7.0 8.0 uniform 8 float4 9.0 10.0 11.0 12.0 uniform 12 float4 13.0 14.0 15.0 16.0 -todo draw quad +draw quad probe all rgba (1.0, 2.0, 10.0, 15.0)
[pixel shader] @@ -43,7 +43,7 @@ uniform 0 float4 1.0 2.0 3.0 4.0 uniform 4 float4 5.0 6.0 7.0 8.0 uniform 8 float4 9.0 10.0 11.0 12.0 uniform 12 float4 13.0 14.0 15.0 16.0 -todo draw quad +draw quad probe all rgba (1.0, 5.0, 7.0, 12.0)
[pixel shader] @@ -58,5 +58,5 @@ float4 main() : SV_TARGET [test] uniform 0 float4 1.0 2.0 3.0 0.0 uniform 4 float4 5.0 6.0 7.0 0.0 -todo draw quad +draw quad probe all rgba (1.0, 3.0, 6.0, 7.0)
On Thu, 21 Apr 2022 at 17:44, Giovanni Mascellani gmascellani@codeweavers.com wrote:
+static bool add_matrix_load(struct hlsl_ctx *ctx, struct list *instrs,
struct hlsl_ir_node *matrix, struct hlsl_ir_node *index, const struct vkd3d_shader_location *loc)
[...]
- vkd3d_string_buffer_init(&name);
- vkd3d_string_buffer_printf(&name, "<index-%u>", counter++);
- var = hlsl_new_synthetic_var(ctx, name.buffer, ret_type, *loc);
- vkd3d_string_buffer_cleanup(&name);
That works, but it seems preferable to use hlsl_get_string_buffer()/hlsl_release_string_buffer() to get an existing buffer from the cache.
Signed-off-by: Giovanni Mascellani gmascellani@codeweavers.com --- v2: * Do not use the comma operator inside a "for" statement. * Prepend "add_" to the name of functions that mutate the instruction stream. * Add a vector and a matrix to the constructor test. --- libs/vkd3d-shader/hlsl.y | 98 ++++++++++++++++--- tests/hlsl-matrix-indexing.shader_test | 16 +++ ...lsl-return-implicit-conversion.shader_test | 8 +- 3 files changed, 102 insertions(+), 20 deletions(-)
diff --git a/libs/vkd3d-shader/hlsl.y b/libs/vkd3d-shader/hlsl.y index d6d9dda6..638a5b18 100644 --- a/libs/vkd3d-shader/hlsl.y +++ b/libs/vkd3d-shader/hlsl.y @@ -2084,18 +2084,87 @@ static struct list *add_call(struct hlsl_ctx *ctx, const char *name, return params->instrs; }
+static struct hlsl_ir_node *add_compute_offset_from_index(struct hlsl_ctx *ctx, struct list *instrs, + struct hlsl_type *type, unsigned int idx, const struct vkd3d_shader_location *loc) +{ + assert(type->type <= HLSL_CLASS_LAST_NUMERIC); + assert(idx < type->dimx * type->dimy); + + if (type->type == HLSL_CLASS_SCALAR || type->type == HLSL_CLASS_VECTOR) + { + struct hlsl_ir_constant *c; + + if (!(c = hlsl_new_uint_constant(ctx, idx, loc))) + return NULL; + list_add_tail(instrs, &c->node.entry); + + return &c->node; + } + else + { + struct hlsl_ir_constant *x, *y; + + if (!(x = hlsl_new_uint_constant(ctx, idx % type->dimx, loc))) + return NULL; + list_add_tail(instrs, &x->node.entry); + + if (!(y = hlsl_new_uint_constant(ctx, idx / type->dimx, loc))) + return NULL; + list_add_tail(instrs, &y->node.entry); + + return add_compute_matrix_offset(ctx, instrs, type, &x->node, &y->node, loc); + } +} + +static struct hlsl_ir_node *add_load_index(struct hlsl_ctx *ctx, struct list *instrs, struct hlsl_ir_node *instr, + unsigned int idx, const struct vkd3d_shader_location *loc) +{ + struct hlsl_type *scal_type = hlsl_get_scalar_type(ctx, instr->data_type->base_type); + struct hlsl_ir_node *offset; + struct hlsl_ir_load *load; + + if (instr->data_type->type > HLSL_CLASS_LAST_NUMERIC) + { + hlsl_fixme(ctx, loc, "Loading from non-numeric type."); + return NULL; + } + + if (!(offset = add_compute_offset_from_index(ctx, instrs, instr->data_type, idx, loc))) + return NULL; + + if (!(load = add_load(ctx, instrs, instr, offset, scal_type, *loc))) + return NULL; + + return &load->node; +} + +static struct hlsl_ir_node *add_store_index(struct hlsl_ctx *ctx, struct list *instrs, struct hlsl_ir_var *var, + struct hlsl_ir_node *rhs, unsigned int idx, const struct vkd3d_shader_location *loc) +{ + struct hlsl_ir_node *offset; + struct hlsl_ir_store *store; + + if (!(offset = add_compute_offset_from_index(ctx, instrs, var->data_type, idx, loc))) + return NULL; + + if (!(store = hlsl_new_store(ctx, var, offset, rhs, 0, *loc))) + return NULL; + list_add_tail(instrs, &store->node.entry); + + return &store->node; +} + static struct list *add_constructor(struct hlsl_ctx *ctx, struct hlsl_type *type, struct parse_initializer *params, struct vkd3d_shader_location loc) { - unsigned int i, writemask_offset = 0; - struct hlsl_ir_store *store; static unsigned int counter; + struct hlsl_type *scal_type; + unsigned int i, j, idx = 0; struct hlsl_ir_load *load; struct hlsl_ir_var *var; char name[23];
- if (type->type == HLSL_CLASS_MATRIX) - hlsl_fixme(ctx, &loc, "Matrix constructor."); + scal_type = hlsl_get_scalar_type(ctx, type->base_type);
sprintf(name, "<constructor-%x>", counter++); if (!(var = hlsl_new_synthetic_var(ctx, name, type, loc))) @@ -2118,22 +2187,19 @@ static struct list *add_constructor(struct hlsl_ctx *ctx, struct hlsl_type *type } width = hlsl_type_component_count(arg->data_type);
- if (width > 4) + for (j = 0; j < width; ++j) { - FIXME("Constructor argument with %u components.\n", width); - continue; - } + struct hlsl_ir_node *value;
- if (!(arg = add_implicit_conversion(ctx, params->instrs, arg, - hlsl_get_vector_type(ctx, type->base_type, width), &arg->loc))) - continue; + if (!(value = add_load_index(ctx, params->instrs, arg, j, &loc))) + return NULL;
- if (!(store = hlsl_new_store(ctx, var, NULL, arg, - ((1u << width) - 1) << writemask_offset, arg->loc))) - return NULL; - list_add_tail(params->instrs, &store->node.entry); + if (!(value = add_implicit_conversion(ctx, params->instrs, value, scal_type, &arg->loc))) + return NULL;
- writemask_offset += width; + if (!add_store_index(ctx, params->instrs, var, value, idx++, &loc)) + return NULL; + } }
if (!(load = hlsl_new_var_load(ctx, var, loc))) diff --git a/tests/hlsl-matrix-indexing.shader_test b/tests/hlsl-matrix-indexing.shader_test index a0a89829..9336a67a 100644 --- a/tests/hlsl-matrix-indexing.shader_test +++ b/tests/hlsl-matrix-indexing.shader_test @@ -60,3 +60,19 @@ uniform 0 float4 1.0 2.0 3.0 0.0 uniform 4 float4 5.0 6.0 7.0 0.0 draw quad probe all rgba (1.0, 3.0, 6.0, 7.0) + +[pixel shader] +float4 main() : SV_TARGET +{ + float2x2 a = float2x2(11.0, 12.0, 13.0, 14.0); + float4x4 m = float4x4(1.0, 2.0, 3.0, 4.0, + float3(5.0, 6.0, 7.0), 8.0, + 9.0, 10.0, + a, + 15.0, 16.0); + return float4(m[0][0], m[1][0], m[1][2], m[2][3]); +} + +[test] +todo draw quad +probe all rgba (1.0, 5.0, 7.0, 12.0) diff --git a/tests/hlsl-return-implicit-conversion.shader_test b/tests/hlsl-return-implicit-conversion.shader_test index 38d21633..bf99d9cb 100644 --- a/tests/hlsl-return-implicit-conversion.shader_test +++ b/tests/hlsl-return-implicit-conversion.shader_test @@ -98,7 +98,7 @@ float4 main() : sv_target todo draw quad probe all rgba (0.4, 0.3, 0.2, 0.0)
-[pixel shader fail todo] +[pixel shader fail] float3x1 func() { return float1x3(0.4, 0.3, 0.2); @@ -109,7 +109,7 @@ float4 main() : sv_target return float4(func(), 0.0); }
-[pixel shader fail todo] +[pixel shader fail] float1x3 func() { return float3x1(0.4, 0.3, 0.2); @@ -191,7 +191,7 @@ float4 main() : sv_target todo draw quad probe all rgba (0.4, 0.3, 0.2, 0.0)
-[pixel shader fail todo] +[pixel shader fail] float3x1 func() { return float1x4(0.4, 0.3, 0.2, 0.1); @@ -217,7 +217,7 @@ float4 main() : sv_target todo draw quad probe all rgba (0.4, 0.3, 0.2, 0.0)
-[pixel shader fail todo] +[pixel shader fail] float1x3 func() { return float4x1(0.4, 0.3, 0.2, 0.1);