ce7cdcd7b4
SkSL does not support shrinking a vector via casting. Use a swizzle instead. Change-Id: Ieba78a05dad9c55f44c765924e28f0c7e1667a67 Bug: skia:12193 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/427198 Auto-Submit: John Stiles <johnstiles@google.com> Commit-Queue: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
20 lines
494 B
Plaintext
20 lines
494 B
Plaintext
// Expect 9 errors
|
|
|
|
// SkSL does not support shrinking a vector via casting.
|
|
// A vector-slice can be performed in SkSL (or GLSL) by using a swizzle instead.
|
|
|
|
const half4 h4 = half4(0);
|
|
const half3 h3 = half3(h4);
|
|
const half2 h2 = half2(h4);
|
|
const half h = half (h4);
|
|
|
|
const int4 i4 = int4(0);
|
|
const int3 i3 = int3(i4);
|
|
const int2 i2 = int2(i4);
|
|
const int i = int (i4);
|
|
|
|
const bool4 b4 = bool4(false);
|
|
const bool3 b3 = bool3(b4);
|
|
const bool2 b2 = bool2(b4);
|
|
const bool b = bool (b4);
|