diff options
author | Fernando Sahmkow <fsahmkow27@gmail.com> | 2019-04-15 18:43:37 +0200 |
---|---|---|
committer | FernandoS27 <fsahmkow27@gmail.com> | 2019-04-15 20:51:36 +0200 |
commit | 8a099ac99f61871f0492864d7e95a5922e57223d (patch) | |
tree | 2e69414c9d5a1b12b7ccc55dcdde27e926f3065f /src/video_core/engines/kepler_memory.h | |
parent | Merge pull request #2378 from lioncash/ro (diff) | |
download | yuzu-8a099ac99f61871f0492864d7e95a5922e57223d.tar yuzu-8a099ac99f61871f0492864d7e95a5922e57223d.tar.gz yuzu-8a099ac99f61871f0492864d7e95a5922e57223d.tar.bz2 yuzu-8a099ac99f61871f0492864d7e95a5922e57223d.tar.lz yuzu-8a099ac99f61871f0492864d7e95a5922e57223d.tar.xz yuzu-8a099ac99f61871f0492864d7e95a5922e57223d.tar.zst yuzu-8a099ac99f61871f0492864d7e95a5922e57223d.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/engines/kepler_memory.h | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/src/video_core/engines/kepler_memory.h b/src/video_core/engines/kepler_memory.h index 78b6c3e45..5f892ddad 100644 --- a/src/video_core/engines/kepler_memory.h +++ b/src/video_core/engines/kepler_memory.h @@ -6,6 +6,7 @@ #include <array> #include <cstddef> +#include <vector> #include "common/bit_field.h" #include "common/common_funcs.h" #include "common/common_types.h" @@ -51,7 +52,11 @@ public: u32 address_high; u32 address_low; u32 pitch; - u32 block_dimensions; + union { + BitField<0, 4, u32> block_width; + BitField<4, 4, u32> block_height; + BitField<8, 4, u32> block_depth; + }; u32 width; u32 height; u32 depth; @@ -63,6 +68,18 @@ public: return static_cast<GPUVAddr>((static_cast<GPUVAddr>(address_high) << 32) | address_low); } + + u32 BlockWidth() const { + return 1U << block_width.Value(); + } + + u32 BlockHeight() const { + return 1U << block_height.Value(); + } + + u32 BlockDepth() const { + return 1U << block_depth.Value(); + } } dest; struct { @@ -81,6 +98,8 @@ public: struct { u32 write_offset = 0; + u32 copy_size = 0; + std::vector<u8> inner_buffer; } state{}; private: @@ -88,7 +107,8 @@ private: VideoCore::RasterizerInterface& rasterizer; MemoryManager& memory_manager; - void ProcessData(u32 data); + void ProcessExec(); + void ProcessData(u32 data, bool is_last_call); }; #define ASSERT_REG_POSITION(field_name, position) \ |