Skip to content

Commit f9730cf

Browse files
authored
Merge pull request #11262 from SDGNelson/patch-1
Add Z_CLIP_SCALE to Spatial Shaders reference vertex built-ins
1 parent 7f64929 commit f9730cf

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

tutorials/shaders/shader_reference/spatial_shader.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -269,6 +269,13 @@ shader, this value can be used as desired.
269269
+----------------------------------------+--------------------------------------------------------+
270270
| in vec4 **CUSTOM3** | Custom value from vertex primitive. |
271271
+----------------------------------------+--------------------------------------------------------+
272+
| out float **Z_CLIP_SCALE** | If written to, scales the vertex towards the camera to |
273+
| | avoid clipping into things like walls. |
274+
| | Lighting and shadows will continue to work correctly |
275+
| | when this is written to, but screen-space effects like |
276+
| | SSAO and SSR may break with lower scales. Try to keep |
277+
| | this value as close to ``1.0`` as possible. |
278+
+----------------------------------------+--------------------------------------------------------+
272279

273280
.. note::
274281

0 commit comments

Comments
 (0)