mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-08-26 16:36:31 +00:00
Create virtual distinction between Vulkan & GL SPIR-V. Closes #2798
* This distinction unfortunately does not exist in SPIR-V so we have to carry around this metadata ourselves. Rather than allowing free specification of tools based on API, instead pretend that Vulkan and GL SPIR-V are separate format, and duplicate all SPIR-V tools to handle "both" types. This allows appropriate tool selection based on the encoding.
This commit is contained in:
@@ -60,6 +60,7 @@ static QMap<QString, ShaderEncoding> encodingExtensions = {
|
||||
{lit("glsl"), ShaderEncoding::GLSL},
|
||||
{lit("frag"), ShaderEncoding::GLSL},
|
||||
{lit("spvasm"), ShaderEncoding::SPIRVAsm},
|
||||
{lit("spvasm"), ShaderEncoding::OpenGLSPIRVAsm},
|
||||
};
|
||||
|
||||
Q_DECLARE_METATYPE(Following);
|
||||
@@ -4537,7 +4538,7 @@ void TextureViewer::on_customCreate_clicked()
|
||||
" color_out = vec4(0,0,0,1);\n"
|
||||
"}\n");
|
||||
}
|
||||
else if(enc == ShaderEncoding::SPIRVAsm)
|
||||
else if(enc == ShaderEncoding::SPIRVAsm || enc == ShaderEncoding::OpenGLSPIRVAsm)
|
||||
{
|
||||
src = lit("; SPIR-V");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user