diff options
author | Erik Johnson <ecmjohnson@hotmail.com> | 2023-01-31 22:53:54 -0500 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2024-02-13 10:36:38 +0100 |
commit | eab95698cdbec875e7a37d295790bf50f065dedd (patch) | |
tree | 31374262db225b47a40c5d9a28801fd36f677fc5 /drivers/gles3/shaders | |
parent | 9272f7b53db1f7f142df43981adec5cebdfbd179 (diff) | |
download | redot-engine-eab95698cdbec875e7a37d295790bf50f065dedd.tar.gz |
Fix shadows for billboarded Sprite3D's
Diffstat (limited to 'drivers/gles3/shaders')
-rw-r--r-- | drivers/gles3/shaders/scene.glsl | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/gles3/shaders/scene.glsl b/drivers/gles3/shaders/scene.glsl index 9e2c8a4452..ffdac85c1e 100644 --- a/drivers/gles3/shaders/scene.glsl +++ b/drivers/gles3/shaders/scene.glsl @@ -155,6 +155,9 @@ layout(std140) uniform SceneData { // ubo:2 highp mat4 inv_view_matrix; highp mat4 view_matrix; + // Used for billboards to cast correct shadows. + highp mat4 main_cam_inv_view_matrix; + vec2 viewport_size; vec2 screen_pixel_size; @@ -637,6 +640,9 @@ layout(std140) uniform SceneData { // ubo:2 highp mat4 inv_view_matrix; highp mat4 view_matrix; + // Used for billboards to cast correct shadows. + highp mat4 main_cam_inv_view_matrix; + vec2 viewport_size; vec2 screen_pixel_size; |