summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/video_core/shader/shader_ir.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/video_core/shader/shader_ir.cpp b/src/video_core/shader/shader_ir.cpp
index 425927777..bc75d400e 100644
--- a/src/video_core/shader/shader_ir.cpp
+++ b/src/video_core/shader/shader_ir.cpp
@@ -106,7 +106,8 @@ Node ShaderIR::GetPhysicalInputAttribute(Tegra::Shader::Register physical_addres
106} 106}
107 107
108Node ShaderIR::GetOutputAttribute(Attribute::Index index, u64 element, Node buffer) { 108Node ShaderIR::GetOutputAttribute(Attribute::Index index, u64 element, Node buffer) {
109 if (index == Attribute::Index::LayerViewportPointSize) { 109 switch (index) {
110 case Attribute::Index::LayerViewportPointSize:
110 switch (element) { 111 switch (element) {
111 case 0: 112 case 0:
112 UNIMPLEMENTED(); 113 UNIMPLEMENTED();
@@ -121,8 +122,8 @@ Node ShaderIR::GetOutputAttribute(Attribute::Index index, u64 element, Node buff
121 uses_point_size = true; 122 uses_point_size = true;
122 break; 123 break;
123 } 124 }
124 } 125 break;
125 if (index == Attribute::Index::TessCoordInstanceIDVertexID) { 126 case Attribute::Index::TessCoordInstanceIDVertexID:
126 switch (element) { 127 switch (element) {
127 case 2: 128 case 2:
128 uses_instance_id = true; 129 uses_instance_id = true;
@@ -130,18 +131,17 @@ Node ShaderIR::GetOutputAttribute(Attribute::Index index, u64 element, Node buff
130 case 3: 131 case 3:
131 uses_vertex_id = true; 132 uses_vertex_id = true;
132 break; 133 break;
133 default:
134 break;
135 } 134 }
136 } 135 break;
137 if (index == Attribute::Index::ClipDistances0123 || 136 case Attribute::Index::ClipDistances0123:
138 index == Attribute::Index::ClipDistances4567) { 137 case Attribute::Index::ClipDistances4567: {
139 const auto clip_index = 138 const auto clip_index =
140 static_cast<u32>((index == Attribute::Index::ClipDistances4567 ? 1 : 0) + element); 139 static_cast<u32>((index == Attribute::Index::ClipDistances4567 ? 1 : 0) + element);
141 used_clip_distances.at(clip_index) = true; 140 used_clip_distances.at(clip_index) = true;
141 break;
142 }
142 } 143 }
143 used_output_attributes.insert(index); 144 used_output_attributes.insert(index);
144
145 return MakeNode<AbufNode>(index, static_cast<u32>(element), std::move(buffer)); 145 return MakeNode<AbufNode>(index, static_cast<u32>(element), std::move(buffer));
146} 146}
147 147