浏览代码

Update spatial_shader.rst to mention godot use the same VIEW vector for both perspective and orthogonal cameras.

谢天 1 年之前
父节点
当前提交
d8f2ce6d6f
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      tutorials/shaders/shader_reference/spatial_shader.rst

+ 2 - 1
tutorials/shaders/shader_reference/spatial_shader.rst

@@ -253,7 +253,8 @@ these properties, and if you don't write to them, Godot will optimize away the c
 +----------------------------------------+--------------------------------------------------------------------------------------------------+
 +----------------------------------------+--------------------------------------------------------------------------------------------------+
 | in bool **FRONT_FACING**               | ``true`` if current face if front face.                                                          |
 | in bool **FRONT_FACING**               | ``true`` if current face if front face.                                                          |
 +----------------------------------------+--------------------------------------------------------------------------------------------------+
 +----------------------------------------+--------------------------------------------------------------------------------------------------+
-| in vec3 **VIEW**                       | Normalized vector from fragment position to camera (in view space).                              |
+| in vec3 **VIEW**                       | Normalized vector from fragment position to camera (in view space). This is the same for both    |
+|                                        | perspective and orthogonal cameras.                                                              |
 +----------------------------------------+--------------------------------------------------------------------------------------------------+
 +----------------------------------------+--------------------------------------------------------------------------------------------------+
 | in vec2 **UV**                         | UV that comes from vertex function.                                                              |
 | in vec2 **UV**                         | UV that comes from vertex function.                                                              |
 +----------------------------------------+--------------------------------------------------------------------------------------------------+
 +----------------------------------------+--------------------------------------------------------------------------------------------------+