mirror of
https://github.com/blender/blender
synced 2026-11-22 03:45:13 +03:00
This is done by using a define for each create info resource frequency. This allows to remove the implicit source include ordering. This requires the correct `*infos.hh` file is included in the shader source. The info file needs to include any shared header that is needed for buffer declarations (previously `TYPEDEF_SOURCE`). This patch mostly contains those changes. The `*infos.hh` files are now parsed and part of the shader source include tree. The result of the parser for now is a simple replacement with some placeholder macros for the resource definition that are created at runtime. This is to avoid complicated and error prone search and replace of the placeholder at runtime. Note that including the infos files inflate the final source quite a bit because the create info are usually shared with many shaders that have different requirements. The follow up task for reducing this overhead is to move the create info back to the associated files or group them by dependencies (by typedef_source or by create info include). While the immediate side effect might look like this makes the shader codebase include deps more spaghetti-like, it only exposes the issue that was already there. Now it is just more apparent. To avoid `gpu_shader_fullscreen_vert.glsl` including all the engines shared headers, we have to duplicate it per engine. Rel #137446 Pull Request: https://projects.blender.org/blender/blender/pulls/149263 |
||
|---|---|---|
| .. | ||
| internal | ||
| stub | ||
| CMakeLists.txt | ||
| opensubdiv_capi.hh | ||
| opensubdiv_capi_type.hh | ||
| opensubdiv_converter_capi.hh | ||
| opensubdiv_evaluator.hh | ||
| opensubdiv_evaluator_capi.hh | ||
| opensubdiv_topology_refiner.hh | ||