diff options
| author | Fernando Sahmkow <fsahmkow27@gmail.com> | 2019-04-23 12:41:55 -0400 |
|---|---|---|
| committer | FernandoS27 <fsahmkow27@gmail.com> | 2019-04-23 15:28:18 -0400 |
| commit | b3118ee316863e1f4a35548f69bc1194bb740627 (patch) | |
| tree | 59118dae69b2e490b7b7856af8ae954d9cae9891 /src/video_core/engines/maxwell_dma.h | |
| parent | f1e5314f1a57b09bd45e0db3ca91449e761c431a (diff) | |
Fixes and Corrections to DMA Engine
Diffstat (limited to 'src/video_core/engines/maxwell_dma.h')
| -rw-r--r-- | src/video_core/engines/maxwell_dma.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/video_core/engines/maxwell_dma.h b/src/video_core/engines/maxwell_dma.h index 0b2e26199..8eab1332e 100644 --- a/src/video_core/engines/maxwell_dma.h +++ b/src/video_core/engines/maxwell_dma.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" @@ -155,6 +156,13 @@ public: BitField<16, 2, u32> component_size; BitField<20, 3, u32> src_num_components; BitField<24, 3, u32> dst_num_components; + + u32 SrcBytePerPixel() const { + return src_num_components.Value() * component_size.Value(); + } + u32 DstBytePerPixel() const { + return dst_num_components.Value() * component_size.Value(); + } } swizzle_config; Parameters dst_params; @@ -176,6 +184,9 @@ private: MemoryManager& memory_manager; + std::vector<u8> read_buffer; + std::vector<u8> write_buffer; + /// Performs the copy from the source buffer to the destination buffer as configured in the /// registers. void HandleCopy(); |
