Download

Possible to Compile User-Defined Shaders at Runtime?

Hi there!

I have a project I am working on that is driven by user-created content that could really benefit from allowing users to create their own shaders.

I’m aware of how to create custom shaders using something like GitHub - Temaran/UE4ShaderPluginDemo: A tutorial project that shows how to implement HLSL Pixel and Compute shaders in UE4 but those still end up getting cooked when packaging for distribution.

I’m only targeting Windows as a platform and I’m happy to have to include usually editor-specific files like the ShaderCompileWorker or to build the engine from source and make modifications as necessary to allow for this if someone could point me in the right direction. I’m not concerned with temporary materials at run-time while compiling (as with in the editor) or any small delay required to compile the shaders if that’s what’s required.

Thanks in advance for any ideas!