Browse Source

spirv_emit_context: Fix BaseInstance for OGL spirv

nce_cpp
Ameer J 2 years ago
parent
commit
deb6899663
  1. 2
      src/shader_recompiler/backend/spirv/spirv_emit_context.cpp

2
src/shader_recompiler/backend/spirv/spirv_emit_context.cpp

@ -1427,7 +1427,7 @@ void EmitContext::DefineInputs(const IR::Program& program) {
if (profile.support_vertex_instance_id) { if (profile.support_vertex_instance_id) {
instance_id = DefineInput(*this, U32[1], true, spv::BuiltIn::InstanceId); instance_id = DefineInput(*this, U32[1], true, spv::BuiltIn::InstanceId);
if (loads[IR::Attribute::BaseInstance]) { if (loads[IR::Attribute::BaseInstance]) {
base_instance = DefineInput(*this, U32[1], true, spv::BuiltIn::BaseVertex);
base_instance = DefineInput(*this, U32[1], true, spv::BuiltIn::BaseInstance);
} }
} else { } else {
instance_index = DefineInput(*this, U32[1], true, spv::BuiltIn::InstanceIndex); instance_index = DefineInput(*this, U32[1], true, spv::BuiltIn::InstanceIndex);

Loading…
Cancel
Save