Releases: hyzboy/GLSLCompiler
Releases · hyzboy/GLSLCompiler
1.05
Upgraded SPIRV-Cross to 2023.02.18 and Added GetLimit/SetLimit functions.
Optimized layout of codes marked it easier to read.
struct GLSLCompilerInterface
{
bool (*Init)();
void (*Close)();
bool (*GetLimit)(TBuiltInResource *,const int);
bool (*SetLimit)(TBuiltInResource *,const int);
uint32_t (*GetType)(const char *ext_name);
SPVData * (*Compile)(const uint32_t stage,const char *shader_source, const CompileInfo *compile_info);
SPVData * (*CompileFromPath)(const uint32_t stage,const char *shader_filename, const CompileInfo *compile_info);
void (*Free)(SPVData *);
};
v1.04
v1.03
new interface.
enum class ShaderLanguageType
{
GLSL=0,
HLSL,
MAX=0xff
};//enum class ShaderType
struct CompileInfo
{
ShaderLanguageType shader_type = ShaderLanguageType::GLSL;
const char *entrypoint;
uint32_t includes_count;
const char **includes;
};
struct GLSLCompilerInterface
{
bool (*Init)();
void (*Close)();
uint32_t (*GetType)(const char *ext_name);
SPVData * (*Compile)(const uint32_t stage,const char *source, const CompileInfo *compile_info);
SPVData * (*CompileFromPath)(const uint32_t stage,const char *path, const CompileInfo *compile_info);
void (*Free)(SPVData *);
};
Force Vulkan1.2 and Core , desktop profile
set the target version to Vulkan 1.2 by glslang::TShader::setEnvClient
set use OpenGL Core profile by glslang::TShader::parse
set the default version to 110 by glslang::TShader::parse
v1.01
first version
- generate .spv file (same glslangValidator)
- generate .shader file (include spv data and VkDescriptorSets info)