diff --git a/README.md b/README.md index a0b98537f..595aa0209 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ __Mac OSX__ To initialize the repository don't forget to execute `git submodule update --init` to pull the wxWidgets source. * __Windows__: -Open the *.SLN* file, and press *Build* > *Rebuild Solution*. +Open the *.SLN* file, and press *Build* > *Clean Solution*, then *Build Solution*. *Rebuild* may not work correctly. * __Linux & Mac OSX__: If you want to build with LLVM, then LLVM 3.6.2 is required. `cd rpcs3 && cmake CMakeLists.txt && make && cd ../` then run with `cd bin && ./rpcs3`. diff --git a/rpcs3.sln b/rpcs3.sln index fdf33f694..e23087503 100644 --- a/rpcs3.sln +++ b/rpcs3.sln @@ -1,6 +1,6 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 14 -VisualStudioVersion = 14.0.23107.0 +VisualStudioVersion = 14.0.24720.0 MinimumVisualStudioVersion = 10.0.40219.1 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "rpcs3", "rpcs3\rpcs3.vcxproj", "{70CD65B0-91D6-4FAE-9A7B-4AF55D0D1B12}" ProjectSection(ProjectDependencies) = postProject @@ -594,18 +594,18 @@ Global {00D36322-6188-4A66-B514-3B3F183E998D}.Release - LLVM|x64.Build.0 = Release|x64 {00D36322-6188-4A66-B514-3B3F183E998D}.Release|x64.ActiveCfg = Release|x64 {00D36322-6188-4A66-B514-3B3F183E998D}.Release|x64.Build.0 = Release|x64 - {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug - LLVM|x64.ActiveCfg = Debug|x64 - {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug - LLVM|x64.Build.0 = Debug|x64 - {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug - MemLeak|x64.ActiveCfg = Debug|x64 - {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug - MemLeak|x64.Build.0 = Debug|x64 + {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug - LLVM|x64.ActiveCfg = Debug - LLVM|x64 + {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug - LLVM|x64.Build.0 = Debug - LLVM|x64 + {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug - MemLeak|x64.ActiveCfg = Debug - MemLeak|x64 + {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug - MemLeak|x64.Build.0 = Debug - MemLeak|x64 {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug|x64.ActiveCfg = Debug|x64 {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Debug|x64.Build.0 = Debug|x64 {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.DLL Debug|x64.ActiveCfg = Debug|x64 {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.DLL Debug|x64.Build.0 = Debug|x64 {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.DLL Release|x64.ActiveCfg = Release|x64 {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.DLL Release|x64.Build.0 = Release|x64 - {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Release - LLVM|x64.ActiveCfg = Release|x64 - {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Release - LLVM|x64.Build.0 = Release|x64 + {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Release - LLVM|x64.ActiveCfg = Release - LLVM|x64 + {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Release - LLVM|x64.Build.0 = Release - LLVM|x64 {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Release|x64.ActiveCfg = Release|x64 {FAC9B17B-F4B8-4B75-8AEB-C8C7CB92B078}.Release|x64.Build.0 = Release|x64 {AB222E8A-00CA-4ACF-A87E-5251C16C0587}.Debug - LLVM|x64.ActiveCfg = Debug|x64 diff --git a/rpcs3/D3D12GSRender.vcxproj b/rpcs3/D3D12GSRender.vcxproj index cf6f0ab07..df5813dd6 100644 --- a/rpcs3/D3D12GSRender.vcxproj +++ b/rpcs3/D3D12GSRender.vcxproj @@ -1,10 +1,22 @@  + + Debug - LLVM + x64 + + + Debug - MemLeak + x64 + Debug x64 + + Release - LLVM + x64 + Release x64 @@ -22,11 +34,30 @@ v140 Unicode + + StaticLibrary + true + v140 + Unicode + + + StaticLibrary + true + v140 + Unicode + StaticLibrary false v140 - true + false + Unicode + + + StaticLibrary + false + v140 + false Unicode @@ -37,24 +68,82 @@ + + + + + + + + + $(VC_IncludePath);$(WindowsSDK_IncludePath);..\minidx12\Include;$(IncludePath) + + $(VC_IncludePath);$(WindowsSDK_IncludePath);..\minidx12\Include;$(IncludePath) + + + $(VC_IncludePath);$(WindowsSDK_IncludePath);..\minidx12\Include;$(IncludePath) + $(VC_IncludePath);$(WindowsSDK_IncludePath);..\minidx12\Include;$(IncludePath) + + $(VC_IncludePath);$(WindowsSDK_IncludePath);..\minidx12\Include;$(IncludePath) + Level3 Disabled false Use - stdafx_d3d12.h + stdafx.h .;.. + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb + true + Async + + + true + + + + + Level3 + Disabled + false + Use + stdafx.h + .;.. + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb + true + Async + _UNICODE;UNICODE;MSVC_CRT_MEMLEAK_DETECTION;%(PreprocessorDefinitions) + + + true + + + + + Level3 + Disabled + false + Use + stdafx.h + .;.. + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb + true + Async + _UNICODE;UNICODE;LLVM_AVAILABLE;%(PreprocessorDefinitions) true @@ -66,10 +155,36 @@ MaxSpeed true true - true + false Use - stdafx_d3d12.h + stdafx.h .;.. + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb + true + Async + + + true + true + true + + + + + Level3 + MaxSpeed + true + true + false + Use + stdafx.h + .;.. + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb + true + Async + _UNICODE;UNICODE;LLVM_AVAILABLE;%(PreprocessorDefinitions) true @@ -103,10 +218,11 @@ - - Create - Create - + + + + {c4a10229-4712-4bd2-b63e-50d93c67a038} + diff --git a/rpcs3/D3D12GSRender.vcxproj.filters b/rpcs3/D3D12GSRender.vcxproj.filters index 8a8005996..52d361d92 100644 --- a/rpcs3/D3D12GSRender.vcxproj.filters +++ b/rpcs3/D3D12GSRender.vcxproj.filters @@ -73,9 +73,6 @@ Source Files - - Source Files - Source Files diff --git a/rpcs3/Emu/Cell/PPUProgramCompiler.cpp b/rpcs3/Emu/Cell/PPUProgramCompiler.cpp index caa6f624b..c4c6d7381 100644 --- a/rpcs3/Emu/Cell/PPUProgramCompiler.cpp +++ b/rpcs3/Emu/Cell/PPUProgramCompiler.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "PPUProgramCompiler.h" #include "Utilities/File.h" diff --git a/rpcs3/Emu/Io/XInput/XInputPadHandler.cpp b/rpcs3/Emu/Io/XInput/XInputPadHandler.cpp index 8a8f6c994..5823f7136 100644 --- a/rpcs3/Emu/Io/XInput/XInputPadHandler.cpp +++ b/rpcs3/Emu/Io/XInput/XInputPadHandler.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #ifdef _MSC_VER #include "Utilities/Log.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12Buffer.cpp b/rpcs3/Emu/RSX/D3D12/D3D12Buffer.cpp index 52da134c0..bb02d2783 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12Buffer.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12Buffer.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "Utilities/Log.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12CommonDecompiler.cpp b/rpcs3/Emu/RSX/D3D12/D3D12CommonDecompiler.cpp index cbf1224c8..de1ff130a 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12CommonDecompiler.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12CommonDecompiler.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12CommonDecompiler.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12Formats.cpp b/rpcs3/Emu/RSX/D3D12/D3D12Formats.cpp index 22996bdaf..e20c4943a 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12Formats.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12Formats.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12Formats.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12FragmentProgramDecompiler.cpp b/rpcs3/Emu/RSX/D3D12/D3D12FragmentProgramDecompiler.cpp index 776b3aa38..ef46afafc 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12FragmentProgramDecompiler.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12FragmentProgramDecompiler.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12FragmentProgramDecompiler.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12GSRender.cpp b/rpcs3/Emu/RSX/D3D12/D3D12GSRender.cpp index 35eb941b5..359656825 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12GSRender.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12GSRender.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12GSRender.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12MemoryHelpers.cpp b/rpcs3/Emu/RSX/D3D12/D3D12MemoryHelpers.cpp index 985417e13..abcd84ad9 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12MemoryHelpers.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12MemoryHelpers.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12MemoryHelpers.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12Overlay.cpp b/rpcs3/Emu/RSX/D3D12/D3D12Overlay.cpp index 17e062807..0d90ddfc6 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12Overlay.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12Overlay.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12GSRender.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12PipelineState.cpp b/rpcs3/Emu/RSX/D3D12/D3D12PipelineState.cpp index 360c8abba..45f7e9792 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12PipelineState.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12PipelineState.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12PipelineState.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12RenderTargetSets.cpp b/rpcs3/Emu/RSX/D3D12/D3D12RenderTargetSets.cpp index 8636c5dca..fdea7f00d 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12RenderTargetSets.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12RenderTargetSets.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12RenderTargetSets.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12Texture.cpp b/rpcs3/Emu/RSX/D3D12/D3D12Texture.cpp index aec4da6d4..ab3d4c1ec 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12Texture.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12Texture.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12GSRender.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12Utils.cpp b/rpcs3/Emu/RSX/D3D12/D3D12Utils.cpp index 84f2380e6..6c77a9b8c 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12Utils.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12Utils.cpp @@ -1,6 +1,4 @@ -/** -* Contains utility shaders -*/ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12GSRender.h" diff --git a/rpcs3/Emu/RSX/D3D12/D3D12VertexProgramDecompiler.cpp b/rpcs3/Emu/RSX/D3D12/D3D12VertexProgramDecompiler.cpp index d603cc9c7..238cd12b8 100644 --- a/rpcs3/Emu/RSX/D3D12/D3D12VertexProgramDecompiler.cpp +++ b/rpcs3/Emu/RSX/D3D12/D3D12VertexProgramDecompiler.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_d3d12.h" #ifdef _MSC_VER #include "D3D12VertexProgramDecompiler.h" diff --git a/rpcs3/Emu/RSX/GSManager.cpp b/rpcs3/Emu/RSX/GSManager.cpp index dd9002bf8..044ef34aa 100644 --- a/rpcs3/Emu/RSX/GSManager.cpp +++ b/rpcs3/Emu/RSX/GSManager.cpp @@ -1,15 +1,11 @@ #include "stdafx.h" #include "Utilities/Log.h" +#include "Emu/System.h" #include "Emu/Memory/Memory.h" #include "Emu/SysCalls/Modules/cellVideoOut.h" #include "Emu/state.h" #include "GSManager.h" -#include "Null/NullGSRender.h" -#include "GL/GLGSRender.h" -#ifdef _MSC_VER -#include "Emu/RSX/D3D12/D3D12GSRender.h" -#endif void GSInfo::Init() { @@ -28,15 +24,7 @@ void GSManager::Init() m_info.Init(); - switch (rpcs3::state.config.rsx.renderer.value()) - { - default: - case rsx_renderer_type::Null : m_render = std::make_shared(); break; - case rsx_renderer_type::OpenGL: m_render = std::make_shared(); break; -#ifdef _MSC_VER - case rsx_renderer_type::DX12: m_render = std::make_shared(); break; -#endif - } + m_render = Emu.GetCallbacks().get_gs_render(); //m_render->Init(GetInfo().outresolution.width, GetInfo().outresolution.height); } diff --git a/rpcs3/Emu/System.h b/rpcs3/Emu/System.h index c45c36b02..6e9438381 100644 --- a/rpcs3/Emu/System.h +++ b/rpcs3/Emu/System.h @@ -14,6 +14,7 @@ struct EmuCallbacks std::function()> get_mouse_handler; std::function()> get_pad_handler; std::function(frame_type)> get_gs_frame; + std::function()> get_gs_render; std::function()> get_msg_dialog; std::function()> get_save_dialog; }; diff --git a/rpcs3/Gui/AutoPauseManager.cpp b/rpcs3/Gui/AutoPauseManager.cpp index a3b7cd7af..0f20a6bee 100644 --- a/rpcs3/Gui/AutoPauseManager.cpp +++ b/rpcs3/Gui/AutoPauseManager.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Emu/System.h" #include "AutoPauseManager.h" diff --git a/rpcs3/Gui/CgDisasm.cpp b/rpcs3/Gui/CgDisasm.cpp index 91df81887..cc57e2b4d 100644 --- a/rpcs3/Gui/CgDisasm.cpp +++ b/rpcs3/Gui/CgDisasm.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "CgDisasm.h" diff --git a/rpcs3/Gui/CompilerELF.cpp b/rpcs3/Gui/CompilerELF.cpp index 3e97ee7ef..bc1bc501f 100644 --- a/rpcs3/Gui/CompilerELF.cpp +++ b/rpcs3/Gui/CompilerELF.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/rMsgBox.h" diff --git a/rpcs3/Gui/ConLogFrame.cpp b/rpcs3/Gui/ConLogFrame.cpp index 5c59e982a..96269d479 100644 --- a/rpcs3/Gui/ConLogFrame.cpp +++ b/rpcs3/Gui/ConLogFrame.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include diff --git a/rpcs3/Gui/Debugger.cpp b/rpcs3/Gui/Debugger.cpp index 05ab3d133..6465bb533 100644 --- a/rpcs3/Gui/Debugger.cpp +++ b/rpcs3/Gui/Debugger.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include diff --git a/rpcs3/Gui/DisAsmFrame.cpp b/rpcs3/Gui/DisAsmFrame.cpp index c7c52acff..090df0493 100644 --- a/rpcs3/Gui/DisAsmFrame.cpp +++ b/rpcs3/Gui/DisAsmFrame.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #if 0 #include "Utilities/Log.h" diff --git a/rpcs3/Gui/GLGSFrame.cpp b/rpcs3/Gui/GLGSFrame.cpp index 67e88bcca..cab168daa 100644 --- a/rpcs3/Gui/GLGSFrame.cpp +++ b/rpcs3/Gui/GLGSFrame.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "GLGSFrame.h" diff --git a/rpcs3/Gui/GSFrame.cpp b/rpcs3/Gui/GSFrame.cpp index 210fac10a..ca795320c 100644 --- a/rpcs3/Gui/GSFrame.cpp +++ b/rpcs3/Gui/GSFrame.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "GSFrame.h" #include "Emu/System.h" diff --git a/rpcs3/Gui/GameViewer.cpp b/rpcs3/Gui/GameViewer.cpp index 78b0e5131..337a44a9f 100644 --- a/rpcs3/Gui/GameViewer.cpp +++ b/rpcs3/Gui/GameViewer.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/AutoPause.h" #include "Utilities/Log.h" diff --git a/rpcs3/Gui/InterpreterDisAsm.cpp b/rpcs3/Gui/InterpreterDisAsm.cpp index 7b6167284..ed90b9e61 100644 --- a/rpcs3/Gui/InterpreterDisAsm.cpp +++ b/rpcs3/Gui/InterpreterDisAsm.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/Log.h" #include "Emu/Memory/Memory.h" diff --git a/rpcs3/Gui/KernelExplorer.cpp b/rpcs3/Gui/KernelExplorer.cpp index 0d1a9f350..ced4b6264 100644 --- a/rpcs3/Gui/KernelExplorer.cpp +++ b/rpcs3/Gui/KernelExplorer.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/Log.h" #include "Emu/Memory/Memory.h" diff --git a/rpcs3/Gui/LLEModulesManager.cpp b/rpcs3/Gui/LLEModulesManager.cpp index fc9eb85a7..bdb8dbd6a 100644 --- a/rpcs3/Gui/LLEModulesManager.cpp +++ b/rpcs3/Gui/LLEModulesManager.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/Log.h" #include "Loader/ELF64.h" diff --git a/rpcs3/Gui/MainFrame.cpp b/rpcs3/Gui/MainFrame.cpp index 3bf3d52bf..5f9be47e1 100644 --- a/rpcs3/Gui/MainFrame.cpp +++ b/rpcs3/Gui/MainFrame.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "rpcs3.h" #include "config.h" diff --git a/rpcs3/Gui/MemoryStringSearcher.cpp b/rpcs3/Gui/MemoryStringSearcher.cpp index 2138a1ece..200be53d5 100644 --- a/rpcs3/Gui/MemoryStringSearcher.cpp +++ b/rpcs3/Gui/MemoryStringSearcher.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/rPlatform.h" #include "Utilities/Log.h" diff --git a/rpcs3/Gui/MemoryViewer.cpp b/rpcs3/Gui/MemoryViewer.cpp index 3489f2a33..130847c54 100644 --- a/rpcs3/Gui/MemoryViewer.cpp +++ b/rpcs3/Gui/MemoryViewer.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/Log.h" #include "Emu/Memory/Memory.h" diff --git a/rpcs3/Gui/MsgDialog.cpp b/rpcs3/Gui/MsgDialog.cpp index 6013db337..a01154fe5 100644 --- a/rpcs3/Gui/MsgDialog.cpp +++ b/rpcs3/Gui/MsgDialog.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "rpcs3.h" #include "Emu/System.h" diff --git a/rpcs3/Gui/PADManager.cpp b/rpcs3/Gui/PADManager.cpp index 573e39edf..e5c6f01b1 100644 --- a/rpcs3/Gui/PADManager.cpp +++ b/rpcs3/Gui/PADManager.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/Log.h" #include "Emu/Memory/Memory.h" diff --git a/rpcs3/Gui/RSXDebugger.cpp b/rpcs3/Gui/RSXDebugger.cpp index 1d7ed7d51..622ba4eab 100644 --- a/rpcs3/Gui/RSXDebugger.cpp +++ b/rpcs3/Gui/RSXDebugger.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "RSXDebugger.h" diff --git a/rpcs3/Gui/SaveDataDialog.cpp b/rpcs3/Gui/SaveDataDialog.cpp index a6518800c..31689f694 100644 --- a/rpcs3/Gui/SaveDataDialog.cpp +++ b/rpcs3/Gui/SaveDataDialog.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Emu/Memory/Memory.h" diff --git a/rpcs3/Gui/SaveDataUtility.cpp b/rpcs3/Gui/SaveDataUtility.cpp index 2403f8aa5..f25a49e8e 100644 --- a/rpcs3/Gui/SaveDataUtility.cpp +++ b/rpcs3/Gui/SaveDataUtility.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "SaveDataUtility.h" #include "Utilities/Log.h" diff --git a/rpcs3/Gui/SettingsDialog.cpp b/rpcs3/Gui/SettingsDialog.cpp index fd651850a..99ee6783a 100644 --- a/rpcs3/Gui/SettingsDialog.cpp +++ b/rpcs3/Gui/SettingsDialog.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Emu/System.h" diff --git a/rpcs3/Gui/SignInDialog.cpp b/rpcs3/Gui/SignInDialog.cpp index 4b629a48f..fdc8f8b27 100644 --- a/rpcs3/Gui/SignInDialog.cpp +++ b/rpcs3/Gui/SignInDialog.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "SignInDialog.h" diff --git a/rpcs3/Gui/TextInputDialog.cpp b/rpcs3/Gui/TextInputDialog.cpp index a95795b2d..86353830d 100644 --- a/rpcs3/Gui/TextInputDialog.cpp +++ b/rpcs3/Gui/TextInputDialog.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "TextInputDialog.h" diff --git a/rpcs3/Gui/VFSManager.cpp b/rpcs3/Gui/VFSManager.cpp index d83680fd1..ead39cc39 100644 --- a/rpcs3/Gui/VFSManager.cpp +++ b/rpcs3/Gui/VFSManager.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/Log.h" #include "Emu/Memory/Memory.h" diff --git a/rpcs3/Gui/VHDDManager.cpp b/rpcs3/Gui/VHDDManager.cpp index d164b1650..223ebefee 100644 --- a/rpcs3/Gui/VHDDManager.cpp +++ b/rpcs3/Gui/VHDDManager.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Utilities/Log.h" #include "VHDDManager.h" diff --git a/rpcs3/emucore.vcxproj b/rpcs3/emucore.vcxproj index 1c67445b4..953599913 100644 --- a/rpcs3/emucore.vcxproj +++ b/rpcs3/emucore.vcxproj @@ -638,11 +638,6 @@ - - - {fac9b17b-f4b8-4b75-8aeb-c8c7cb92b078} - - {C4A10229-4712-4BD2-B63E-50D93C67A038} emucore @@ -742,6 +737,8 @@ true ../glm false + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb true @@ -758,6 +755,8 @@ Async true ../glm + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb true @@ -778,6 +777,8 @@ Async true ../glm + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb true @@ -796,6 +797,8 @@ true ../glm _UNICODE;UNICODE;%(PreprocessorDefinitions) + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb true @@ -813,9 +816,11 @@ Use stdafx.h Async - LLVM_AVAILABLE;%(PreprocessorDefinitions) + _UNICODE;UNICODE;LLVM_AVAILABLE;%(PreprocessorDefinitions) true ../glm + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb true diff --git a/rpcs3/rpcs3.cpp b/rpcs3/rpcs3.cpp index 50256fef0..54e1866a0 100644 --- a/rpcs3/rpcs3.cpp +++ b/rpcs3/rpcs3.cpp @@ -1,3 +1,4 @@ +#include "stdafx.h" #include "stdafx_gui.h" #include "Emu/Memory/Memory.h" #include "Emu/System.h" @@ -29,6 +30,13 @@ #include "Gui/SaveDataDialog.h" #include "Gui/GLGSFrame.h" + +#include "Emu/RSX/Null/NullGSRender.h" +#include "Emu/RSX/GL/GLGSRender.h" +#ifdef _MSC_VER +#include "Emu/RSX/D3D12/D3D12GSRender.h" +#endif + #include #ifdef _WIN32 @@ -110,7 +118,7 @@ bool Rpcs3App::OnInit() #ifdef _MSC_VER case io_handler_mode::xinput: return std::make_unique(); #endif - default: throw EXCEPTION("Invalid Pad Handler Mode %d", +(u32)mode); + default: throw EXCEPTION("Invalid Pad Handler Mode %d", (int)mode); } }; @@ -118,19 +126,27 @@ bool Rpcs3App::OnInit() { switch (type) { - case frame_type::OpenGL: - return std::make_unique(); - - case frame_type::DX12: - return std::make_unique("DirectX 12"); - - case frame_type::Null: - return std::make_unique("Null"); + case frame_type::OpenGL: return std::make_unique(); + case frame_type::DX12: return std::make_unique("DirectX 12"); + case frame_type::Null: return std::make_unique("Null"); } throw EXCEPTION("Invalid Frame Type"); }; + callbacks.get_gs_render = []() -> std::shared_ptr + { + switch (auto mode = rpcs3::state.config.rsx.renderer.value()) + { + case rsx_renderer_type::Null: return std::make_shared(); + case rsx_renderer_type::OpenGL: return std::make_shared(); +#ifdef _MSC_VER + case rsx_renderer_type::DX12: return std::make_shared(); +#endif + default: throw EXCEPTION("Invalid GS Renderer %d", (int)mode); + } + }; + callbacks.get_msg_dialog = []() -> std::unique_ptr { return std::make_unique(); diff --git a/rpcs3/rpcs3.vcxproj b/rpcs3/rpcs3.vcxproj index 5f0dc350e..7434256cc 100644 --- a/rpcs3/rpcs3.vcxproj +++ b/rpcs3/rpcs3.vcxproj @@ -50,7 +50,7 @@ Application false - true + false Unicode v140 false @@ -58,7 +58,7 @@ Application false - true + false Unicode v140 false @@ -124,9 +124,10 @@ Use ..\wxWidgets\include\msvc;..\glm Async - stdafx_gui.h - $(IntDir)$(TargetName)_gui.pch + stdafx.h + $(Platform)\$(Configuration).pch _UNICODE;UNICODE;%(PreprocessorDefinitions) + $(Platform)\$(Configuration).pdb true @@ -154,9 +155,10 @@ Use ..\wxWidgets\include\msvc;..\glm Async - stdafx_gui.h - $(IntDir)$(TargetName)_gui.pch + stdafx.h + $(Platform)\$(Configuration).pch _UNICODE;UNICODE;LLVM_AVAILABLE;%(PreprocessorDefinitions) + $(Platform)\$(Configuration).pdb true @@ -183,10 +185,11 @@ ProgramDatabase Use ..\wxWidgets\include\msvc;..\glm - _UNICODE;UNICODE;MSVC_CRT_MEMLEAK_DETECTION;%(PreprocessorDefinitions);DX12_SUPPORT + _UNICODE;UNICODE;MSVC_CRT_MEMLEAK_DETECTION;%(PreprocessorDefinitions) Async - stdafx_gui.h - $(IntDir)$(TargetName)_gui.pch + stdafx.h + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb true @@ -214,15 +217,15 @@ true ..\wxWidgets\include\msvc;..\glm MultiThreadedDLL - WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions) false Use Speed Async false true - stdafx_gui.h - $(IntDir)$(TargetName)_gui.pch + stdafx.h + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb Windows @@ -252,15 +255,16 @@ true ..\wxWidgets\include\msvc;..\glm MultiThreadedDLL - WIN32;NDEBUG;_WINDOWS;LLVM_AVAILABLE;%(PreprocessorDefinitions) false Use Speed Async false true - stdafx_gui.h - $(IntDir)$(TargetName)_gui.pch + stdafx.h + $(Platform)\$(Configuration).pch + $(Platform)\$(Configuration).pdb + _UNICODE;UNICODE;LLVM_AVAILABLE;%(PreprocessorDefinitions) Windows @@ -311,13 +315,6 @@ - - Create - Create - Create - Create - Create - diff --git a/rpcs3/rpcs3.vcxproj.filters b/rpcs3/rpcs3.vcxproj.filters index 8d1549118..f4b982135 100644 --- a/rpcs3/rpcs3.vcxproj.filters +++ b/rpcs3/rpcs3.vcxproj.filters @@ -81,9 +81,6 @@ Io\XInput - - rpcs3 - Gui diff --git a/rpcs3/stdafx_d3d12.cpp b/rpcs3/stdafx_d3d12.cpp deleted file mode 100644 index e8a394cff..000000000 --- a/rpcs3/stdafx_d3d12.cpp +++ /dev/null @@ -1,7 +0,0 @@ -#include "stdafx_d3d12.h" - -#ifdef _MSC_VER -#pragma comment(lib, "d2d1") -#pragma comment(lib, "DXGI") -#pragma comment(lib, "Dwrite") -#endif diff --git a/rpcs3/stdafx_d3d12.h b/rpcs3/stdafx_d3d12.h index b72b98664..19f78b367 100644 --- a/rpcs3/stdafx_d3d12.h +++ b/rpcs3/stdafx_d3d12.h @@ -1,7 +1,6 @@ #pragma once -#ifdef _MSC_VER -#include "stdafx.h" +#ifdef _MSC_VER // Must be included first #include @@ -10,4 +9,9 @@ #include "Emu\RSX\D3D12\D3D12Utils.h" #include "Emu\RSX\D3D12\D3D12Formats.h" #include "Emu\RSX\D3D12\D3D12GSRender.h" + +#pragma comment(lib, "d2d1") +#pragma comment(lib, "DXGI") +#pragma comment(lib, "Dwrite") + #endif diff --git a/rpcs3/stdafx_gui.cpp b/rpcs3/stdafx_gui.cpp deleted file mode 100644 index b4f62112d..000000000 --- a/rpcs3/stdafx_gui.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "stdafx_gui.h" \ No newline at end of file diff --git a/rpcs3/stdafx_gui.h b/rpcs3/stdafx_gui.h index 090192991..083c9525c 100644 --- a/rpcs3/stdafx_gui.h +++ b/rpcs3/stdafx_gui.h @@ -1,6 +1,9 @@ #pragma once #ifndef QT_UI +#ifdef _MSC_VER +#pragma warning(push, 0) +#endif #include #include #include @@ -23,6 +26,7 @@ #include #include #include +#ifdef _MSC_VER +#pragma warning(pop) +#endif #endif - -#include "stdafx.h"