diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/video_core/regs_pipeline.h | 34 | ||||
| -rw-r--r-- | src/video_core/regs_shader.h | 7 |
2 files changed, 39 insertions, 2 deletions
diff --git a/src/video_core/regs_pipeline.h b/src/video_core/regs_pipeline.h index 8b6369297..e78c3e331 100644 --- a/src/video_core/regs_pipeline.h +++ b/src/video_core/regs_pipeline.h | |||
| @@ -147,7 +147,15 @@ struct PipelineRegs { | |||
| 147 | // Number of vertices to render | 147 | // Number of vertices to render |
| 148 | u32 num_vertices; | 148 | u32 num_vertices; |
| 149 | 149 | ||
| 150 | INSERT_PADDING_WORDS(0x1); | 150 | enum class UseGS : u32 { |
| 151 | No = 0, | ||
| 152 | Yes = 2, | ||
| 153 | }; | ||
| 154 | |||
| 155 | union { | ||
| 156 | BitField<0, 2, UseGS> use_gs; | ||
| 157 | BitField<31, 1, u32> variable_primitive; | ||
| 158 | }; | ||
| 151 | 159 | ||
| 152 | // The index of the first vertex to render | 160 | // The index of the first vertex to render |
| 153 | u32 vertex_offset; | 161 | u32 vertex_offset; |
| @@ -218,7 +226,29 @@ struct PipelineRegs { | |||
| 218 | 226 | ||
| 219 | GPUMode gpu_mode; | 227 | GPUMode gpu_mode; |
| 220 | 228 | ||
| 221 | INSERT_PADDING_WORDS(0x18); | 229 | INSERT_PADDING_WORDS(0x4); |
| 230 | BitField<0, 4, u32> vs_outmap_total_minus_1_a; | ||
| 231 | INSERT_PADDING_WORDS(0x6); | ||
| 232 | BitField<0, 4, u32> vs_outmap_total_minus_1_b; | ||
| 233 | |||
| 234 | enum class GSMode : u32 { | ||
| 235 | Point = 0, | ||
| 236 | VariablePrimitive = 1, | ||
| 237 | FixedPrimitive = 2, | ||
| 238 | }; | ||
| 239 | |||
| 240 | union { | ||
| 241 | BitField<0, 8, GSMode> mode; | ||
| 242 | BitField<8, 4, u32> fixed_vertex_num_minus_1; | ||
| 243 | BitField<12, 4, u32> stride_minus_1; | ||
| 244 | BitField<16, 4, u32> start_index; | ||
| 245 | } gs_config; | ||
| 246 | |||
| 247 | INSERT_PADDING_WORDS(0x1); | ||
| 248 | |||
| 249 | u32 variable_vertex_main_num_minus_1; | ||
| 250 | |||
| 251 | INSERT_PADDING_WORDS(0x9); | ||
| 222 | 252 | ||
| 223 | enum class TriangleTopology : u32 { | 253 | enum class TriangleTopology : u32 { |
| 224 | List = 0, | 254 | List = 0, |
diff --git a/src/video_core/regs_shader.h b/src/video_core/regs_shader.h index ddb1ee451..c15d4d162 100644 --- a/src/video_core/regs_shader.h +++ b/src/video_core/regs_shader.h | |||
| @@ -24,9 +24,16 @@ struct ShaderRegs { | |||
| 24 | 24 | ||
| 25 | INSERT_PADDING_WORDS(0x4); | 25 | INSERT_PADDING_WORDS(0x4); |
| 26 | 26 | ||
| 27 | enum ShaderMode { | ||
| 28 | GS = 0x08, | ||
| 29 | VS = 0xA0, | ||
| 30 | }; | ||
| 31 | |||
| 27 | union { | 32 | union { |
| 28 | // Number of input attributes to shader unit - 1 | 33 | // Number of input attributes to shader unit - 1 |
| 29 | BitField<0, 4, u32> max_input_attribute_index; | 34 | BitField<0, 4, u32> max_input_attribute_index; |
| 35 | BitField<8, 8, u32> input_to_uniform; | ||
| 36 | BitField<24, 8, ShaderMode> shader_mode; | ||
| 30 | }; | 37 | }; |
| 31 | 38 | ||
| 32 | // Offset to shader program entry point (in words) | 39 | // Offset to shader program entry point (in words) |