EEVEE Next: Tag shadowmap usage for transparent object volumes #104580

Merged
Miguel Pozo merged 31 commits from pragma37/blender:pull-eevee-shadows-tag-usage-transparent into main 2023-03-08 13:51:35 +01:00

31 Commits

Author SHA1 Message Date
Miguel Pozo 40c5909f4a fix comments 2023-03-08 13:41:20 +01:00
Miguel Pozo 39ad50fb0e Fix comment 2023-03-06 19:08:41 +01:00
Miguel Pozo 2e7c34342d Comments improvements 2023-03-06 15:56:29 +01:00
Miguel Pozo 29d79d2210 Clarify lP meaning in eevee_shadow_tilemap_lib 2023-03-06 15:38:42 +01:00
Miguel Pozo e95164f067 Remove dist_to_cam from shadow_tag_usage_tilemap_directional 2023-03-06 15:37:44 +01:00
Miguel Pozo b147780266 IsectBox -> Box 2023-03-06 15:36:30 +01:00
Miguel Pozo 43f3238c0e Remove unneeded conservative measure in punctual shadows 2023-03-06 13:43:49 +01:00
Miguel Pozo c029637e3e Simplify punctual face selection 2023-03-06 13:43:49 +01:00
Miguel Pozo a5d681d5d4 Back to half-pixel conservative rasterization.
We don't need a full pixel now that pixel bounds are used for tagging.
2023-03-06 13:43:49 +01:00
Miguel Pozo 38cf4cc107 Fix vP 2023-03-06 13:43:49 +01:00
Miguel Pozo 96fb75c54e Cleanup 2023-03-06 13:43:49 +01:00
Miguel Pozo 711eaa8618 Usage tag radius support for punctual lights 2023-03-06 13:43:49 +01:00
Miguel Pozo f0de9265a9 Step size and bounding sphere improvements 2023-03-06 13:43:48 +01:00
Miguel Pozo 2faa8d05f7 shadow_tag_usage radius support 2023-03-06 13:43:48 +01:00
Miguel Pozo 69624ed614 Cleanup: Split shadow_tag_usage_tilemap 2023-03-06 13:43:48 +01:00
Miguel Pozo c5f7238fc7 Cleanup: Remove debugging code 2023-03-06 13:43:48 +01:00
Miguel Pozo 66cf2dcddb EEVEE Shadows: Step bounding sphere 2023-03-06 13:43:48 +01:00
Miguel Pozo c5fbe87e58 Inflate bounds by 1 full pixel 2023-03-06 13:43:48 +01:00
Miguel Pozo 07a8d43728 Cleanup and comments
Use exp2 instead of pow.
Pass vec2 to max_v2.
Don't use the float specifier.
2023-03-06 13:43:48 +01:00
Miguel Pozo 3d44db4a7d EEVEE Shadows: Conservative rasterization 2023-03-06 13:43:48 +01:00
Miguel Pozo 0b08dda301 EEVEE Shadows: Support low-res usage-tagging 2023-03-06 13:43:48 +01:00
Miguel Pozo ca7cc12b69 EEVEE Shadows: Use hiz_tx instead of depth_tx 2023-03-06 13:43:48 +01:00
Miguel Pozo 63ae3637d0 Cleanup 2023-03-06 13:43:48 +01:00
Miguel Pozo 2fdd1f52af EEVEE Shadows: Improved step size 2023-03-06 13:43:48 +01:00
Miguel Pozo 901615ad05 Cleanup 2023-03-06 13:43:48 +01:00
Miguel Pozo b8a42966b3 EEVEE Shadows: Test against opaque depth
ammend
2023-03-06 13:43:47 +01:00
Miguel Pozo b387a90985 EEVEE Shadows: Move AABB computation to vertex shader 2023-03-06 13:43:47 +01:00
Miguel Pozo 609853e8e5 EEVEE Shadows: Transparent tag usage the whole bbox volume 2023-03-06 13:43:47 +01:00
Miguel Pozo 6a008dfc3e EEVEE Shadows: Avoid struct/class missmatch compiler warnings 2023-03-06 13:43:47 +01:00
Miguel Pozo 074e2dc0e6 EEVEE Shadows: Fix transparent bbox size
Box vertices goes from -1 to +1
2023-03-06 13:43:47 +01:00
Miguel Pozo 5837765d24 EEVEE Shadows: Perform depth testing in tilemap_usage_transparent_ps_ 2023-03-06 13:43:47 +01:00