summaryrefslogtreecommitdiff
path: root/src/core/hw/gpu.h
diff options
context:
space:
mode:
authorGravatar Tony Wasserka2014-06-04 18:30:23 +0200
committerGravatar Tony Wasserka2014-07-23 00:33:08 +0200
commitbaf0aa04f50dff257b57fa78786e53b97c1e6abb (patch)
tree3dc92a276f58d1099eb19dd2b5fcb52c69a8da9a /src/core/hw/gpu.h
parentGPU: Add proper framebuffer register handling. (diff)
downloadyuzu-baf0aa04f50dff257b57fa78786e53b97c1e6abb.tar.gz
yuzu-baf0aa04f50dff257b57fa78786e53b97c1e6abb.tar.xz
yuzu-baf0aa04f50dff257b57fa78786e53b97c1e6abb.zip
GPU: Emulate memory fills.
Diffstat (limited to 'src/core/hw/gpu.h')
-rw-r--r--src/core/hw/gpu.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/core/hw/gpu.h b/src/core/hw/gpu.h
index 50c360814..47d7fcb26 100644
--- a/src/core/hw/gpu.h
+++ b/src/core/hw/gpu.h
@@ -14,6 +14,15 @@ static const u32 kFrameTicks = kFrameCycles / 3; ///< Approximate number of i
14 14
15struct Registers { 15struct Registers {
16 enum Id : u32 { 16 enum Id : u32 {
17 MemoryFillStart1 = 0x1EF00010,
18 MemoryFillEnd1 = 0x1EF00014,
19 MemoryFillSize1 = 0x1EF00018,
20 MemoryFillValue1 = 0x1EF0001C,
21 MemoryFillStart2 = 0x1EF00020,
22 MemoryFillEnd2 = 0x1EF00024,
23 MemoryFillSize2 = 0x1EF00028,
24 MemoryFillValue2 = 0x1EF0002C,
25
17 FramebufferTopSize = 0x1EF0045C, 26 FramebufferTopSize = 0x1EF0045C,
18 FramebufferTopLeft1 = 0x1EF00468, // Main LCD, first framebuffer for 3D left 27 FramebufferTopLeft1 = 0x1EF00468, // Main LCD, first framebuffer for 3D left
19 FramebufferTopLeft2 = 0x1EF0046C, // Main LCD, second framebuffer for 3D left 28 FramebufferTopLeft2 = 0x1EF0046C, // Main LCD, second framebuffer for 3D left
@@ -53,6 +62,23 @@ struct Registers {
53 RGBA4 = 4, 62 RGBA4 = 4,
54 }; 63 };
55 64
65 struct MemoryFillConfig {
66 u32 address_start;
67 u32 address_end; // ?
68 u32 size;
69 u32 value; // ?
70
71 inline u32 GetStartAddress() const {
72 return address_start * 8;
73 }
74
75 inline u32 GetEndAddress() const {
76 return address_end * 8;
77 }
78 };
79
80 MemoryFillConfig memory_fill[2];
81
56 // TODO: Move these into the framebuffer struct 82 // TODO: Move these into the framebuffer struct
57 u32 framebuffer_top_left_1; 83 u32 framebuffer_top_left_1;
58 u32 framebuffer_top_left_2; 84 u32 framebuffer_top_left_2;