On Thursday, 10 July 2014 at 15:38:07 UTC, ponce wrote:
You might want to look at what bgfx does: https://github.com/bkaradzic/bgfx
It provides a shader compiler to various supported backends.

I have seen it but I have never used it. I don't actually know if
its any good or not but it is in the same vein of what I am
talking about.

Abstracting shaders more or less mandates having a shader compiler from your language to graphics API out there. It does make an additional build step.

It would be complicated yes but certainly doable.

Compiling such a shader abstraction language at compile-time seems a bit optimistic to me.

Maybe a little now but in the future maybe not, things are always
improving. It is also one of the reason I wish we could call out
to precompiled code at compile time, make it possible to have
inline shaders passed out of the compiler at compile time and
compiled by some other app.

Reply via email to