summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2016-12-11 01:33:40 +0100
committerLioncash <mathew1800@gmail.com>2016-12-11 02:01:22 +0100
commitf1ee7e4e0e87d743748f9a8d157fc83a8b38cddc (patch)
treef659ce8578377ec21c838aeb9539a3502fe530b6 /src
parentgraphics_cmdlists: Make LoadImage internally linked (diff)
downloadyuzu-f1ee7e4e0e87d743748f9a8d157fc83a8b38cddc.tar
yuzu-f1ee7e4e0e87d743748f9a8d157fc83a8b38cddc.tar.gz
yuzu-f1ee7e4e0e87d743748f9a8d157fc83a8b38cddc.tar.bz2
yuzu-f1ee7e4e0e87d743748f9a8d157fc83a8b38cddc.tar.lz
yuzu-f1ee7e4e0e87d743748f9a8d157fc83a8b38cddc.tar.xz
yuzu-f1ee7e4e0e87d743748f9a8d157fc83a8b38cddc.tar.zst
yuzu-f1ee7e4e0e87d743748f9a8d157fc83a8b38cddc.zip
Diffstat (limited to 'src')
-rw-r--r--src/citra_qt/debugger/graphics_cmdlists.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/citra_qt/debugger/graphics_cmdlists.cpp b/src/citra_qt/debugger/graphics_cmdlists.cpp
index cc49b471a..dde95a219 100644
--- a/src/citra_qt/debugger/graphics_cmdlists.cpp
+++ b/src/citra_qt/debugger/graphics_cmdlists.cpp
@@ -22,7 +22,7 @@
#include "video_core/pica_state.h"
namespace {
-QImage LoadTexture(u8* src, const Pica::DebugUtils::TextureInfo& info) {
+QImage LoadTexture(const u8* src, const Pica::DebugUtils::TextureInfo& info) {
QImage decoded_image(info.width, info.height, QImage::Format_ARGB32);
for (int y = 0; y < info.height; ++y) {
for (int x = 0; x < info.width; ++x) {
@@ -36,7 +36,8 @@ QImage LoadTexture(u8* src, const Pica::DebugUtils::TextureInfo& info) {
class TextureInfoWidget : public QWidget {
public:
- TextureInfoWidget(u8* src, const Pica::DebugUtils::TextureInfo& info, QWidget* parent = nullptr)
+ TextureInfoWidget(const u8* src, const Pica::DebugUtils::TextureInfo& info,
+ QWidget* parent = nullptr)
: QWidget(parent) {
QLabel* image_widget = new QLabel;
QPixmap image_pixmap = QPixmap::fromImage(LoadTexture(src, info));
@@ -162,7 +163,7 @@ void GPUCommandListWidget::SetCommandInfo(const QModelIndex& index) {
auto format = Pica::g_state.regs.GetTextures()[index].format;
auto info = Pica::DebugUtils::TextureInfo::FromPicaRegister(config, format);
- u8* src = Memory::GetPhysicalPointer(config.GetPhysicalAddress());
+ const u8* src = Memory::GetPhysicalPointer(config.GetPhysicalAddress());
new_info_widget = new TextureInfoWidget(src, info);
}
if (command_info_widget) {