-
Notifications
You must be signed in to change notification settings - Fork 2
/
Shader.tres
80 lines (61 loc) · 1.69 KB
/
Shader.tres
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
[gd_resource type="VisualShader" load_steps=6 format=2]
[sub_resource type="VisualShaderNodeColorConstant" id=1]
[sub_resource type="VisualShaderNodeTexture" id=2]
source = 2
[sub_resource type="VisualShaderNodeVectorOp" id=3]
operator = 6
[sub_resource type="VisualShaderNodeVectorOp" id=4]
operator = 2
[sub_resource type="VisualShaderNodeBooleanUniform" id=5]
uniform_name = "active"
[resource]
code = "shader_type canvas_item;
uniform bool active;
void vertex() {
// Output:0
}
void fragment() {
// Texture:3
vec3 n_out3p0;
float n_out3p1;
{
vec4 _tex_read = texture( TEXTURE , UV.xy );
n_out3p0 = _tex_read.rgb;
n_out3p1 = _tex_read.a;
}
// BooleanUniform:9
bool n_out9p0;
n_out9p0 = active;
// Color:11
vec3 n_out11p0;
float n_out11p1;
n_out11p0 = vec3(1.000000,1.000000,1.000000);
n_out11p1 = 1.000000;
// VectorOp:6
vec3 n_out6p0;
n_out6p0 = vec3(n_out9p0?1.0:0.0) * n_out11p0;
// VectorOp:5
vec3 n_out5p0;
n_out5p0 = max( n_out3p0 , n_out6p0 );
// Output:0
COLOR.rgb = n_out5p0;
COLOR.a = n_out3p1;
}
void light() {
// Output:0
}
"
mode = 1
flags/light_only = false
nodes/fragment/0/position = Vector2( 1040, 60 )
nodes/fragment/3/node = SubResource( 2 )
nodes/fragment/3/position = Vector2( 600, -40 )
nodes/fragment/5/node = SubResource( 3 )
nodes/fragment/5/position = Vector2( 860, -60 )
nodes/fragment/6/node = SubResource( 4 )
nodes/fragment/6/position = Vector2( 600, 100 )
nodes/fragment/9/node = SubResource( 5 )
nodes/fragment/9/position = Vector2( 400, 0 )
nodes/fragment/11/node = SubResource( 1 )
nodes/fragment/11/position = Vector2( 400, 120 )
nodes/fragment/connections = PoolIntArray( 3, 1, 0, 1, 3, 0, 5, 0, 6, 0, 5, 1, 5, 0, 0, 0, 9, 0, 6, 0, 11, 0, 6, 1 )