diff --git a/CMakeLists.txt b/CMakeLists.txt index 848d5081e..b513d342a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -114,7 +114,7 @@ file (GLOB CXBXR_HEADER_EMU "${CXBXR_ROOT_DIR}/src/common/audio/converter.hpp" "${CXBXR_ROOT_DIR}/src/common/util/gloffscreen/glextensions.h" "${CXBXR_ROOT_DIR}/src/common/util/gloffscreen/gloffscreen.h" - "${CXBXR_ROOT_DIR}/src/common/XADPCM.h" + "${CXBXR_ROOT_DIR}/src/common/audio/XADPCM.h" "${CXBXR_ROOT_DIR}/src/common/xbox/Logging.hpp" "${CXBXR_ROOT_DIR}/src/core/hle/D3D8/Direct3D9/CxbxVertexShaderTemplate.hlsl" "${CXBXR_ROOT_DIR}/src/core/hle/D3D8/Direct3D9/Direct3D9.h" @@ -164,7 +164,7 @@ file (GLOB CXBXR_HEADER_EMU "${CXBXR_ROOT_DIR}/src/core/kernel/support/EmuNtDll.h" "${CXBXR_ROOT_DIR}/src/devices/ADM1032Device.h" "${CXBXR_ROOT_DIR}/src/devices/EEPROMDevice.h" - "${CXBXR_ROOT_DIR}/src/devices/EmuNVNet.h" + "${CXBXR_ROOT_DIR}/src/devices/network/NVNetDevice.h" "${CXBXR_ROOT_DIR}/src/devices/LED.h" "${CXBXR_ROOT_DIR}/src/devices/MCPXDevice.h" "${CXBXR_ROOT_DIR}/src/devices/PCIBus.h" @@ -328,7 +328,7 @@ file (GLOB CXBXR_SOURCE_EMU "${CXBXR_ROOT_DIR}/src/core/kernel/support/EmuNtDll.cpp" "${CXBXR_ROOT_DIR}/src/devices/ADM1032Device.cpp" "${CXBXR_ROOT_DIR}/src/devices/EEPROMDevice.cpp" - "${CXBXR_ROOT_DIR}/src/devices/EmuNVNet.cpp" + "${CXBXR_ROOT_DIR}/src/devices/network/NVNetDevice.cpp" "${CXBXR_ROOT_DIR}/src/devices/MCPXDevice.cpp" "${CXBXR_ROOT_DIR}/src/devices/PCIBus.cpp" "${CXBXR_ROOT_DIR}/src/devices/PCIDevice.cpp" diff --git a/src/CxbxLoader/CxbxEmulator.cpp b/src/CxbxLoader/CxbxEmulator.cpp deleted file mode 100644 index 1bfdfc657..000000000 --- a/src/CxbxLoader/CxbxEmulator.cpp +++ /dev/null @@ -1,75 +0,0 @@ -// This is an open source non-commercial project. Dear PVS-Studio, please check it. -// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com -// ****************************************************************** -// * -// * .,-::::: .,:: .::::::::. .,:: .: -// * ,;;;'````' `;;;, .,;; ;;;'';;' `;;;, .,;; -// * [[[ '[[,,[[' [[[__[[\. '[[,,[[' -// * $$$ Y$$$P $$""""Y$$ Y$$$P -// * `88bo,__,o, oP"``"Yo, _88o,,od8P oP"``"Yo, -// * "YUMMMMMP",m" "Mm,""YUMMMP" ,m" "Mm, -// * -// * This file is part of the Cxbx project. -// * -// * Cxbx is free software; you can redistribute it -// * and/or modify it under the terms of the GNU General Public -// * License as published by the Free Software Foundation; either -// * version 2 of the license, or (at your option) any later version. -// * -// * This program is distributed in the hope that it will be useful, -// * but WITHOUT ANY WARRANTY; without even the implied warranty of -// * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// * GNU General Public License for more details. -// * -// * You should have recieved a copy of the GNU General Public License -// * along with this program; see the file COPYING. -// * If not, write to the Free Software Foundation, Inc., -// * 59 Temple Place - Suite 330, Bostom, MA 02111-1307, USA. -// * -// * (c) 2017-2019 Patrick van Logchem -// * -// * All rights reserved -// * -// ****************************************************************** - -// CxbxEmulator.cpp : Defines the exported functions for the DLL application. - -#include "stdafx.h" -#include "Cxbx.h" - -DWORD WINAPI Emulate() -{ - FUNC_EXPORTS - - /*! verify Cxbx-Loader.exe is loaded to base address 0x00010000 */ - if ((UINT_PTR)GetModuleHandle(nullptr) != CXBX_BASE_ADDR) - { - /*! CXBX_BASE_ADDR is defined as 0x00010000, which is the base address of - the Cxbx-Loader.exe host executable. - Set in Cxbx-Loader.exe Project options, Linker, Advanced, Base Address */ - MessageBox(NULL, "Cxbx-Loader.exe was not loaded to base address 0x00010000 (which is a requirement for Xbox emulation)", "Cxbx-Reloaded", MB_OK); - return 1; - } - - /* Initialize Cxbx File Paths */ - CxbxInitFilePaths(); - - /*! initialize shared memory */ - if (!EmuShared::Init()) { - MessageBox(NULL, "Could not map shared memory!", "Cxbx-Reloaded", MB_OK); - return 1; - } - - LPSTR CommandLine = GetCommandLine(); - int argc; - PCHAR *argv = CommandLineToArgvA(CommandLine, &argc); - - CxbxKrnlMain(argc, argv); - - LocalFree(argv); - - /*! cleanup shared memory */ - EmuShared::Cleanup(); - - return 0; -} diff --git a/src/common/XADPCM.h b/src/common/audio/XADPCM.h similarity index 100% rename from src/common/XADPCM.h rename to src/common/audio/XADPCM.h diff --git a/src/core/hle/DSOUND/DirectSound/DirectSoundInline.hpp b/src/core/hle/DSOUND/DirectSound/DirectSoundInline.hpp index a4ae45224..66c6a2714 100644 --- a/src/core/hle/DSOUND/DirectSound/DirectSoundInline.hpp +++ b/src/core/hle/DSOUND/DirectSound/DirectSoundInline.hpp @@ -29,7 +29,7 @@ #include #include -#include "common/XADPCM.h" +#include "common/audio/XADPCM.h" #include "core/hle/DSOUND/XbDSoundTypes.h" #include "core/hle/DSOUND/common/windows/WFXformat.hpp" diff --git a/src/devices/Xbox.h b/src/devices/Xbox.h index 462d8e961..46a9ca650 100644 --- a/src/devices/Xbox.h +++ b/src/devices/Xbox.h @@ -31,7 +31,7 @@ #include "MCPXDevice.h" // For MCPXDevice #include "SMCDevice.h" // For SMCDevice #include "EEPROMDevice.h" // For EEPROMDevice -#include "EmuNVNet.h" // For NVNetDevice +#include "network/NVNetDevice.h" // For NVNetDevice #include "ADM1032Device.h" // For ADM1032 #include "devices\video\nv2a.h" // For NV2ADevice #include "Usb\USBDevice.h" // For USBDevice diff --git a/src/devices/EmuNVNet.cpp b/src/devices/network/NVNetDevice.cpp similarity index 99% rename from src/devices/EmuNVNet.cpp rename to src/devices/network/NVNetDevice.cpp index 33552a451..34841e789 100644 --- a/src/devices/EmuNVNet.cpp +++ b/src/devices/network/NVNetDevice.cpp @@ -40,7 +40,7 @@ #include "core\kernel\exports\EmuKrnl.h" #include "EmuShared.h" #include "devices\Xbox.h" -#include "EmuNVNet.h" +#include "NVNetDevice.h" #include #include #include diff --git a/src/devices/EmuNVNet.h b/src/devices/network/NVNetDevice.h similarity index 99% rename from src/devices/EmuNVNet.h rename to src/devices/network/NVNetDevice.h index a73311c98..d2a069396 100644 --- a/src/devices/EmuNVNet.h +++ b/src/devices/network/NVNetDevice.h @@ -26,7 +26,7 @@ #include -#include "PCIDevice.h" // For PCIDevice +#include "../PCIDevice.h" // For PCIDevice // NVNET Register Definitions // Taken from XQEMU