Skip to content

ShaderC dependencies and Shader Compilation Refactor#504

Merged
JeanPhilippeKernel merged 1 commit intoJeanPhilippeKernel:developfrom
MathewBensonCode:cmake_shader_compile
Mar 12, 2026
Merged

ShaderC dependencies and Shader Compilation Refactor#504
JeanPhilippeKernel merged 1 commit intoJeanPhilippeKernel:developfrom
MathewBensonCode:cmake_shader_compile

Conversation

@MathewBensonCode
Copy link
Contributor

@MathewBensonCode MathewBensonCode commented Feb 8, 2026

  • We remove the use of the shaderc download, which was only being used for compiling shaders.
  • We instead use the glslang compiler that we we're compiling anyway.
  • This way we can extract the glslang compiler that we have compiled and do the shader compilation as part of the CMake Scripting.
  • This should reduce the compilation times and/or storage requirements.
  • As Currently configured the Shaders will be compiled in each build, however, we can improve on this and ensure that compilation is only done as required at a later stage.

Should Close #481

@MathewBensonCode MathewBensonCode marked this pull request as draft February 8, 2026 22:06
@MathewBensonCode
Copy link
Contributor Author

I initially attempted to use the ShaderC library to reduce the compilation by trying to use the Iibraries in the ShaderC package but ran into various linking errors on the different systems. I had worked locally for me though.

It was also not possible to use it with the macOS arm build as the ShaderC libraries available online are only x86-64.

So I went with the option of removing the ShaderC download step and shader compilation using powershell and instead incorporate it into the CMake workflow

@MathewBensonCode MathewBensonCode marked this pull request as ready for review February 9, 2026 05:51
@JeanPhilippeKernel JeanPhilippeKernel added enhancement New feature or request area-linux Work on Linux system area-window Work on Window system area-macOS Work on macOS system labels Mar 5, 2026
@JeanPhilippeKernel JeanPhilippeKernel added this to the Born baby (0.2.0) milestone Mar 5, 2026
@JeanPhilippeKernel JeanPhilippeKernel self-requested a review March 8, 2026 13:15
@JeanPhilippeKernel JeanPhilippeKernel moved this to In Progress in ZEngine Board Mar 8, 2026
@MathewBensonCode MathewBensonCode marked this pull request as draft March 12, 2026 10:58
- We remove the use of the shaderc download, which was only being used
  for compiling shaders.
- We instead use the glslang compiler that we we're compiling anyway.
- This way we can extract the glslang compiler that we have compiled
  and do the shader compilation as part of the CMake Scripting.
- This should reduce the compilation times and/or storage requirements.
- As Currently configured the Shaders will be compiled in each build,
  however, we can improve on this and ensure that compilation is only
  done as required at a later stage
@MathewBensonCode MathewBensonCode marked this pull request as ready for review March 12, 2026 12:54
Copy link
Owner

@JeanPhilippeKernel JeanPhilippeKernel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for this awesome PR 🎉

@JeanPhilippeKernel JeanPhilippeKernel merged commit 29d0bac into JeanPhilippeKernel:develop Mar 12, 2026
21 checks passed
@github-project-automation github-project-automation bot moved this from In Progress to Done in ZEngine Board Mar 12, 2026
@MathewBensonCode MathewBensonCode deleted the cmake_shader_compile branch March 12, 2026 22:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-linux Work on Linux system area-macOS Work on macOS system area-window Work on Window system enhancement New feature or request

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Duplicate Production of Shader Compilation Tools

3 participants