Sign in
skia
/
skia
/
97be28c4cc05231fe6e70dc32662c24700e731cc
/
.
/
tests
/
sksl
/
runtime
/
Switch.stage
blob: 6d58e81763af620068560774c98d9dab9ffd3656 [
file
] [
log
] [
blame
]
uniform half4 colorGreen
;
uniform half4 colorRed
;
half4 main
(
float2 coords
)
{
half4 color
;
switch
(
int
(
colorGreen
.
y
))
{
case
0
:
color
=
colorRed
;
break
;
case
1
:
color
=
colorGreen
;
break
;
default
:
color
=
colorRed
;
break
;
}
return
half4
(
color
);
}