diff --git a/build/win32/Cxbx.vcxproj b/build/win32/Cxbx.vcxproj index 1f0fb073f..1f122c870 100644 --- a/build/win32/Cxbx.vcxproj +++ b/build/win32/Cxbx.vcxproj @@ -227,9 +227,9 @@ - - - + + + @@ -239,16 +239,16 @@ - - - - - + + + + + - - + + @@ -419,18 +419,8 @@ %(PreprocessorDefinitions) %(PreprocessorDefinitions) - - %(AdditionalIncludeDirectories) - %(AdditionalIncludeDirectories) - %(PreprocessorDefinitions) - %(PreprocessorDefinitions) - - - %(AdditionalIncludeDirectories) - %(AdditionalIncludeDirectories) - %(PreprocessorDefinitions) - %(PreprocessorDefinitions) - + + %(AdditionalIncludeDirectories) %(AdditionalIncludeDirectories) @@ -476,36 +466,21 @@ - - - %(AdditionalIncludeDirectories) - %(AdditionalIncludeDirectories) - %(PreprocessorDefinitions) - %(PreprocessorDefinitions) - - - %(AdditionalIncludeDirectories) - %(AdditionalIncludeDirectories) - %(PreprocessorDefinitions) - %(PreprocessorDefinitions) - - - + + + %(AdditionalIncludeDirectories) %(AdditionalIncludeDirectories) %(PreprocessorDefinitions) %(PreprocessorDefinitions) + + - - %(AdditionalIncludeDirectories) - %(AdditionalIncludeDirectories) - %(PreprocessorDefinitions) - %(PreprocessorDefinitions) - - + + %(AdditionalIncludeDirectories) %(AdditionalIncludeDirectories) diff --git a/build/win32/Cxbx.vcxproj.filters b/build/win32/Cxbx.vcxproj.filters index e6a712e55..4f84615ac 100644 --- a/build/win32/Cxbx.vcxproj.filters +++ b/build/win32/Cxbx.vcxproj.filters @@ -109,11 +109,11 @@ Emulator - - Emulator + + core\HLE\XAPI\OHCI\XInput - - Emulator + + core\HLE\DSOUND\DirectSound Emulator @@ -130,23 +130,23 @@ Emulator - - Emulator + + core\HLE\XACTENG - - Emulator + + core\HLE\XAPI - - Emulator + + core\HLE\XGRAPHIC - - Emulator + + core\HLE\XAPI\OHCI\XInput - - Emulator + + core\HLE\XONLINE - - Emulator + + core\HLE Kernel @@ -320,11 +320,6 @@ Cross Platform\Win32 - - Emulator - - - GUI @@ -391,11 +386,11 @@ Emulator - - Emulator + + core\HLE\XAPI\OHCI\XInput - - Emulator + + core\HLE\DSOUND\DirectSound Emulator @@ -409,26 +404,26 @@ Emulator - - Emulator + + core\HLE\XACTENG - - Emulator + + core\HLE\XAPI - - Emulator + + core\HLE\XGRAPHIC - - Emulator + + core\HLE\XAPI\OHCI\XInput - - Emulator + + core\HLE\XONLINE Emulator - - Emulator + + core\HLE Emulator @@ -469,8 +464,8 @@ Shared - - Emulator + + core\HLE\DSOUND\DirectSound GUI @@ -631,9 +626,12 @@ Cross Platform - - Emulator + + core\HLE + + core\HLE + @@ -767,6 +765,39 @@ {76faeca9-d66f-43fb-9efa-ffb0668f8843} + + {6d7b4608-3bf3-401f-924e-52617798e6b8} + + + {563da04b-4c54-4c1b-a055-809ce0f5bf97} + + + {5fcb96a1-736d-4749-ba21-a87dedc72427} + + + {9b3e7b4d-161e-4eeb-9338-3368e134b439} + + + {6f4e7159-1112-4a80-9e76-11963812811e} + + + {f9c6738c-bb93-4de5-b3ae-490f2d80fa74} + + + {69e32fa9-3fcd-400a-8d45-66b7ec3d555c} + + + {dd1295ad-f875-47dc-a6bb-d5679452f236} + + + {c6ea372d-ae98-46eb-917f-009302c000c5} + + + {c494f79e-ff8e-4b45-b1c3-1da0b4b9ee49} + + + {6f39b9de-ab9d-4780-b687-2d930f86738e} + diff --git a/src/CxbxKrnl/CxbxKrnl.cpp b/src/CxbxKrnl/CxbxKrnl.cpp index 33c11b791..7d01b5e7c 100644 --- a/src/CxbxKrnl/CxbxKrnl.cpp +++ b/src/CxbxKrnl/CxbxKrnl.cpp @@ -56,7 +56,7 @@ namespace xboxkrnl #include "EmuKrnl.h" #include "EmuShared.h" #include "EmuXTL.h" -#include "HLEIntercept.h" +#include "core/HLE/Intercept.hpp" #include "ReservedMemory.h" // For virtual_memory_placeholder #include "VMManager.h" #include "CxbxDebugger.h" diff --git a/src/CxbxKrnl/Emu.cpp b/src/CxbxKrnl/Emu.cpp index f4ed2de85..f1e9b236f 100644 --- a/src/CxbxKrnl/Emu.cpp +++ b/src/CxbxKrnl/Emu.cpp @@ -47,7 +47,7 @@ namespace xboxkrnl #include "EmuFS.h" #include "EmuXTL.h" #include "EmuShared.h" -#include "HLEIntercept.h" +#include "core/HLE/Intercept.hpp" #include "CxbxDebugger.h" #ifdef _DEBUG diff --git a/src/CxbxKrnl/EmuD3D8.cpp b/src/CxbxKrnl/EmuD3D8.cpp index 4af439259..83a20d9a3 100644 --- a/src/CxbxKrnl/EmuD3D8.cpp +++ b/src/CxbxKrnl/EmuD3D8.cpp @@ -57,7 +57,7 @@ namespace xboxkrnl #include "EmuXTL.h" #include "Logging.h" #include "EmuD3D8Logging.h" -#include "HLEIntercept.h" // for bLLE_GPU +#include "core/HLE/Intercept.hpp" // for bLLE_GPU #include "Cxbx/ResCxbx.h" #include diff --git a/src/CxbxKrnl/EmuX86.cpp b/src/CxbxKrnl/EmuX86.cpp index 6c96923f1..7571ac2eb 100644 --- a/src/CxbxKrnl/EmuX86.cpp +++ b/src/CxbxKrnl/EmuX86.cpp @@ -49,7 +49,7 @@ #include "CxbxKrnl.h" #include "Emu.h" // For EmuLog #include "EmuX86.h" -#include "HLEIntercept.h" // for bLLE_GPU +#include "core/HLE/Intercept.hpp" // for bLLE_GPU #include #include "devices\Xbox.h" // For g_PCIBus diff --git a/src/CxbxKrnl/EmuXTL.h b/src/CxbxKrnl/EmuXTL.h index d9f9de73a..19a79ddfc 100644 --- a/src/CxbxKrnl/EmuXTL.h +++ b/src/CxbxKrnl/EmuXTL.h @@ -38,7 +38,7 @@ namespace XTL { - #include "EmuXapi.h" + #include "core/HLE/XAPI/Xapi.h" #include "EmuD3D8.h" #include "EmuD3D8\Convert.h" #include "EmuD3D8\VertexBuffer.h" @@ -46,12 +46,12 @@ namespace XTL #include "EmuD3D8\VertexShader.h" #include "EmuD3D8\PixelShader.h" #include "EmuD3D8\State.h" - #include "EmuDInput.h" - #include "EmuDSound.h" - #include "EmuXOnline.h" - #include "EmuXG.h" - #include "EmuXactEng.h" - #include "EmuXInput.h" + #include "core/HLE/XAPI/OHCI/XInput/DInput.h" + #include "core/HLE/DSOUND/DirectSound/DirectSound.hpp" + #include "core/HLE/XONLINE/XOnline.h" + #include "core/HLE/XGRAPHIC/XGraphic.h" + #include "core/HLE/XACTENG/XactEng.h" + #include "core/HLE/XAPI/OHCI/XInput/XInput.h" } extern XTL::IDirect3DDevice *g_pD3DDevice; diff --git a/src/CxbxKrnl/EmuDSound.cpp b/src/core/HLE/DSOUND/DirectSound/DirectSound.cpp old mode 100755 new mode 100644 similarity index 99% rename from src/CxbxKrnl/EmuDSound.cpp rename to src/core/HLE/DSOUND/DirectSound/DirectSound.cpp index 7de683c98..53e89ea84 --- a/src/CxbxKrnl/EmuDSound.cpp +++ b/src/core/HLE/DSOUND/DirectSound/DirectSound.cpp @@ -9,7 +9,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuDSound.cpp +// * src->core->HLE->DSound->DirectSound->DirectSound.cpp // * // * This file is part of the Cxbx project. // * @@ -45,11 +45,11 @@ namespace xboxkrnl { #include #include -#include "CxbxKrnl.h" -#include "Emu.h" -#include "EmuFS.h" -#include "EmuShared.h" -#include "EmuXTL.h" +#include "CxbxKrnl/CxbxKrnl.h" +#include "CxbxKrnl/Emu.h" +#include "CxbxKrnl/EmuFS.h" +#include "CxbxKrnl/EmuShared.h" +#include "CxbxKrnl/EmuXTL.h" #include "Common/Settings.hpp" @@ -220,7 +220,7 @@ static void dsound_thread_worker(LPVOID); EmuLog(LOG_PREFIX, LOG_LEVEL::WARNING, "An issue has been found. Please report game title and console's output of return result," \ " function, and file name to https://github.com/Cxbx-Reloaded/Cxbx-Reloaded/issues/485"); } return hRet; } -#include "EmuDSoundInline.hpp" +#include "DirectSoundInline.hpp" #ifdef __cplusplus extern "C" { diff --git a/src/CxbxKrnl/EmuDSound.h b/src/core/HLE/DSOUND/DirectSound/DirectSound.hpp old mode 100755 new mode 100644 similarity index 99% rename from src/CxbxKrnl/EmuDSound.h rename to src/core/HLE/DSOUND/DirectSound/DirectSound.hpp index 166ce467e..1d4b8d17a --- a/src/CxbxKrnl/EmuDSound.h +++ b/src/core/HLE/DSOUND/DirectSound/DirectSound.hpp @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuDSound.h +// * src->core->HLE->DSound->DirectSound->DirectSound.h // * // * This file is part of the Cxbx project. // * diff --git a/src/CxbxKrnl/EmuDSoundInline.hpp b/src/core/HLE/DSOUND/DirectSound/DirectSoundInline.hpp similarity index 99% rename from src/CxbxKrnl/EmuDSoundInline.hpp rename to src/core/HLE/DSOUND/DirectSound/DirectSoundInline.hpp index ff4c1fb36..96663cfdb 100644 --- a/src/CxbxKrnl/EmuDSoundInline.hpp +++ b/src/core/HLE/DSOUND/DirectSound/DirectSoundInline.hpp @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuDSoundInline.hpp +// * src->core->HLE->DSound->DirectSound->DirectSoundInline.hpp // * // * This file is part of the Cxbx project. // * diff --git a/src/CxbxKrnl/HLEIntercept.cpp b/src/core/HLE/Intercept.cpp similarity index 98% rename from src/CxbxKrnl/HLEIntercept.cpp rename to src/core/HLE/Intercept.cpp index 43ad2ff8e..18ecd3107 100644 --- a/src/CxbxKrnl/HLEIntercept.cpp +++ b/src/core/HLE/Intercept.cpp @@ -9,7 +9,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->HLEIntercept.cpp +// * src->core->HLE->Intercept.cpp // * // * This file is part of the Cxbx project. // * @@ -38,18 +38,18 @@ #include #include // For std::setfill and std::setw -#include "CxbxKrnl.h" -#include "Emu.h" -#include "EmuFS.h" -#include "EmuXTL.h" -#include "EmuShared.h" -#include "CxbxDebugger.h" +#include "CxbxKrnl/CxbxKrnl.h" +#include "CxbxKrnl/Emu.h" +#include "CxbxKrnl/EmuFS.h" +#include "CxbxKrnl/EmuXTL.h" +#include "CxbxKrnl/EmuShared.h" +#include "Common/CxbxDebugger.h" #include "Logging.h" #pragma comment(lib, "XbSymbolDatabase.lib") #include "../../import/XbSymbolDatabase/XbSymbolDatabase.h" -#include "HLEIntercept.h" -#include "HLEPatches.h" -#include "xxhash32.h" +#include "Intercept.hpp" +#include "Patches.hpp" +#include "CxbxKrnl/xxhash32.h" #include #include #include @@ -60,19 +60,19 @@ std::map g_SymbolAddresses; bool g_HLECacheUsed = false; // D3D build version -uint32 g_BuildVersion = 0; - +uint32 g_BuildVersion = 0; + bool bLLE_APU = false; // Set this to true for experimental APU (sound) LLE -bool bLLE_GPU = false; // Set this to true for experimental GPU (graphics) LLE +bool bLLE_GPU = false; // Set this to true for experimental GPU (graphics) LLE bool bLLE_USB = false; // Set this to true for experimental USB (input) LLE bool bLLE_JIT = false; // Set this to true for experimental JIT void* GetXboxFunctionPointer(std::string functionName) -{ - void* ptr = GetPatchedFunctionTrampoline(functionName); - if (ptr != nullptr) { - return ptr; - } +{ + void* ptr = GetPatchedFunctionTrampoline(functionName); + if (ptr != nullptr) { + return ptr; + } // If we got here, the function wasn't patched, so we can just look it up the HLE cache // and return the correct offset @@ -134,7 +134,7 @@ bool VerifySymbolAddressAgainstXRef(char *SymbolName, xbaddr Address, int XRef) } // For XREF_D3DTSS_TEXCOORDINDEX, Kabuki Warriors hits this case - CxbxPopupMessage(LOG_PREFIX, LOG_LEVEL::WARNING, CxbxMsgDlgIcon_Warn, + CxbxPopupMessage(LOG_PREFIX, LOG_LEVEL::WARNING, CxbxMsgDlgIcon_Warn, "Verification of %s failed : XREF was 0x%.8X while lookup gave 0x%.8X", SymbolName, XRefAddr, Address); // For XREF_D3DTSS_TEXCOORDINDEX, Kabuki Warriors hits this case return false; @@ -266,10 +266,10 @@ void CDECL EmuRegisterSymbol(const char* library_str, output << "\t*NO PATCH AVAILABLE!*"; } } -#endif - - output << "\n"; - +#endif + + output << "\n"; + g_SymbolAddresses[symbol_str] = func_addr; printf(output.str().c_str()); } @@ -316,16 +316,16 @@ uint EmuUpdateLLEStatus(uint32_t XbLibScan) bLLE_APU = true; FlagsLLE ^= LLE_APU; EmuOutputMessage(XB_OUTPUT_MESSAGE_INFO, "Fallback to LLE APU."); - } -#if 0 // Reenable this when LLE USB actually works + } +#if 0 // Reenable this when LLE USB actually works if ((FlagsLLE & LLE_USB) == false && (XbLibScan & XbSymbolLib_XAPILIB) == 0) { bLLE_USB = true; FlagsLLE ^= LLE_USB; EmuOutputMessage(XB_OUTPUT_MESSAGE_INFO, "Fallback to LLE USB."); - } + } #endif - ipc_send_gui_update(IPC_UPDATE_GUI::LLE_FLAGS, FlagsLLE); + ipc_send_gui_update(IPC_UPDATE_GUI::LLE_FLAGS, FlagsLLE); return FlagsLLE; } @@ -472,8 +472,8 @@ void EmuHLEIntercept(Xbe::Header *pXbeHeader) } // If the HLE Cache was used, go straight to patching, no need to re-scan - if (g_HLECacheUsed) { - EmuInstallPatches(); + if (g_HLECacheUsed) { + EmuInstallPatches(); return; } @@ -574,7 +574,7 @@ void EmuHLEIntercept(Xbe::Header *pXbeHeader) std::stringstream cacheAddress; cacheAddress << std::hex << (*it).second; WritePrivateProfileString("Symbols", (*it).first.c_str(), cacheAddress.str().c_str(), filename.c_str()); - } + } EmuInstallPatches(); } diff --git a/src/CxbxKrnl/HLEIntercept.h b/src/core/HLE/Intercept.hpp similarity index 95% rename from src/CxbxKrnl/HLEIntercept.h rename to src/core/HLE/Intercept.hpp index 17a149593..d1cfe7ab9 100644 --- a/src/CxbxKrnl/HLEIntercept.h +++ b/src/core/HLE/Intercept.hpp @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->HLEIntercept.h +// * src->core->HLE->Intercept.hpp // * // * This file is part of the Cxbx project. // * @@ -31,13 +31,13 @@ // * All rights reserved // * // ****************************************************************** -#ifndef HLEINTERCEPT_H -#define HLEINTERCEPT_H +#ifndef HLEINTERCEPT_HPP +#define HLEINTERCEPT_HPP #include extern bool bLLE_APU; // Set this to true for experimental APU (sound) LLE -extern bool bLLE_GPU; // Set this to true for experimental GPU (graphics) LLE +extern bool bLLE_GPU; // Set this to true for experimental GPU (graphics) LLE extern bool bLLE_USB; // Set this to true for experimental USB (input) LLE extern bool bLLE_JIT; // Set this to true for experimental JIT @@ -57,4 +57,4 @@ void* GetXboxFunctionPointer(std::string functionName); void VerifyHLEDataBase(); #endif -#endif // HLEINTERCEPT_H +#endif diff --git a/src/CxbxKrnl/HLEPatches.cpp b/src/core/HLE/Patches.cpp similarity index 99% rename from src/CxbxKrnl/HLEPatches.cpp rename to src/core/HLE/Patches.cpp index 62b5069d8..72e0a4228 100644 --- a/src/CxbxKrnl/HLEPatches.cpp +++ b/src/core/HLE/Patches.cpp @@ -10,7 +10,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->HLEPatches.cpp +// * src->core->HLE->Patches.cpp // * // * This file is part of the Cxbx project. // * @@ -35,11 +35,11 @@ // * // ****************************************************************** -#include "CxbxKrnl.h" -#include "Emu.h" -#include "EmuXTL.h" -#include "HLEPatches.h" -#include "HLEIntercept.h" +#include "CxbxKrnl/CxbxKrnl.h" +#include "CxbxKrnl/Emu.h" +#include "CxbxKrnl/EmuXTL.h" +#include "Patches.hpp" +#include "Intercept.hpp" #include #include diff --git a/src/CxbxKrnl/HLEPatches.h b/src/core/HLE/Patches.hpp similarity index 94% rename from src/CxbxKrnl/HLEPatches.h rename to src/core/HLE/Patches.hpp index faba42ca2..eb1efe3af 100644 --- a/src/CxbxKrnl/HLEPatches.h +++ b/src/core/HLE/Patches.hpp @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->HLEPatches.h +// * src->core->HLE->Patches.hpp // * // * This file is part of the Cxbx project. // * @@ -31,8 +31,12 @@ // * All rights reserved // * // ****************************************************************** +#ifndef HLEPATCHES_HPP +#define HLEPATCHES_HPP #include void EmuInstallPatches(); void* GetPatchedFunctionTrampoline(std::string functionName); + +#endif diff --git a/src/CxbxKrnl/EmuXactEng.cpp b/src/core/HLE/XACTENG/XactEng.cpp similarity index 98% rename from src/CxbxKrnl/EmuXactEng.cpp rename to src/core/HLE/XACTENG/XactEng.cpp index 417107fe2..5f8ec6657 100644 --- a/src/CxbxKrnl/EmuXactEng.cpp +++ b/src/core/HLE/XACTENG/XactEng.cpp @@ -9,7 +9,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuXactEng.cpp +// * src->core->HLE->XACTENG->XactEng.cpp // * // * This file is part of the Cxbx project. // * @@ -43,13 +43,13 @@ namespace xboxkrnl #include }; -#include "CxbxKrnl.h" -#include "Logging.h" -#include "Emu.h" -#include "EmuFS.h" -#include "EmuShared.h" -#include "EmuXTL.h" -#include "VMManager.h" +#include "CxbxKrnl/CxbxKrnl.h" +#include "Common/Logging.h" +#include "CxbxKrnl/Emu.h" +#include "CxbxKrnl/EmuFS.h" +#include "CxbxKrnl/EmuShared.h" +#include "CxbxKrnl/EmuXTL.h" +#include "CxbxKrnl/VMManager.h" #include #include diff --git a/src/CxbxKrnl/EmuXactEng.h b/src/core/HLE/XACTENG/XactEng.h similarity index 99% rename from src/CxbxKrnl/EmuXactEng.h rename to src/core/HLE/XACTENG/XactEng.h index 63ac302e4..fb2f25151 100644 --- a/src/CxbxKrnl/EmuXactEng.h +++ b/src/core/HLE/XACTENG/XactEng.h @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuXactEng.h +// * src->core->HLE->XACTENG->XactEng.h // * // * This file is part of the Cxbx project. // * @@ -352,4 +352,4 @@ HRESULT WINAPI EMUPATCH(IXACTEngine_UnRegisterWaveBank) X_XACTWaveBank* pWaveBank ); -#endif \ No newline at end of file +#endif diff --git a/src/CxbxKrnl/EmuDInput.cpp b/src/core/HLE/XAPI/OHCI/XInput/DInput.cpp similarity index 95% rename from src/CxbxKrnl/EmuDInput.cpp rename to src/core/HLE/XAPI/OHCI/XInput/DInput.cpp index 8016ad9e7..0a0d1691c 100644 --- a/src/CxbxKrnl/EmuDInput.cpp +++ b/src/core/HLE/XAPI/OHCI/XInput/DInput.cpp @@ -9,7 +9,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuDInput.cpp +// * src->core->HLE->XAPI->OHCI->XInput->DInput.cpp // * // * This file is part of the Cxbx project. // * @@ -37,10 +37,10 @@ #define LOG_PREFIX CXBXR_MODULE::DINP -#include "Emu.h" -#include "EmuXTL.h" -#include "EmuShared.h" -#include "Common/Win32/DInputController.h" +#include "CxbxKrnl/Emu.h" +#include "CxbxKrnl/EmuXTL.h" +#include "CxbxKrnl/EmuShared.h" +#include "Common/Win32/DInputController.h" #include "Logging.h" // ****************************************************************** diff --git a/src/CxbxKrnl/EmuDInput.h b/src/core/HLE/XAPI/OHCI/XInput/DInput.h similarity index 96% rename from src/CxbxKrnl/EmuDInput.h rename to src/core/HLE/XAPI/OHCI/XInput/DInput.h index 313d39c96..d3a2ccd0d 100644 --- a/src/CxbxKrnl/EmuDInput.h +++ b/src/core/HLE/XAPI/OHCI/XInput/DInput.h @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuDInput.h +// * src->core->HLE->XAPI->OHCI->XInput->DInput.h // * // * This file is part of the Cxbx project. // * @@ -31,8 +31,8 @@ // * All rights reserved // * // ****************************************************************** -#ifndef EMUDINPUT_H -#define EMUDINPUT_H +#ifndef DINPUT_H +#define DINPUT_H #define DIRECTINPUT_VERSION 0x0800 #include diff --git a/src/CxbxKrnl/EmuXInput.cpp b/src/core/HLE/XAPI/OHCI/XInput/XInput.cpp similarity index 97% rename from src/CxbxKrnl/EmuXInput.cpp rename to src/core/HLE/XAPI/OHCI/XInput/XInput.cpp index 0d4b5bf0c..da9aae948 100644 --- a/src/CxbxKrnl/EmuXInput.cpp +++ b/src/core/HLE/XAPI/OHCI/XInput/XInput.cpp @@ -9,7 +9,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuDInput.cpp +// * src->core->HLE->XAPI->OHCI->XInput->DInput.cpp // * // * This file is part of the Cxbx project. // * @@ -37,12 +37,12 @@ #define LOG_PREFIX CXBXR_MODULE::XINP -#include "Emu.h" -#include "EmuXTL.h" -#include "EmuShared.h" -#include "EmuXInput.h" +#include "CxbxKrnl/Emu.h" +#include "CxbxKrnl/EmuXTL.h" +#include "CxbxKrnl/EmuShared.h" +#include "XInput.h" -#include +#include #include "Logging.h" diff --git a/src/CxbxKrnl/EmuXInput.h b/src/core/HLE/XAPI/OHCI/XInput/XInput.h similarity index 95% rename from src/CxbxKrnl/EmuXInput.h rename to src/core/HLE/XAPI/OHCI/XInput/XInput.h index 852d3d60b..72c7d56c1 100644 --- a/src/CxbxKrnl/EmuXInput.h +++ b/src/core/HLE/XAPI/OHCI/XInput/XInput.h @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuXInput.h +// * src->core->HLE->XAPI->OHCI->XInput->XInput.h // * // * This file is part of the Cxbx project. // * @@ -31,8 +31,8 @@ // * All rights reserved // * // ****************************************************************** -#ifndef EMUXINPUT_H -#define EMUXINPUT_H +#ifndef XINPUT_H +#define XINPUT_H //query the total connected xinput gamepad DWORD XInputGamepad_Connected(void); diff --git a/src/CxbxKrnl/EmuXapi.cpp b/src/core/HLE/XAPI/Xapi.cpp similarity index 99% rename from src/CxbxKrnl/EmuXapi.cpp rename to src/core/HLE/XAPI/Xapi.cpp index ff3a2594e..a8eddc8ef 100644 --- a/src/CxbxKrnl/EmuXapi.cpp +++ b/src/core/HLE/XAPI/Xapi.cpp @@ -45,16 +45,16 @@ namespace xboxkrnl }; #include -#include "CxbxKrnl.h" +#include "CxbxKrnl/CxbxKrnl.h" #include "Logging.h" -#include "Emu.h" -#include "EmuKrnl.h" // For DefaultLaunchDataPage -#include "EmuFile.h" -#include "EmuFS.h" -#include "EmuXTL.h" -#include "EmuShared.h" +#include "CxbxKrnl/Emu.h" +#include "CxbxKrnl/EmuKrnl.h" // For DefaultLaunchDataPage +#include "CxbxKrnl/EmuFile.h" +#include "CxbxKrnl/EmuFS.h" +#include "CxbxKrnl/EmuXTL.h" +#include "CxbxKrnl/EmuShared.h" #include "../Common/Win32/XBPortMapping.h" -#include "HLEIntercept.h" +#include "core/HLE/Intercept.hpp" #include "CxbxVSBC/CxbxVSBC.h" #include "Windef.h" #include diff --git a/src/CxbxKrnl/EmuXapi.h b/src/core/HLE/XAPI/Xapi.h similarity index 99% rename from src/CxbxKrnl/EmuXapi.h rename to src/core/HLE/XAPI/Xapi.h index 80ed26a29..8e8fd9731 100644 --- a/src/CxbxKrnl/EmuXapi.h +++ b/src/core/HLE/XAPI/Xapi.h @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuXapi.h +// * src->core->HLE->XAPI->Xapi.h // * // * This file is part of the Cxbx project. // * @@ -31,8 +31,8 @@ // * All rights reserved // * // ****************************************************************** -#ifndef EMUXAPI_H -#define EMUXAPI_H +#ifndef XAPI_H +#define XAPI_H // ****************************************************************** // * calling conventions diff --git a/src/CxbxKrnl/EmuXG.cpp b/src/core/HLE/XGRAPHIC/XGraphic.cpp similarity index 97% rename from src/CxbxKrnl/EmuXG.cpp rename to src/core/HLE/XGRAPHIC/XGraphic.cpp index 2a1575a9c..c095cdaa7 100644 --- a/src/CxbxKrnl/EmuXG.cpp +++ b/src/core/HLE/XGRAPHIC/XGraphic.cpp @@ -9,7 +9,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuXG.cpp +// * core->HLE->XGRAPHIC->XGraphic.cpp // * // * This file is part of the Cxbx project. // * @@ -40,11 +40,11 @@ #undef FIELD_OFFSET // prevent macro redefinition warnings #include -#include "Emu.h" -#include "EmuFS.h" -#include "Logging.h" -#include "EmuXTL.h" -#include "EmuD3D8Logging.h" // for log rendering of X_D3DFORMAT, etc. +#include "CxbxKrnl/Emu.h" +#include "CxbxKrnl/EmuFS.h" +#include "Common/Logging.h" +#include "CxbxKrnl/EmuXTL.h" +#include "CxbxKrnl/EmuD3D8Logging.h" // for log rendering of X_D3DFORMAT, etc. // ****************************************************************** // * patch: XGIsSwizzledFormat diff --git a/src/CxbxKrnl/EmuXG.h b/src/core/HLE/XGRAPHIC/XGraphic.h similarity index 97% rename from src/CxbxKrnl/EmuXG.h rename to src/core/HLE/XGRAPHIC/XGraphic.h index d9ee7780f..0aa8290f7 100644 --- a/src/CxbxKrnl/EmuXG.h +++ b/src/core/HLE/XGRAPHIC/XGraphic.h @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuXG.h +// * core->HLE->XGRAPHIC->XGraphic.h // * // * This file is part of the Cxbx project. // * @@ -31,8 +31,8 @@ // * All rights reserved // * // ****************************************************************** -#ifndef EMUXG_H -#define EMUXG_H +#ifndef XGRAPHIC_H +#define XGRAPHIC_H typedef struct _XGPOINT3D { diff --git a/src/CxbxKrnl/EmuXOnline.cpp b/src/core/HLE/XONLINE/XOnline.cpp similarity index 97% rename from src/CxbxKrnl/EmuXOnline.cpp rename to src/core/HLE/XONLINE/XOnline.cpp index 0b3537b09..68ed34b8c 100644 --- a/src/CxbxKrnl/EmuXOnline.cpp +++ b/src/core/HLE/XONLINE/XOnline.cpp @@ -9,7 +9,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuXOnline.cpp +// * src->core->HLE->XONLINE->XOnline.cpp // * // * This file is part of the Cxbx project. // * @@ -37,10 +37,10 @@ #define LOG_PREFIX CXBXR_MODULE::XONLINE -#include "Emu.h" -#include "Logging.h" -#include "EmuFS.h" -#include "EmuXTL.h" +#include "CxbxKrnl/Emu.h" +#include "Common/Logging.h" +#include "CxbxKrnl/EmuFS.h" +#include "CxbxKrnl/EmuXTL.h" /* // ****************************************************************** diff --git a/src/CxbxKrnl/EmuXOnline.h b/src/core/HLE/XONLINE/XOnline.h similarity index 97% rename from src/CxbxKrnl/EmuXOnline.h rename to src/core/HLE/XONLINE/XOnline.h index b8a6f7447..5a5b32cab 100644 --- a/src/CxbxKrnl/EmuXOnline.h +++ b/src/core/HLE/XONLINE/XOnline.h @@ -7,7 +7,7 @@ // * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, // * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, // * -// * Cxbx->Win32->CxbxKrnl->EmuXOnline.h +// * src->core->HLE->XONLINE->XOnline.h // * // * This file is part of the Cxbx project. // * @@ -31,8 +31,8 @@ // * All rights reserved // * // ****************************************************************** -#ifndef EMUXONLINE_H -#define EMUXONLINE_H +#ifndef XONLINE_H +#define XONLINE_H // Flags returned by XNetGetEthernetLinkStatus() diff --git a/src/devices/Xbox.cpp b/src/devices/Xbox.cpp index 3b23a86cd..85b7fb2dc 100644 --- a/src/devices/Xbox.cpp +++ b/src/devices/Xbox.cpp @@ -36,7 +36,7 @@ #include "Xbox.h" // For HardwareModel #include "Xbe.h" // Without this HLEIntercept complains about some undefined xbe variables -#include "..\CxbxKrnl\HLEIntercept.h" +#include "core/HLE/Intercept.hpp" PCIBus* g_PCIBus; SMBus* g_SMBus; diff --git a/src/devices/video/nv2a.cpp b/src/devices/video/nv2a.cpp index 9ca8f1f7e..bc4252e23 100644 --- a/src/devices/video/nv2a.cpp +++ b/src/devices/video/nv2a.cpp @@ -65,7 +65,7 @@ namespace xboxkrnl #include "CxbxKrnl\Emu.h" #include "CxbxKrnl\EmuFS.h" #include "CxbxKrnl\EmuKrnl.h" -#include "CxbxKrnl\HLEIntercept.h" +#include "core/HLE/Intercept.hpp" #include "Logging.h" #include "vga.h"