Skip to content

Commit 4023e05

Browse files
authored
Merge pull request godotengine#9191 from dawei-wang/patch-1
Complete the example for "skip_vertex_transform"
2 parents 3dc75a7 + ec274eb commit 4023e05

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tutorials/shaders/shader_reference/spatial_shader.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,8 @@ it manually with the following code:
130130
void vertex() {
131131
VERTEX = (MODELVIEW_MATRIX * vec4(VERTEX, 1.0)).xyz;
132132
NORMAL = normalize((MODELVIEW_MATRIX * vec4(NORMAL, 0.0)).xyz);
133-
// same as above for binormal and tangent, if normal mapping is used
133+
BINORMAL = normalize((MODELVIEW_MATRIX * vec4(BINORMAL, 0.0)).xyz);
134+
TANGENT = normalize((MODELVIEW_MATRIX * vec4(TANGENT, 0.0)).xyz);
134135
}
135136
136137
Other built-ins, such as UV, UV2 and COLOR, are also passed through to the fragment function if not modified.

0 commit comments

Comments
 (0)