diff options
| author | 2015-05-09 03:08:11 -0300 | |
|---|---|---|
| committer | 2015-05-09 03:08:11 -0300 | |
| commit | 28a9e4c1d55c66e99b5cf16fda00dcb75ab27fde (patch) | |
| tree | 9c40b519bff8a84c948b9343367763781cb64454 /src/citra_qt/debugger | |
| parent | Memory: Sort memory region variables by VAddr (diff) | |
| download | yuzu-28a9e4c1d55c66e99b5cf16fda00dcb75ab27fde.tar.gz yuzu-28a9e4c1d55c66e99b5cf16fda00dcb75ab27fde.tar.xz yuzu-28a9e4c1d55c66e99b5cf16fda00dcb75ab27fde.zip | |
Memory: Support more regions in the VAddr-PAddr translation functions
Also adds better documentation and removes the one-off reimplementation
of the function in pica.h.
Diffstat (limited to 'src/citra_qt/debugger')
| -rw-r--r-- | src/citra_qt/debugger/graphics_cmdlists.cpp | 4 | ||||
| -rw-r--r-- | src/citra_qt/debugger/graphics_framebuffer.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/citra_qt/debugger/graphics_cmdlists.cpp b/src/citra_qt/debugger/graphics_cmdlists.cpp index 9bcd25821..6727acf18 100644 --- a/src/citra_qt/debugger/graphics_cmdlists.cpp +++ b/src/citra_qt/debugger/graphics_cmdlists.cpp | |||
| @@ -159,7 +159,7 @@ void TextureInfoDockWidget::OnStrideChanged(int value) { | |||
| 159 | } | 159 | } |
| 160 | 160 | ||
| 161 | QPixmap TextureInfoDockWidget::ReloadPixmap() const { | 161 | QPixmap TextureInfoDockWidget::ReloadPixmap() const { |
| 162 | u8* src = Memory::GetPointer(Pica::PAddrToVAddr(info.physical_address)); | 162 | u8* src = Memory::GetPointer(Memory::PhysicalToVirtualAddress(info.physical_address)); |
| 163 | return QPixmap::fromImage(LoadTexture(src, info)); | 163 | return QPixmap::fromImage(LoadTexture(src, info)); |
| 164 | } | 164 | } |
| 165 | 165 | ||
| @@ -274,7 +274,7 @@ void GPUCommandListWidget::SetCommandInfo(const QModelIndex& index) { | |||
| 274 | auto format = Pica::registers.GetTextures()[index].format; | 274 | auto format = Pica::registers.GetTextures()[index].format; |
| 275 | 275 | ||
| 276 | auto info = Pica::DebugUtils::TextureInfo::FromPicaRegister(config, format); | 276 | auto info = Pica::DebugUtils::TextureInfo::FromPicaRegister(config, format); |
| 277 | u8* src = Memory::GetPointer(Pica::PAddrToVAddr(config.GetPhysicalAddress())); | 277 | u8* src = Memory::GetPointer(Memory::PhysicalToVirtualAddress(config.GetPhysicalAddress())); |
| 278 | new_info_widget = new TextureInfoWidget(src, info); | 278 | new_info_widget = new TextureInfoWidget(src, info); |
| 279 | } else { | 279 | } else { |
| 280 | new_info_widget = new QWidget; | 280 | new_info_widget = new QWidget; |
diff --git a/src/citra_qt/debugger/graphics_framebuffer.cpp b/src/citra_qt/debugger/graphics_framebuffer.cpp index d621d7204..fa101a6a2 100644 --- a/src/citra_qt/debugger/graphics_framebuffer.cpp +++ b/src/citra_qt/debugger/graphics_framebuffer.cpp | |||
| @@ -215,7 +215,7 @@ void GraphicsFramebufferWidget::OnUpdate() | |||
| 215 | u32 bytes_per_pixel = GraphicsFramebufferWidget::BytesPerPixel(framebuffer_format); | 215 | u32 bytes_per_pixel = GraphicsFramebufferWidget::BytesPerPixel(framebuffer_format); |
| 216 | 216 | ||
| 217 | QImage decoded_image(framebuffer_width, framebuffer_height, QImage::Format_ARGB32); | 217 | QImage decoded_image(framebuffer_width, framebuffer_height, QImage::Format_ARGB32); |
| 218 | u8* buffer = Memory::GetPointer(Pica::PAddrToVAddr(framebuffer_address)); | 218 | u8* buffer = Memory::GetPointer(Memory::PhysicalToVirtualAddress(framebuffer_address)); |
| 219 | 219 | ||
| 220 | for (unsigned int y = 0; y < framebuffer_height; ++y) { | 220 | for (unsigned int y = 0; y < framebuffer_height; ++y) { |
| 221 | for (unsigned int x = 0; x < framebuffer_width; ++x) { | 221 | for (unsigned int x = 0; x < framebuffer_width; ++x) { |