diff options
| author | 2020-03-13 10:08:57 -0400 | |
|---|---|---|
| committer | 2020-03-13 10:08:57 -0400 | |
| commit | b30b1f741dcbcb69672d065b0bec4f4a9e5f0993 (patch) | |
| tree | b8416dffe6beb924c574ef25755aad12db0a68fb /src/video_core/engines | |
| parent | Merge pull request #3483 from namkazt/patch-1 (diff) | |
| parent | gl_rasterizer: Implement polygon modes and fill rectangles (diff) | |
| download | yuzu-b30b1f741dcbcb69672d065b0bec4f4a9e5f0993.tar.gz yuzu-b30b1f741dcbcb69672d065b0bec4f4a9e5f0993.tar.xz yuzu-b30b1f741dcbcb69672d065b0bec4f4a9e5f0993.zip | |
Merge pull request #3491 from ReinUsesLisp/polygon-modes
gl_rasterizer: Implement polygon modes and fill rectangles
Diffstat (limited to 'src/video_core/engines')
| -rw-r--r-- | src/video_core/engines/maxwell_3d.h | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/src/video_core/engines/maxwell_3d.h b/src/video_core/engines/maxwell_3d.h index 491cff370..ed7fc8fdd 100644 --- a/src/video_core/engines/maxwell_3d.h +++ b/src/video_core/engines/maxwell_3d.h | |||
| @@ -524,6 +524,12 @@ public: | |||
| 524 | FractionalEven = 2, | 524 | FractionalEven = 2, |
| 525 | }; | 525 | }; |
| 526 | 526 | ||
| 527 | enum class PolygonMode : u32 { | ||
| 528 | Point = 0x1b00, | ||
| 529 | Line = 0x1b01, | ||
| 530 | Fill = 0x1b02, | ||
| 531 | }; | ||
| 532 | |||
| 527 | struct RenderTargetConfig { | 533 | struct RenderTargetConfig { |
| 528 | u32 address_high; | 534 | u32 address_high; |
| 529 | u32 address_low; | 535 | u32 address_low; |
| @@ -705,7 +711,12 @@ public: | |||
| 705 | 711 | ||
| 706 | s32 clear_stencil; | 712 | s32 clear_stencil; |
| 707 | 713 | ||
| 708 | INSERT_UNION_PADDING_WORDS(0x7); | 714 | INSERT_UNION_PADDING_WORDS(0x2); |
| 715 | |||
| 716 | PolygonMode polygon_mode_front; | ||
| 717 | PolygonMode polygon_mode_back; | ||
| 718 | |||
| 719 | INSERT_UNION_PADDING_WORDS(0x3); | ||
| 709 | 720 | ||
| 710 | u32 polygon_offset_point_enable; | 721 | u32 polygon_offset_point_enable; |
| 711 | u32 polygon_offset_line_enable; | 722 | u32 polygon_offset_line_enable; |
| @@ -764,7 +775,11 @@ public: | |||
| 764 | BitField<12, 4, u32> viewport; | 775 | BitField<12, 4, u32> viewport; |
| 765 | } clear_flags; | 776 | } clear_flags; |
| 766 | 777 | ||
| 767 | INSERT_UNION_PADDING_WORDS(0x19); | 778 | INSERT_UNION_PADDING_WORDS(0x10); |
| 779 | |||
| 780 | u32 fill_rectangle; | ||
| 781 | |||
| 782 | INSERT_UNION_PADDING_WORDS(0x8); | ||
| 768 | 783 | ||
| 769 | std::array<VertexAttribute, NumVertexAttributes> vertex_attrib_format; | 784 | std::array<VertexAttribute, NumVertexAttributes> vertex_attrib_format; |
| 770 | 785 | ||
| @@ -1422,6 +1437,8 @@ ASSERT_REG_POSITION(depth_mode, 0x35F); | |||
| 1422 | ASSERT_REG_POSITION(clear_color[0], 0x360); | 1437 | ASSERT_REG_POSITION(clear_color[0], 0x360); |
| 1423 | ASSERT_REG_POSITION(clear_depth, 0x364); | 1438 | ASSERT_REG_POSITION(clear_depth, 0x364); |
| 1424 | ASSERT_REG_POSITION(clear_stencil, 0x368); | 1439 | ASSERT_REG_POSITION(clear_stencil, 0x368); |
| 1440 | ASSERT_REG_POSITION(polygon_mode_front, 0x36B); | ||
| 1441 | ASSERT_REG_POSITION(polygon_mode_back, 0x36C); | ||
| 1425 | ASSERT_REG_POSITION(polygon_offset_point_enable, 0x370); | 1442 | ASSERT_REG_POSITION(polygon_offset_point_enable, 0x370); |
| 1426 | ASSERT_REG_POSITION(polygon_offset_line_enable, 0x371); | 1443 | ASSERT_REG_POSITION(polygon_offset_line_enable, 0x371); |
| 1427 | ASSERT_REG_POSITION(polygon_offset_fill_enable, 0x372); | 1444 | ASSERT_REG_POSITION(polygon_offset_fill_enable, 0x372); |
| @@ -1435,6 +1452,7 @@ ASSERT_REG_POSITION(rt_separate_frag_data, 0x3EB); | |||
| 1435 | ASSERT_REG_POSITION(depth_bounds, 0x3E7); | 1452 | ASSERT_REG_POSITION(depth_bounds, 0x3E7); |
| 1436 | ASSERT_REG_POSITION(zeta, 0x3F8); | 1453 | ASSERT_REG_POSITION(zeta, 0x3F8); |
| 1437 | ASSERT_REG_POSITION(clear_flags, 0x43E); | 1454 | ASSERT_REG_POSITION(clear_flags, 0x43E); |
| 1455 | ASSERT_REG_POSITION(fill_rectangle, 0x44F); | ||
| 1438 | ASSERT_REG_POSITION(vertex_attrib_format, 0x458); | 1456 | ASSERT_REG_POSITION(vertex_attrib_format, 0x458); |
| 1439 | ASSERT_REG_POSITION(rt_control, 0x487); | 1457 | ASSERT_REG_POSITION(rt_control, 0x487); |
| 1440 | ASSERT_REG_POSITION(zeta_width, 0x48a); | 1458 | ASSERT_REG_POSITION(zeta_width, 0x48a); |