14 .storage_buf(3, Qualifier::READ,
"float",
"pos[]", Frequency::GEOMETRY)
16 .push_constant(Type::IVEC2,
"gpu_attr_3")
17 .uniform_buf(1,
"ShadowPassData",
"pass_data")
18 .typedef_source(
"workbench_shader_shared.h")
19 .additional_info(
"gpu_index_load")
20 .additional_info(
"draw_view")
21 .additional_info(
"draw_modelmat_new")
22 .additional_info(
"draw_resource_handle_new");
26 .define(
"DRW_VIEW_LEN",
"64")
27 .storage_buf(0, Qualifier::READ,
"ObjectBounds",
"bounds_buf[]")
28 .uniform_buf(2,
"ExtrudedFrustum",
"extruded_frustum")
29 .push_constant(Type::INT,
"resource_len")
30 .push_constant(Type::INT,
"view_len")
31 .push_constant(Type::INT,
"visibility_word_per_draw")
32 .push_constant(Type::BOOL,
"force_fail_method")
33 .push_constant(Type::VEC3,
"shadow_direction")
34 .typedef_source(
"workbench_shader_shared.h")
35 .compute_source(
"workbench_shadow_visibility_comp.glsl")
36 .additional_info(
"draw_view",
"draw_view_culling");
39 .additional_info(
"workbench_shadow_visibility_compute_common")
40 .define(
"DYNAMIC_PASS_SELECTION")
41 .storage_buf(1, Qualifier::READ_WRITE,
"uint",
"pass_visibility_buf[]")
42 .storage_buf(2, Qualifier::READ_WRITE,
"uint",
"fail_visibility_buf[]")
43 .do_static_compilation(
true);
46 .additional_info(
"workbench_shadow_visibility_compute_common")
47 .storage_buf(1, Qualifier::READ_WRITE,
"uint",
"visibility_buf[]")
48 .do_static_compilation(
true);
57 .fragment_source(
"gpu_shader_depth_only_frag.glsl");
60 .fragment_out(0, Type::VEC4,
"out_debug_color")
61 .fragment_source(
"workbench_shadow_debug_frag.glsl");
69#define WORKBENCH_SHADOW_VARIATIONS(common, prefix, suffix, ...) \
70 GPU_SHADER_CREATE_INFO(prefix##_pass_manifold_no_caps##suffix) \
71 .define("SHADOW_PASS") \
72 .vertex_source("workbench_shadow_vert.glsl") \
73 .additional_info(common, __VA_ARGS__) \
74 .do_static_compilation(true); \
75 GPU_SHADER_CREATE_INFO(prefix##_pass_no_manifold_no_caps##suffix) \
76 .define("SHADOW_PASS") \
77 .define("DOUBLE_MANIFOLD") \
78 .vertex_source("workbench_shadow_vert.glsl") \
79 .additional_info(common, __VA_ARGS__) \
80 .do_static_compilation(true); \
81 GPU_SHADER_CREATE_INFO(prefix##_fail_manifold_caps##suffix) \
82 .define("SHADOW_FAIL") \
83 .vertex_source("workbench_shadow_caps_vert.glsl") \
84 .additional_info(common, __VA_ARGS__) \
85 .do_static_compilation(true); \
86 GPU_SHADER_CREATE_INFO(prefix##_fail_manifold_no_caps##suffix) \
87 .define("SHADOW_FAIL") \
88 .vertex_source("workbench_shadow_vert.glsl") \
89 .additional_info(common, __VA_ARGS__) \
90 .do_static_compilation(true); \
91 GPU_SHADER_CREATE_INFO(prefix##_fail_no_manifold_caps##suffix) \
92 .define("SHADOW_FAIL") \
93 .define("DOUBLE_MANIFOLD") \
94 .vertex_source("workbench_shadow_caps_vert.glsl") \
95 .additional_info(common, __VA_ARGS__) \
96 .do_static_compilation(true); \
97 GPU_SHADER_CREATE_INFO(prefix##_fail_no_manifold_no_caps##suffix) \
98 .define("SHADOW_FAIL") \
99 .define("DOUBLE_MANIFOLD") \
100 .vertex_source("workbench_shadow_vert.glsl") \
101 .additional_info(common, __VA_ARGS__) \
102 .do_static_compilation(true);
107 "workbench_shadow_no_debug")
112 "workbench_shadow_debug")
#define DRW_VISIBILITY_GROUP_SIZE
#define GPU_SHADER_CREATE_INFO(_info)
#define WORKBENCH_SHADOW_VARIATIONS(common, prefix, suffix,...)