I am currently working on a little graphics demo (using DirectX) which is primarily based around an HLSL shader I am working on. Using the D3DX10CreateEffectFromFile I am loading (and compiling the shader) at runtime as I find it easier for tweaking.
However, once I am done I'd like to do some combination of the following:
- Pre-compile the shader so the demo starts up faster for the user
- Bury (compile into the executable) the compiled shader (or maybe just the source if necessary)
Primarily, I want to do this because I want the demo to just be one file that can be very easily copied around.
One thing I could easily do is just put the source text right into a cpp but that would be very tedious I needed to update it later.
Is it possible to do something like this (using Visual Studio, DirectX, HLSL)?