bkaradzic/bgfx

Shaderc.cpp incorrectly adds PSSL preamble to compute shader

00bins opened this issue · 1 comments

Line 1550 of shaderc.cpp reads

if (profile->lang != ShadingLang::PSSL)
{
	preprocessor.writef(getPsslPreamble() );
}

should read

if (profile->lang == ShadingLang::PSSL)
{
	preprocessor.writef(getPsslPreamble() );
}

This is only a problem if you have pssl support and getPsslPreamble() doesn't return ""

Send PR with fix.