Core: Purge WITH_IMGUI define
This commit is contained in:
parent
d5128a5ea9
commit
fd76f437b3
|
@ -118,7 +118,6 @@ target_include_directories(core PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/..")
|
|||
target_include_directories(core PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/..")
|
||||
target_link_libraries(core PUBLIC Threads::Threads common zlib vulkan-loader)
|
||||
target_link_libraries(core PRIVATE glad stb xxhash imgui)
|
||||
target_compile_definitions(core PUBLIC "-DWITH_IMGUI=1")
|
||||
|
||||
if(WIN32)
|
||||
target_sources(core PRIVATE
|
||||
|
|
|
@ -5,14 +5,12 @@
|
|||
#include "common/platform.h"
|
||||
#include "common/state_wrapper.h"
|
||||
#include "dma.h"
|
||||
#include "imgui.h"
|
||||
#include "interrupt_controller.h"
|
||||
#include "settings.h"
|
||||
#include "spu.h"
|
||||
#include "system.h"
|
||||
#include <cmath>
|
||||
#ifdef WITH_IMGUI
|
||||
#include "imgui.h"
|
||||
#endif
|
||||
Log_SetChannel(CDROM);
|
||||
|
||||
#if defined(CPU_X64)
|
||||
|
@ -2722,7 +2720,6 @@ void CDROM::ClearSectorBuffers()
|
|||
|
||||
void CDROM::DrawDebugWindow()
|
||||
{
|
||||
#ifdef WITH_IMGUI
|
||||
static const ImVec4 active_color{1.0f, 1.0f, 1.0f, 1.0f};
|
||||
static const ImVec4 inactive_color{0.4f, 0.4f, 0.4f, 1.0f};
|
||||
const float framebuffer_scale = ImGui::GetIO().DisplayFramebufferScale.x;
|
||||
|
@ -2919,5 +2916,4 @@ void CDROM::DrawDebugWindow()
|
|||
}
|
||||
|
||||
ImGui::End();
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -4,7 +4,6 @@
|
|||
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<PreprocessorDefinitions>WITH_IMGUI=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions Condition="'$(Platform)'=='x64' Or '$(Platform)'=='ARM' Or '$(Platform)'=='ARM64'">WITH_RECOMPILER=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions Condition="('$(Platform)'=='x64' Or '$(Platform)'=='ARM64') And ('$(BuildingForUWP)'!='true')">WITH_MMAP_FASTMEM=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
||||
|
|
|
@ -7,14 +7,12 @@
|
|||
#include "cpu_code_cache.h"
|
||||
#include "cpu_core.h"
|
||||
#include "gpu.h"
|
||||
#include "imgui.h"
|
||||
#include "interrupt_controller.h"
|
||||
#include "mdec.h"
|
||||
#include "pad.h"
|
||||
#include "spu.h"
|
||||
#include "system.h"
|
||||
#ifdef WITH_IMGUI
|
||||
#include "imgui.h"
|
||||
#endif
|
||||
Log_SetChannel(DMA);
|
||||
|
||||
static u32 GetAddressMask()
|
||||
|
@ -621,7 +619,6 @@ TickCount DMA::TransferDeviceToMemory(Channel channel, u32 address, u32 incremen
|
|||
|
||||
void DMA::DrawDebugStateWindow()
|
||||
{
|
||||
#ifdef WITH_IMGUI
|
||||
static constexpr u32 NUM_COLUMNS = 10;
|
||||
static constexpr std::array<const char*, NUM_COLUMNS> column_names = {
|
||||
{"#", "Req", "Direction", "Chopping", "Mode", "Busy", "Enable", "Priority", "IRQ", "Flag"}};
|
||||
|
@ -697,5 +694,4 @@ void DMA::DrawDebugStateWindow()
|
|||
|
||||
ImGui::Columns(1);
|
||||
ImGui::End();
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -7,15 +7,13 @@
|
|||
#include "dma.h"
|
||||
#include "host_display.h"
|
||||
#include "host_interface.h"
|
||||
#include "imgui.h"
|
||||
#include "interrupt_controller.h"
|
||||
#include "settings.h"
|
||||
#include "stb_image_write.h"
|
||||
#include "system.h"
|
||||
#include "timers.h"
|
||||
#include <cmath>
|
||||
#ifdef WITH_IMGUI
|
||||
#include "imgui.h"
|
||||
#endif
|
||||
Log_SetChannel(GPU);
|
||||
|
||||
std::unique_ptr<GPU> g_gpu;
|
||||
|
@ -1553,7 +1551,6 @@ bool GPU::DumpVRAMToFile(const char* filename, u32 width, u32 height, u32 stride
|
|||
|
||||
void GPU::DrawDebugStateWindow()
|
||||
{
|
||||
#ifdef WITH_IMGUI
|
||||
const float framebuffer_scale = ImGui::GetIO().DisplayFramebufferScale.x;
|
||||
|
||||
ImGui::SetNextWindowSize(ImVec2(450.0f * framebuffer_scale, 550.0f * framebuffer_scale), ImGuiCond_FirstUseEver);
|
||||
|
@ -1671,7 +1668,6 @@ void GPU::DrawDebugStateWindow()
|
|||
}
|
||||
|
||||
ImGui::End();
|
||||
#endif
|
||||
}
|
||||
|
||||
void GPU::DrawRendererStats(bool is_idle_frame) {}
|
||||
|
|
|
@ -5,15 +5,13 @@
|
|||
#include "common/state_wrapper.h"
|
||||
#include "cpu_core.h"
|
||||
#include "gpu_sw_backend.h"
|
||||
#include "imgui.h"
|
||||
#include "pgxp.h"
|
||||
#include "settings.h"
|
||||
#include "system.h"
|
||||
#include <cmath>
|
||||
#include <sstream>
|
||||
#include <tuple>
|
||||
#ifdef WITH_IMGUI
|
||||
#include "imgui.h"
|
||||
#endif
|
||||
Log_SetChannel(GPU_HW);
|
||||
|
||||
template<typename T>
|
||||
|
@ -1403,7 +1401,6 @@ void GPU_HW::DrawRendererStats(bool is_idle_frame)
|
|||
m_renderer_stats = {};
|
||||
}
|
||||
|
||||
#ifdef WITH_IMGUI
|
||||
if (ImGui::CollapsingHeader("Renderer Statistics", ImGuiTreeNodeFlags_DefaultOpen))
|
||||
{
|
||||
static const ImVec4 active_color{1.0f, 1.0f, 1.0f, 1.0f};
|
||||
|
@ -1472,7 +1469,6 @@ void GPU_HW::DrawRendererStats(bool is_idle_frame)
|
|||
|
||||
ImGui::Columns(1);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
GPU_HW::ShaderCompileProgressTracker::ShaderCompileProgressTracker(std::string title, u32 total)
|
||||
|
|
|
@ -123,12 +123,10 @@ public:
|
|||
|
||||
virtual void SetVSync(bool enabled) = 0;
|
||||
|
||||
#ifdef WITH_IMGUI
|
||||
/// ImGui context management, usually called by derived classes.
|
||||
virtual bool CreateImGuiContext() = 0;
|
||||
virtual void DestroyImGuiContext() = 0;
|
||||
virtual bool UpdateImGuiFontTexture() = 0;
|
||||
#endif
|
||||
|
||||
const void* GetDisplayTextureHandle() const { return m_display_texture_handle; }
|
||||
const s32 GetDisplayTopMargin() const { return m_display_top_margin; }
|
||||
|
|
|
@ -3,11 +3,9 @@
|
|||
#include "common/state_wrapper.h"
|
||||
#include "cpu_core.h"
|
||||
#include "dma.h"
|
||||
#include "imgui.h"
|
||||
#include "interrupt_controller.h"
|
||||
#include "system.h"
|
||||
#ifdef WITH_IMGUI
|
||||
#include "imgui.h"
|
||||
#endif
|
||||
Log_SetChannel(MDEC);
|
||||
|
||||
MDEC g_mdec;
|
||||
|
@ -724,7 +722,6 @@ void MDEC::HandleSetScaleCommand()
|
|||
|
||||
void MDEC::DrawDebugStateWindow()
|
||||
{
|
||||
#ifdef WITH_IMGUI
|
||||
const float framebuffer_scale = ImGui::GetIO().DisplayFramebufferScale.x;
|
||||
|
||||
ImGui::SetNextWindowSize(ImVec2(300.0f * framebuffer_scale, 350.0f * framebuffer_scale), ImGuiCond_FirstUseEver);
|
||||
|
@ -762,5 +759,4 @@ void MDEC::DrawDebugStateWindow()
|
|||
}
|
||||
|
||||
ImGui::End();
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -7,11 +7,9 @@
|
|||
#include "common/wav_writer.h"
|
||||
#include "dma.h"
|
||||
#include "host_interface.h"
|
||||
#include "imgui.h"
|
||||
#include "interrupt_controller.h"
|
||||
#include "system.h"
|
||||
#ifdef WITH_IMGUI
|
||||
#include "imgui.h"
|
||||
#endif
|
||||
Log_SetChannel(SPU);
|
||||
|
||||
SPU g_spu;
|
||||
|
@ -1921,7 +1919,6 @@ void SPU::UpdateEventInterval()
|
|||
|
||||
void SPU::DrawDebugStateWindow()
|
||||
{
|
||||
#ifdef WITH_IMGUI
|
||||
static const ImVec4 active_color{1.0f, 1.0f, 1.0f, 1.0f};
|
||||
static const ImVec4 inactive_color{0.4f, 0.4f, 0.4f, 1.0f};
|
||||
const float framebuffer_scale = ImGui::GetIO().DisplayFramebufferScale.x;
|
||||
|
@ -2102,5 +2099,4 @@ void SPU::DrawDebugStateWindow()
|
|||
}
|
||||
|
||||
ImGui::End();
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -2,11 +2,9 @@
|
|||
#include "common/log.h"
|
||||
#include "common/state_wrapper.h"
|
||||
#include "gpu.h"
|
||||
#include "imgui.h"
|
||||
#include "interrupt_controller.h"
|
||||
#include "system.h"
|
||||
#ifdef WITH_IMGUI
|
||||
#include "imgui.h"
|
||||
#endif
|
||||
Log_SetChannel(Timers);
|
||||
|
||||
Timers g_timers;
|
||||
|
@ -394,7 +392,6 @@ void Timers::UpdateSysClkEvent()
|
|||
|
||||
void Timers::DrawDebugStateWindow()
|
||||
{
|
||||
#ifdef WITH_IMGUI
|
||||
static constexpr u32 NUM_COLUMNS = 10;
|
||||
static constexpr std::array<const char*, NUM_COLUMNS> column_names = {
|
||||
{"#", "Value", "Target", "Sync", "Reset", "IRQ", "IRQRepeat", "IRQToggle", "Clock Source", "Reached"}};
|
||||
|
@ -463,5 +460,4 @@ void Timers::DrawDebugStateWindow()
|
|||
|
||||
ImGui::Columns(1);
|
||||
ImGui::End();
|
||||
#endif
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue