From 0d9ea809dd436b631874f65d100eac95764ef349 Mon Sep 17 00:00:00 2001 From: baldurk Date: Fri, 17 Nov 2023 16:58:54 +0000 Subject: [PATCH] Fix some test failures by consistently stripping gl_PerVertex_Var prefix --- .../shaders/spirv/spirv_debug_setup.cpp | 2 + .../driver/shaders/spirv/spirv_reflect.cpp | 34 +++++++------ .../driver/shaders/spirv/spirv_reflect.h | 2 + .../tests/Vulkan/VK_Dedicated_Allocation.py | 6 +-- .../test/tests/Vulkan/VK_Dynamic_Rendering.py | 6 +-- .../tests/Vulkan/VK_Extended_Dynamic_State.py | 8 ++-- util/test/tests/Vulkan/VK_Frame0.py | 6 +-- .../test/tests/Vulkan/VK_Graphics_Pipeline.py | 6 +-- util/test/tests/Vulkan/VK_Indirect.py | 48 +++++++++---------- util/test/tests/Vulkan/VK_Int8_IBuffer.py | 6 +-- util/test/tests/Vulkan/VK_Large_Buffer.py | 6 +-- util/test/tests/Vulkan/VK_Mesh_Zoo.py | 8 ++-- util/test/tests/Vulkan/VK_Misaligned_Dirty.py | 6 +-- util/test/tests/Vulkan/VK_Robustness2.py | 6 +-- util/test/tests/Vulkan/VK_Simple_Triangle.py | 6 +-- util/test/tests/Vulkan/VK_Vertex_Attr_Zoo.py | 12 ++--- 16 files changed, 88 insertions(+), 80 deletions(-) diff --git a/renderdoc/driver/shaders/spirv/spirv_debug_setup.cpp b/renderdoc/driver/shaders/spirv/spirv_debug_setup.cpp index 0cb92bf9fa..bf476da234 100644 --- a/renderdoc/driver/shaders/spirv/spirv_debug_setup.cpp +++ b/renderdoc/driver/shaders/spirv/spirv_debug_setup.cpp @@ -966,6 +966,8 @@ ShaderDebugTrace *Debugger::BeginDebug(DebugAPIWrapper *api, const ShaderStage s sourceVar.columns = var.columns; sourceVar.signatureIndex = sigNames.indexOf(debugVarName); + StripCommonGLPrefixes(sourceVar.name); + for(uint32_t x = 0; x < uint32_t(var.rows) * var.columns; x++) sourceVar.variables.push_back(DebugVariableReference( isInput ? DebugVariableType::Input : DebugVariableType::Variable, debugVarName, x)); diff --git a/renderdoc/driver/shaders/spirv/spirv_reflect.cpp b/renderdoc/driver/shaders/spirv/spirv_reflect.cpp index 58f1a414a8..3a26578bd8 100644 --- a/renderdoc/driver/shaders/spirv/spirv_reflect.cpp +++ b/renderdoc/driver/shaders/spirv/spirv_reflect.cpp @@ -30,6 +30,24 @@ #include "spirv_editor.h" #include "spirv_op_helpers.h" +void StripCommonGLPrefixes(rdcstr &name) +{ + // remove certain common prefixes that generate only useless noise from GLSL. This is mostly + // irrelevant for the majority of cases but is primarily relevant for single-component outputs + // like gl_PointSize or gl_CullPrimitiveEXT + const rdcstr prefixesToRemove[] = { + "gl_PerVertex.", "gl_PerVertex_var.", "gl_MeshVerticesEXT.", + "gl_MeshVerticesEXT_var.", "gl_MeshPrimitivesEXT.", "gl_MeshPrimitivesEXT_var.", + }; + + for(const rdcstr &prefix : prefixesToRemove) + { + int offs = name.find(prefix); + if(offs == 0) + name.erase(0, prefix.length()); + } +} + void FillSpecConstantVariables(ResourceId shader, const SPIRVPatchData &patchData, const rdcarray &invars, rdcarray &outvars, @@ -2210,21 +2228,7 @@ void Reflector::AddSignatureParameter(const bool isInput, const ShaderStage stag if(isArray) n += StringFormat::Fmt("[%u]", a); - - // remove certain common prefixes that generate only useless noise from GLSL. This is mostly - // irrelevant for the majority of cases but is primarily relevant for single-component outputs - // like gl_PointSize or gl_CullPrimitiveEXT - const rdcstr prefixesToRemove[] = { - "gl_PerVertex.", "gl_PerVertex_var.", "gl_MeshVerticesEXT.", - "gl_MeshVerticesEXT_var.", "gl_MeshPrimitivesEXT.", "gl_MeshPrimitivesEXT_var.", - }; - - for(const rdcstr &prefix : prefixesToRemove) - { - int offs = n.find(prefix); - if(offs == 0) - n.erase(0, prefix.length()); - } + StripCommonGLPrefixes(n); sig.varName = n; diff --git a/renderdoc/driver/shaders/spirv/spirv_reflect.h b/renderdoc/driver/shaders/spirv/spirv_reflect.h index b6e024a6f3..32077e9382 100644 --- a/renderdoc/driver/shaders/spirv/spirv_reflect.h +++ b/renderdoc/driver/shaders/spirv/spirv_reflect.h @@ -157,6 +157,8 @@ class Reflector : public Processor }; // namespace rdcspv +void StripCommonGLPrefixes(rdcstr &name); + void FillSpecConstantVariables(ResourceId shader, const SPIRVPatchData &patchData, const rdcarray &invars, rdcarray &outvars, diff --git a/util/test/tests/Vulkan/VK_Dedicated_Allocation.py b/util/test/tests/Vulkan/VK_Dedicated_Allocation.py index c06da54553..8f79fc012a 100644 --- a/util/test/tests/Vulkan/VK_Dedicated_Allocation.py +++ b/util/test/tests/Vulkan/VK_Dedicated_Allocation.py @@ -16,7 +16,7 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.5, 0.5, 0.0, 1.0], + 'gl_Position': [-0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [-0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], @@ -24,7 +24,7 @@ def check_capture(self): 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [0.0, -0.5, 0.0, 1.0], + 'gl_Position': [0.0, -0.5, 0.0, 1.0], 'vertOut.pos': [0.0, -0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 1.0, 0.0, 1.0], @@ -32,7 +32,7 @@ def check_capture(self): 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [0.5, 0.5, 0.0, 1.0], + 'gl_Position': [0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [1.0, 0.0, 0.0, 1.0], diff --git a/util/test/tests/Vulkan/VK_Dynamic_Rendering.py b/util/test/tests/Vulkan/VK_Dynamic_Rendering.py index 215f2aac40..d462582358 100644 --- a/util/test/tests/Vulkan/VK_Dynamic_Rendering.py +++ b/util/test/tests/Vulkan/VK_Dynamic_Rendering.py @@ -23,7 +23,7 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.5, 0.5, 0.0, 1.0], + 'gl_Position': [-0.5, 0.5, 0.0, 1.0], 'gout.pos': [-0.5, 0.5, 0.0, 1.0], 'gout.col': [0.0, 1.0, 0.0, 1.0], 'gout.uv': [0.0, 0.0, 0.0, 1.0], @@ -31,7 +31,7 @@ def check_capture(self): 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [0.0, -0.5, 0.0, 1.0], + 'gl_Position': [0.0, -0.5, 0.0, 1.0], 'gout.pos': [0.0, -0.5, 0.0, 1.0], 'gout.col': [0.0, 1.0, 0.0, 1.0], 'gout.uv': [0.0, 1.0, 0.0, 1.0], @@ -39,7 +39,7 @@ def check_capture(self): 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [0.5, 0.5, 0.0, 1.0], + 'gl_Position': [0.5, 0.5, 0.0, 1.0], 'gout.pos': [0.5, 0.5, 0.0, 1.0], 'gout.col': [0.0, 1.0, 0.0, 1.0], 'gout.uv': [1.0, 0.0, 0.0, 1.0], diff --git a/util/test/tests/Vulkan/VK_Extended_Dynamic_State.py b/util/test/tests/Vulkan/VK_Extended_Dynamic_State.py index d881ed9bc2..de1e83504c 100644 --- a/util/test/tests/Vulkan/VK_Extended_Dynamic_State.py +++ b/util/test/tests/Vulkan/VK_Extended_Dynamic_State.py @@ -49,28 +49,28 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.75, 0.5, 0.4, 1.0], + 'gl_Position': [-0.75, 0.5, 0.4, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], }, 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [-0.25, -0.5, 0.4, 1.0], + 'gl_Position': [-0.25, -0.5, 0.4, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 1.0, 0.0, 1.0], }, 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [0.25, 0.5, 0.4, 1.0], + 'gl_Position': [0.25, 0.5, 0.4, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [1.0, 0.0, 0.0, 1.0], }, 5: { 'vtx': 5, 'idx': 5, - 'gl_PerVertex_var.gl_Position': [0.75, 0.5, 0.6, 1.0], + 'gl_Position': [0.75, 0.5, 0.6, 1.0], 'vertOut.col': [0.0, 0.0, 1.0, 1.0], 'vertOut.uv': [1.0, 0.0, 0.0, 1.0], }, diff --git a/util/test/tests/Vulkan/VK_Frame0.py b/util/test/tests/Vulkan/VK_Frame0.py index 2b6456647a..742dc8ce2f 100644 --- a/util/test/tests/Vulkan/VK_Frame0.py +++ b/util/test/tests/Vulkan/VK_Frame0.py @@ -37,7 +37,7 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.5, 0.5, 0.0, 1.0], + 'gl_Position': [-0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [-0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], @@ -45,7 +45,7 @@ def check_capture(self): 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [0.0, -0.5, 0.0, 1.0], + 'gl_Position': [0.0, -0.5, 0.0, 1.0], 'vertOut.pos': [0.0, -0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 1.0, 0.0, 1.0], @@ -53,7 +53,7 @@ def check_capture(self): 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [0.5, 0.5, 0.0, 1.0], + 'gl_Position': [0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [1.0, 0.0, 0.0, 1.0], diff --git a/util/test/tests/Vulkan/VK_Graphics_Pipeline.py b/util/test/tests/Vulkan/VK_Graphics_Pipeline.py index 96f9a9b0e4..831626efd6 100644 --- a/util/test/tests/Vulkan/VK_Graphics_Pipeline.py +++ b/util/test/tests/Vulkan/VK_Graphics_Pipeline.py @@ -26,7 +26,7 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.5, 0.5, 0.0, 1.0], + 'gl_Position': [-0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [-0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], @@ -34,7 +34,7 @@ def check_capture(self): 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [0.0, -0.5, 0.0, 1.0], + 'gl_Position': [0.0, -0.5, 0.0, 1.0], 'vertOut.pos': [0.0, -0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 1.0, 0.0, 1.0], @@ -42,7 +42,7 @@ def check_capture(self): 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [0.5, 0.5, 0.0, 1.0], + 'gl_Position': [0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [1.0, 0.0, 0.0, 1.0], diff --git a/util/test/tests/Vulkan/VK_Indirect.py b/util/test/tests/Vulkan/VK_Indirect.py index efbb159ce4..4312894701 100644 --- a/util/test/tests/Vulkan/VK_Indirect.py +++ b/util/test/tests/Vulkan/VK_Indirect.py @@ -219,9 +219,9 @@ def check_capture(self): postvs_data = self.get_postvs(action, rd.MeshDataStage.VSOut) postvs_ref = { - 0: {'vtx': 0, 'idx': 0, 'gl_PerVertex_var.gl_Position': [-0.8, -0.5, 0.0, 1.0]}, - 1: {'vtx': 1, 'idx': 1, 'gl_PerVertex_var.gl_Position': [-0.7, -0.8, 0.0, 1.0]}, - 2: {'vtx': 2, 'idx': 2, 'gl_PerVertex_var.gl_Position': [-0.6, -0.5, 0.0, 1.0]}, + 0: {'vtx': 0, 'idx': 0, 'gl_Position': [-0.8, -0.5, 0.0, 1.0]}, + 1: {'vtx': 1, 'idx': 1, 'gl_Position': [-0.7, -0.8, 0.0, 1.0]}, + 2: {'vtx': 2, 'idx': 2, 'gl_Position': [-0.6, -0.5, 0.0, 1.0]}, } self.check_mesh_data(postvs_ref, postvs_data) @@ -246,9 +246,9 @@ def check_capture(self): # These indices are the *output* indices, which have been rebased/remapped, so are not the same as the input # indices postvs_ref = { - 0: {'vtx': 0, 'idx': 6, 'gl_PerVertex_var.gl_Position': [-0.6, -0.5, 0.0, 1.0]}, - 1: {'vtx': 1, 'idx': 7, 'gl_PerVertex_var.gl_Position': [-0.5, -0.8, 0.0, 1.0]}, - 2: {'vtx': 2, 'idx': 8, 'gl_PerVertex_var.gl_Position': [-0.4, -0.5, 0.0, 1.0]}, + 0: {'vtx': 0, 'idx': 6, 'gl_Position': [-0.6, -0.5, 0.0, 1.0]}, + 1: {'vtx': 1, 'idx': 7, 'gl_Position': [-0.5, -0.8, 0.0, 1.0]}, + 2: {'vtx': 2, 'idx': 8, 'gl_Position': [-0.4, -0.5, 0.0, 1.0]}, } self.check_mesh_data(postvs_ref, postvs_data) @@ -269,13 +269,13 @@ def check_capture(self): postvs_data = self.get_postvs(action, rd.MeshDataStage.VSOut) postvs_ref = { - 0: {'vtx': 0, 'idx': 9, 'gl_PerVertex_var.gl_Position': [-0.4, -0.5, 0.0, 1.0]}, - 1: {'vtx': 1, 'idx': 10, 'gl_PerVertex_var.gl_Position': [-0.3, -0.8, 0.0, 1.0]}, - 2: {'vtx': 2, 'idx': 11, 'gl_PerVertex_var.gl_Position': [-0.2, -0.8, 0.0, 1.0]}, + 0: {'vtx': 0, 'idx': 9, 'gl_Position': [-0.4, -0.5, 0.0, 1.0]}, + 1: {'vtx': 1, 'idx': 10, 'gl_Position': [-0.3, -0.8, 0.0, 1.0]}, + 2: {'vtx': 2, 'idx': 11, 'gl_Position': [-0.2, -0.8, 0.0, 1.0]}, - 3: {'vtx': 3, 'idx': 12, 'gl_PerVertex_var.gl_Position': [-0.1, -0.5, 0.0, 1.0]}, - 4: {'vtx': 4, 'idx': 13, 'gl_PerVertex_var.gl_Position': [ 0.0, -0.8, 0.0, 1.0]}, - 5: {'vtx': 5, 'idx': 14, 'gl_PerVertex_var.gl_Position': [ 0.1, -0.8, 0.0, 1.0]}, + 3: {'vtx': 3, 'idx': 12, 'gl_Position': [-0.1, -0.5, 0.0, 1.0]}, + 4: {'vtx': 4, 'idx': 13, 'gl_Position': [ 0.0, -0.8, 0.0, 1.0]}, + 5: {'vtx': 5, 'idx': 14, 'gl_Position': [ 0.1, -0.8, 0.0, 1.0]}, } self.check_mesh_data(postvs_ref, postvs_data) @@ -327,9 +327,9 @@ def check_capture(self): # These indices are the *output* indices, which have been rebased/remapped, so are not the same as the input # indices postvs_ref = { - 0: {'vtx': 0, 'idx': 0, 'gl_PerVertex_var.gl_Position': [-0.8, 0.5, 0.0, 1.0]}, - 1: {'vtx': 1, 'idx': 1, 'gl_PerVertex_var.gl_Position': [-0.7, 0.2, 0.0, 1.0]}, - 2: {'vtx': 2, 'idx': 2, 'gl_PerVertex_var.gl_Position': [-0.6, 0.5, 0.0, 1.0]}, + 0: {'vtx': 0, 'idx': 0, 'gl_Position': [-0.8, 0.5, 0.0, 1.0]}, + 1: {'vtx': 1, 'idx': 1, 'gl_Position': [-0.7, 0.2, 0.0, 1.0]}, + 2: {'vtx': 2, 'idx': 2, 'gl_Position': [-0.6, 0.5, 0.0, 1.0]}, } self.check_mesh_data(postvs_ref, postvs_data) @@ -357,9 +357,9 @@ def check_capture(self): # These indices are the *output* indices, which have been rebased/remapped, so are not the same as the input # indices postvs_ref = { - 0: {'vtx': 0, 'idx': 15, 'gl_PerVertex_var.gl_Position': [-0.6, 0.5, 0.0, 1.0]}, - 1: {'vtx': 1, 'idx': 16, 'gl_PerVertex_var.gl_Position': [-0.5, 0.2, 0.0, 1.0]}, - 2: {'vtx': 2, 'idx': 17, 'gl_PerVertex_var.gl_Position': [-0.4, 0.5, 0.0, 1.0]}, + 0: {'vtx': 0, 'idx': 15, 'gl_Position': [-0.6, 0.5, 0.0, 1.0]}, + 1: {'vtx': 1, 'idx': 16, 'gl_Position': [-0.5, 0.2, 0.0, 1.0]}, + 2: {'vtx': 2, 'idx': 17, 'gl_Position': [-0.4, 0.5, 0.0, 1.0]}, } self.check_mesh_data(postvs_ref, postvs_data) @@ -397,13 +397,13 @@ def check_capture(self): # These indices are the *output* indices, which have been rebased/remapped, so are not the same as the input # indices postvs_ref = { - 0: {'vtx': 0, 'idx': 18, 'gl_PerVertex_var.gl_Position': [-0.4, 0.5, 0.0, 1.0]}, - 1: {'vtx': 1, 'idx': 19, 'gl_PerVertex_var.gl_Position': [-0.3, 0.2, 0.0, 1.0]}, - 2: {'vtx': 2, 'idx': 20, 'gl_PerVertex_var.gl_Position': [-0.2, 0.2, 0.0, 1.0]}, + 0: {'vtx': 0, 'idx': 18, 'gl_Position': [-0.4, 0.5, 0.0, 1.0]}, + 1: {'vtx': 1, 'idx': 19, 'gl_Position': [-0.3, 0.2, 0.0, 1.0]}, + 2: {'vtx': 2, 'idx': 20, 'gl_Position': [-0.2, 0.2, 0.0, 1.0]}, - 3: {'vtx': 3, 'idx': 21, 'gl_PerVertex_var.gl_Position': [-0.1, 0.5, 0.0, 1.0]}, - 4: {'vtx': 4, 'idx': 22, 'gl_PerVertex_var.gl_Position': [ 0.0, 0.2, 0.0, 1.0]}, - 5: {'vtx': 5, 'idx': 23, 'gl_PerVertex_var.gl_Position': [ 0.1, 0.2, 0.0, 1.0]}, + 3: {'vtx': 3, 'idx': 21, 'gl_Position': [-0.1, 0.5, 0.0, 1.0]}, + 4: {'vtx': 4, 'idx': 22, 'gl_Position': [ 0.0, 0.2, 0.0, 1.0]}, + 5: {'vtx': 5, 'idx': 23, 'gl_Position': [ 0.1, 0.2, 0.0, 1.0]}, } self.check_mesh_data(postvs_ref, postvs_data) diff --git a/util/test/tests/Vulkan/VK_Int8_IBuffer.py b/util/test/tests/Vulkan/VK_Int8_IBuffer.py index 40ef2847fc..8b3503faa9 100644 --- a/util/test/tests/Vulkan/VK_Int8_IBuffer.py +++ b/util/test/tests/Vulkan/VK_Int8_IBuffer.py @@ -26,14 +26,14 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.8, -0.2, 0.0, 1.0], + 'gl_Position': [-0.8, -0.2, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], }, 4: { 'vtx': 4, 'idx': 4, - 'gl_PerVertex_var.gl_Position': [0.0, -0.2, 0.0, 1.0], + 'gl_Position': [0.0, -0.2, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], }, @@ -43,7 +43,7 @@ def check_capture(self): 9: { 'vtx': 9, 'idx': 8, - 'gl_PerVertex_var.gl_Position': [-0.8, 0.7, 0.0, 1.0], + 'gl_Position': [-0.8, 0.7, 0.0, 1.0], 'vertOut.col': [0.0, 0.0, 1.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], }, diff --git a/util/test/tests/Vulkan/VK_Large_Buffer.py b/util/test/tests/Vulkan/VK_Large_Buffer.py index 0f867b12e6..3854d3924a 100644 --- a/util/test/tests/Vulkan/VK_Large_Buffer.py +++ b/util/test/tests/Vulkan/VK_Large_Buffer.py @@ -42,7 +42,7 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.5, 0.5, 0.0, 1.0], + 'gl_Position': [-0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [-0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], @@ -50,7 +50,7 @@ def check_capture(self): 1: { 'vtx': 1, 'idx': 1000000, - 'gl_PerVertex_var.gl_Position': [0.0, -0.5, 0.0, 1.0], + 'gl_Position': [0.0, -0.5, 0.0, 1.0], 'vertOut.pos': [0.0, -0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 1.0, 0.0, 1.0], @@ -58,7 +58,7 @@ def check_capture(self): 2: { 'vtx': 2, 'idx': 2345678, - 'gl_PerVertex_var.gl_Position': [0.5, 0.5, 0.0, 1.0], + 'gl_Position': [0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [1.0, 0.0, 0.0, 1.0], diff --git a/util/test/tests/Vulkan/VK_Mesh_Zoo.py b/util/test/tests/Vulkan/VK_Mesh_Zoo.py index 8e50db08a4..d30b09c4c4 100644 --- a/util/test/tests/Vulkan/VK_Mesh_Zoo.py +++ b/util/test/tests/Vulkan/VK_Mesh_Zoo.py @@ -24,25 +24,25 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [0.8, 0.8, 0.0, 1.0], + 'gl_Position': [0.8, 0.8, 0.0, 1.0], 'uv1': [0.5, 0.5], }, 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [0.8, 0.9, 0.0, 1.0], + 'gl_Position': [0.8, 0.9, 0.0, 1.0], 'uv1': [0.6, 0.6], }, 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [0.9, 0.8, 0.0, 1.0], + 'gl_Position': [0.9, 0.8, 0.0, 1.0], 'uv1': [0.7, 0.7], }, 3: { 'vtx': 3, 'idx': 3, - 'gl_PerVertex_var.gl_Position': [0.9, 0.9, 0.0, 1.0], + 'gl_Position': [0.9, 0.9, 0.0, 1.0], 'uv1': [0.8, 0.8], }, } diff --git a/util/test/tests/Vulkan/VK_Misaligned_Dirty.py b/util/test/tests/Vulkan/VK_Misaligned_Dirty.py index fbd88a2902..37be4feb49 100644 --- a/util/test/tests/Vulkan/VK_Misaligned_Dirty.py +++ b/util/test/tests/Vulkan/VK_Misaligned_Dirty.py @@ -40,19 +40,19 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-val, val, val, 1.0], + 'gl_Position': [-val, val, val, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], }, 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [0.0, -val, val, 1.0], + 'gl_Position': [0.0, -val, val, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], }, 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [val, val, val, 1.0], + 'gl_Position': [val, val, val, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], }, } diff --git a/util/test/tests/Vulkan/VK_Robustness2.py b/util/test/tests/Vulkan/VK_Robustness2.py index 158d4e45c1..a5e1fe06c8 100644 --- a/util/test/tests/Vulkan/VK_Robustness2.py +++ b/util/test/tests/Vulkan/VK_Robustness2.py @@ -48,7 +48,7 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.5, 0.5, 0.0, 1.0], + 'gl_Position': [-0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [-0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 0.0, 0.0, 0.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], @@ -56,7 +56,7 @@ def check_capture(self): 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [0.0, -0.5, 0.0, 1.0], + 'gl_Position': [0.0, -0.5, 0.0, 1.0], 'vertOut.pos': [0.0, -0.5, 0.0, 1.0], 'vertOut.col': [0.0, 0.0, 0.0, 0.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], @@ -64,7 +64,7 @@ def check_capture(self): 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [0.5, 0.5, 0.0, 1.0], + 'gl_Position': [0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 0.0, 0.0, 0.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], diff --git a/util/test/tests/Vulkan/VK_Simple_Triangle.py b/util/test/tests/Vulkan/VK_Simple_Triangle.py index 604d59a0d5..74948fa0f8 100644 --- a/util/test/tests/Vulkan/VK_Simple_Triangle.py +++ b/util/test/tests/Vulkan/VK_Simple_Triangle.py @@ -24,7 +24,7 @@ def check_capture(self): 0: { 'vtx': 0, 'idx': 0, - 'gl_PerVertex_var.gl_Position': [-0.5, 0.5, 0.0, 1.0], + 'gl_Position': [-0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [-0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 0.0, 0.0, 1.0], @@ -32,7 +32,7 @@ def check_capture(self): 1: { 'vtx': 1, 'idx': 1, - 'gl_PerVertex_var.gl_Position': [0.0, -0.5, 0.0, 1.0], + 'gl_Position': [0.0, -0.5, 0.0, 1.0], 'vertOut.pos': [0.0, -0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [0.0, 1.0, 0.0, 1.0], @@ -40,7 +40,7 @@ def check_capture(self): 2: { 'vtx': 2, 'idx': 2, - 'gl_PerVertex_var.gl_Position': [0.5, 0.5, 0.0, 1.0], + 'gl_Position': [0.5, 0.5, 0.0, 1.0], 'vertOut.pos': [0.5, 0.5, 0.0, 1.0], 'vertOut.col': [0.0, 1.0, 0.0, 1.0], 'vertOut.uv': [1.0, 0.0, 0.0, 1.0], diff --git a/util/test/tests/Vulkan/VK_Vertex_Attr_Zoo.py b/util/test/tests/Vulkan/VK_Vertex_Attr_Zoo.py index 3a3c27efbe..c5c2c8e385 100644 --- a/util/test/tests/Vulkan/VK_Vertex_Attr_Zoo.py +++ b/util/test/tests/Vulkan/VK_Vertex_Attr_Zoo.py @@ -93,14 +93,14 @@ def check_capture(self): vsout_ref = copy.deepcopy(out_ref) gsout_ref = out_ref - vsout_ref[0]['gl_PerVertex_var.gl_Position'] = [-0.5, 0.5, 0.0, 1.0] - gsout_ref[0]['gl_PerVertex_var.gl_Position'] = [0.5, -0.5, 0.4, 1.2] + vsout_ref[0]['gl_Position'] = [-0.5, 0.5, 0.0, 1.0] + gsout_ref[0]['gl_Position'] = [0.5, -0.5, 0.4, 1.2] - vsout_ref[1]['gl_PerVertex_var.gl_Position'] = [0.0, -0.5, 0.0, 1.0] - gsout_ref[1]['gl_PerVertex_var.gl_Position'] = [-0.5, 0.0, 0.4, 1.2] + vsout_ref[1]['gl_Position'] = [0.0, -0.5, 0.0, 1.0] + gsout_ref[1]['gl_Position'] = [-0.5, 0.0, 0.4, 1.2] - vsout_ref[2]['gl_PerVertex_var.gl_Position'] = [0.5, 0.5, 0.0, 1.0] - gsout_ref[2]['gl_PerVertex_var.gl_Position'] = [0.5, 0.5, 0.4, 1.2] + vsout_ref[2]['gl_Position'] = [0.5, 0.5, 0.0, 1.0] + gsout_ref[2]['gl_Position'] = [0.5, 0.5, 0.4, 1.2] self.check_mesh_data(in_ref, self.get_vsin(action)) rdtest.log.success("Vertex input data is as expected")