pineapple/src/yuzu/configuration/configure_graphics.h

65 lines
1.5 KiB
C
Raw Normal View History

2020-12-28 16:15:37 +01:00
// Copyright 2016 Citra Emulator Project
// Licensed under GPLv2 or any later version
// Refer to the license.txt file included.
#pragma once
#include <memory>
#include <vector>
#include <QString>
#include <QWidget>
2021-04-15 04:05:28 +02:00
#include "common/settings.h"
2020-12-28 16:15:37 +01:00
2021-10-09 02:29:53 +02:00
namespace Core {
class System;
}
2020-12-28 16:15:37 +01:00
namespace ConfigurationShared {
enum class CheckState;
}
namespace Ui {
class ConfigureGraphics;
}
class ConfigureGraphics : public QWidget {
Q_OBJECT
public:
2021-10-09 02:29:53 +02:00
explicit ConfigureGraphics(const Core::System& system_, QWidget* parent = nullptr);
2020-12-28 16:15:37 +01:00
~ConfigureGraphics() override;
void ApplyConfiguration();
2021-10-09 02:29:53 +02:00
void SetConfiguration();
2020-12-28 16:15:37 +01:00
private:
void changeEvent(QEvent* event) override;
void RetranslateUI();
void UpdateBackgroundColorButton(QColor color);
2021-07-09 23:54:15 +02:00
void UpdateAPILayout();
2020-12-28 16:15:37 +01:00
void UpdateDeviceSelection(int device);
2021-07-09 23:54:15 +02:00
void UpdateShaderBackendSelection(int backend);
2020-12-28 16:15:37 +01:00
void RetrieveVulkanDevices();
void SetupPerGameUI();
Settings::RendererBackend GetCurrentGraphicsBackend() const;
2021-08-12 01:07:27 +02:00
Settings::NvdecEmulation GetCurrentNvdecEmulation() const;
2020-12-28 16:15:37 +01:00
std::unique_ptr<Ui::ConfigureGraphics> ui;
QColor bg_color;
ConfigurationShared::CheckState use_nvdec_emulation;
2021-06-14 16:57:42 +02:00
ConfigurationShared::CheckState accelerate_astc;
2020-12-28 16:15:37 +01:00
ConfigurationShared::CheckState use_disk_shader_cache;
ConfigurationShared::CheckState use_asynchronous_gpu_emulation;
std::vector<QString> vulkan_devices;
u32 vulkan_device{};
2021-07-09 23:54:15 +02:00
Settings::ShaderBackend shader_backend{};
2021-10-09 02:29:53 +02:00
const Core::System& system;
2020-12-28 16:15:37 +01:00
};