소스 검색

Add LIGHT_IS_DIRECTIONAL built-in for spatial shaders (#7194)

Johan 2 년 전
부모
커밋
930ad1f77b
1개의 변경된 파일2개의 추가작업 그리고 0개의 파일을 삭제
  1. 2 0
      tutorials/shaders/shader_reference/spatial_shader.rst

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

@@ -443,6 +443,8 @@ If you want the lights to add together, add the light contribution to ``DIFFUSE_
 +-----------------------------------+----------------------------------------------------+
 | in vec3 **LIGHT_COLOR**           | Color of light multiplied by energy.               |
 +-----------------------------------+----------------------------------------------------+
+| in vec3 **LIGHT_IS_DIRECTIONAL**  | ``true`` if this pass is a ``DirectionalLight3D``. |
++-----------------------------------+----------------------------------------------------+
 | in float **ATTENUATION**          | Attenuation based on distance or shadow.           |
 +-----------------------------------+----------------------------------------------------+
 | in vec3 **ALBEDO**                | Base albedo.                                       |