Move utility classes from common to own static lib

This commit is contained in:
Connor McLaughlin 2022-07-08 22:43:38 +10:00
parent d2ca454576
commit b7fbde31a7
101 changed files with 371 additions and 282 deletions

View file

@ -14,16 +14,14 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "common", "src\common\common
{7F909E29-4808-4BD9-A60C-56C51A3AAEC2} = {7F909E29-4808-4BD9-A60C-56C51A3AAEC2} {7F909E29-4808-4BD9-A60C-56C51A3AAEC2} = {7F909E29-4808-4BD9-A60C-56C51A3AAEC2}
{43540154-9E1E-409C-834F-B84BE5621388} = {43540154-9E1E-409C-834F-B84BE5621388} {43540154-9E1E-409C-834F-B84BE5621388} = {43540154-9E1E-409C-834F-B84BE5621388}
{ED601289-AC1A-46B8-A8ED-17DB9EB73423} = {ED601289-AC1A-46B8-A8ED-17DB9EB73423} {ED601289-AC1A-46B8-A8ED-17DB9EB73423} = {ED601289-AC1A-46B8-A8ED-17DB9EB73423}
{425D6C99-D1C8-43C2-B8AC-4D7B1D941017} = {425D6C99-D1C8-43C2-B8AC-4D7B1D941017}
{8BDA439C-6358-45FB-9994-2FF083BABE06} = {8BDA439C-6358-45FB-9994-2FF083BABE06} {8BDA439C-6358-45FB-9994-2FF083BABE06} = {8BDA439C-6358-45FB-9994-2FF083BABE06}
{7FF9FDB9-D504-47DB-A16A-B08071999620} = {7FF9FDB9-D504-47DB-A16A-B08071999620} {7FF9FDB9-D504-47DB-A16A-B08071999620} = {7FF9FDB9-D504-47DB-A16A-B08071999620}
{39F0ADFF-3A84-470D-9CF0-CA49E164F2F3} = {39F0ADFF-3A84-470D-9CF0-CA49E164F2F3}
EndProjectSection EndProjectSection
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "core", "src\core\core.vcxproj", "{868B98C8-65A1-494B-8346-250A73A48C0A}" Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "core", "src\core\core.vcxproj", "{868B98C8-65A1-494B-8346-250A73A48C0A}"
ProjectSection(ProjectDependencies) = postProject ProjectSection(ProjectDependencies) = postProject
{EE054E08-3799-4A59-A422-18259C105FFD} = {EE054E08-3799-4A59-A422-18259C105FFD}
{BB08260F-6FBC-46AF-8924-090EE71360C6} = {BB08260F-6FBC-46AF-8924-090EE71360C6} {BB08260F-6FBC-46AF-8924-090EE71360C6} = {BB08260F-6FBC-46AF-8924-090EE71360C6}
{57F6206D-F264-4B07-BAF8-11B9BBE1F455} = {57F6206D-F264-4B07-BAF8-11B9BBE1F455}
{8906836E-F06E-46E8-B11A-74E5E8C7B8FB} = {8906836E-F06E-46E8-B11A-74E5E8C7B8FB} {8906836E-F06E-46E8-B11A-74E5E8C7B8FB} = {8906836E-F06E-46E8-B11A-74E5E8C7B8FB}
{E4357877-D459-45C7-B8F6-DCBB587BB528} = {E4357877-D459-45C7-B8F6-DCBB587BB528} {E4357877-D459-45C7-B8F6-DCBB587BB528} = {E4357877-D459-45C7-B8F6-DCBB587BB528}
{ED601289-AC1A-46B8-A8ED-17DB9EB73423} = {ED601289-AC1A-46B8-A8ED-17DB9EB73423} {ED601289-AC1A-46B8-A8ED-17DB9EB73423} = {ED601289-AC1A-46B8-A8ED-17DB9EB73423}
@ -101,6 +99,13 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "rainterface", "dep\rainterf
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "fmt", "dep\fmt\fmt.vcxproj", "{8BE398E6-B882-4248-9065-FECC8728E038}" Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "fmt", "dep\fmt\fmt.vcxproj", "{8BE398E6-B882-4248-9065-FECC8728E038}"
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "util", "src\util\util.vcxproj", "{57F6206D-F264-4B07-BAF8-11B9BBE1F455}"
ProjectSection(ProjectDependencies) = postProject
{EE054E08-3799-4A59-A422-18259C105FFD} = {EE054E08-3799-4A59-A422-18259C105FFD}
{425D6C99-D1C8-43C2-B8AC-4D7B1D941017} = {425D6C99-D1C8-43C2-B8AC-4D7B1D941017}
{39F0ADFF-3A84-470D-9CF0-CA49E164F2F3} = {39F0ADFF-3A84-470D-9CF0-CA49E164F2F3}
EndProjectSection
EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|ARM64 = Debug|ARM64 Debug|ARM64 = Debug|ARM64
@ -955,6 +960,42 @@ Global
{8BE398E6-B882-4248-9065-FECC8728E038}.ReleaseUWP|x64.Build.0 = ReleaseUWP|x64 {8BE398E6-B882-4248-9065-FECC8728E038}.ReleaseUWP|x64.Build.0 = ReleaseUWP|x64
{8BE398E6-B882-4248-9065-FECC8728E038}.ReleaseUWP|x86.ActiveCfg = ReleaseUWP|Win32 {8BE398E6-B882-4248-9065-FECC8728E038}.ReleaseUWP|x86.ActiveCfg = ReleaseUWP|Win32
{8BE398E6-B882-4248-9065-FECC8728E038}.ReleaseUWP|x86.Build.0 = ReleaseUWP|Win32 {8BE398E6-B882-4248-9065-FECC8728E038}.ReleaseUWP|x86.Build.0 = ReleaseUWP|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Debug|ARM64.ActiveCfg = Debug|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Debug|ARM64.Build.0 = Debug|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Debug|x64.ActiveCfg = Debug|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Debug|x64.Build.0 = Debug|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Debug|x86.ActiveCfg = Debug|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Debug|x86.Build.0 = Debug|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugFast|ARM64.ActiveCfg = DebugFast|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugFast|ARM64.Build.0 = DebugFast|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugFast|x64.ActiveCfg = DebugFast|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugFast|x64.Build.0 = DebugFast|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugFast|x86.ActiveCfg = DebugFast|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugFast|x86.Build.0 = DebugFast|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugUWP|ARM64.ActiveCfg = DebugUWP|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugUWP|ARM64.Build.0 = DebugUWP|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugUWP|x64.ActiveCfg = DebugUWP|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugUWP|x64.Build.0 = DebugUWP|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugUWP|x86.ActiveCfg = DebugUWP|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.DebugUWP|x86.Build.0 = DebugUWP|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Release|ARM64.ActiveCfg = Release|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Release|ARM64.Build.0 = Release|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Release|x64.ActiveCfg = Release|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Release|x64.Build.0 = Release|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Release|x86.ActiveCfg = Release|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.Release|x86.Build.0 = Release|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseLTCG|ARM64.ActiveCfg = ReleaseLTCG|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseLTCG|ARM64.Build.0 = ReleaseLTCG|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseLTCG|x64.ActiveCfg = ReleaseLTCG|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseLTCG|x64.Build.0 = ReleaseLTCG|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseLTCG|x86.ActiveCfg = ReleaseLTCG|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseLTCG|x86.Build.0 = ReleaseLTCG|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseUWP|ARM64.ActiveCfg = ReleaseUWP|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseUWP|ARM64.Build.0 = ReleaseUWP|ARM64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseUWP|x64.ActiveCfg = ReleaseUWP|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseUWP|x64.Build.0 = ReleaseUWP|x64
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseUWP|x86.ActiveCfg = ReleaseUWP|Win32
{57F6206D-F264-4B07-BAF8-11B9BBE1F455}.ReleaseUWP|x86.Build.0 = ReleaseUWP|Win32
EndGlobalSection EndGlobalSection
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE

View file

@ -1,4 +1,5 @@
add_subdirectory(common) add_subdirectory(common)
add_subdirectory(util)
add_subdirectory(core) add_subdirectory(core)
add_subdirectory(scmversion) add_subdirectory(scmversion)
add_subdirectory(frontend-common) add_subdirectory(frontend-common)

View file

@ -2,34 +2,12 @@ add_library(common
align.h align.h
assert.cpp assert.cpp
assert.h assert.h
audio_stream.cpp
audio_stream.h
bitfield.h bitfield.h
bitutils.h bitutils.h
byte_stream.cpp byte_stream.cpp
byte_stream.h byte_stream.h
cd_image.cpp
cd_image.h
cd_image_bin.cpp
cd_image_cue.cpp
cd_image_chd.cpp
cd_image_device.cpp
cd_image_ecm.cpp
cd_image_hasher.cpp
cd_image_hasher.h
cd_image_m3u.cpp
cd_image_memory.cpp
cd_image_mds.cpp
cd_image_pbp.cpp
cd_image_ppf.cpp
cd_subchannel_replacement.cpp
cd_subchannel_replacement.h
cd_xa.cpp
cd_xa.h
crash_handler.cpp crash_handler.cpp
crash_handler.h crash_handler.h
cue_parser.cpp
cue_parser.h
dimensional_array.h dimensional_array.h
error.cpp error.cpp
error.h error.h
@ -52,10 +30,6 @@ add_library(common
gl/texture.h gl/texture.h
hash_combine.h hash_combine.h
heap_array.h heap_array.h
iso_reader.cpp
iso_reader.h
jit_code_buffer.cpp
jit_code_buffer.h
log.cpp log.cpp
log.h log.h
make_array.h make_array.h
@ -63,23 +37,12 @@ add_library(common
md5_digest.h md5_digest.h
minizip_helpers.cpp minizip_helpers.cpp
minizip_helpers.h minizip_helpers.h
null_audio_stream.cpp
null_audio_stream.h
memory_arena.cpp
memory_arena.h
page_fault_handler.cpp
page_fault_handler.h
path.h path.h
platform.h platform.h
pbp_types.h
progress_callback.cpp progress_callback.cpp
progress_callback.h progress_callback.h
rectangle.h rectangle.h
scope_guard.h scope_guard.h
shiftjis.cpp
shiftjis.h
state_wrapper.cpp
state_wrapper.h
string.cpp string.cpp
string.h string.h
string_util.cpp string_util.cpp
@ -111,8 +74,6 @@ add_library(common
vulkan/texture.h vulkan/texture.h
vulkan/util.cpp vulkan/util.cpp
vulkan/util.h vulkan/util.h
wav_writer.cpp
wav_writer.h
window_info.cpp window_info.cpp
window_info.h window_info.h
) )

View file

@ -2,13 +2,13 @@
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemDefinitionGroup> <ItemDefinitionGroup>
<ClCompile> <ClCompile>
<AdditionalIncludeDirectories>$(SolutionDir)dep\fmt\include;$(SolutionDir)dep\libsamplerate\include;$(SolutionDir)dep\glad\include;$(SolutionDir)dep\vulkan\include;$(SolutionDir)dep\libcue\include;$(SolutionDir)dep\libchdr\include;$(SolutionDir)dep\stb\include;$(SolutionDir)dep\glslang;$(SolutionDir)dep\zlib\include;$(SolutionDir)dep\minizip\include;$(SolutionDir)src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> <AdditionalIncludeDirectories>$(SolutionDir)dep\fmt\include;$(SolutionDir)dep\glad\include;$(SolutionDir)dep\vulkan\include;$(SolutionDir)dep\stb\include;$(SolutionDir)dep\glslang;$(SolutionDir)dep\zlib\include;$(SolutionDir)dep\minizip\include;$(SolutionDir)src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile> </ClCompile>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemDefinitionGroup> <ItemDefinitionGroup>
<Link> <Link>
<AdditionalDependencies>$(RootBuildDir)fmt\fmt.lib;$(RootBuildDir)glad\glad.lib;$(RootBuildDir)glslang\glslang.lib;$(RootBuildDir)libchdr\libchdr.lib;$(RootBuildDir)zlib\zlib.lib;$(RootBuildDir)minizip\minizip.lib;$(RootBuildDir)lzma\lzma.lib;$(RootBuildDir)libsamplerate\libsamplerate.lib;d3dcompiler.lib;d3d11.lib;%(AdditionalDependencies)</AdditionalDependencies> <AdditionalDependencies>$(RootBuildDir)fmt\fmt.lib;$(RootBuildDir)glad\glad.lib;$(RootBuildDir)glslang\glslang.lib;$(RootBuildDir)zlib\zlib.lib;$(RootBuildDir)minizip\minizip.lib;$(RootBuildDir)lzma\lzma.lib;d3dcompiler.lib;d3d11.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link> </Link>
</ItemDefinitionGroup> </ItemDefinitionGroup>
</Project> </Project>

View file

@ -4,14 +4,10 @@
<ItemGroup> <ItemGroup>
<ClInclude Include="align.h" /> <ClInclude Include="align.h" />
<ClInclude Include="assert.h" /> <ClInclude Include="assert.h" />
<ClInclude Include="audio_stream.h" />
<ClInclude Include="bitfield.h" /> <ClInclude Include="bitfield.h" />
<ClInclude Include="bitutils.h" /> <ClInclude Include="bitutils.h" />
<ClInclude Include="byte_stream.h" /> <ClInclude Include="byte_stream.h" />
<ClInclude Include="cd_image.h" />
<ClInclude Include="cd_image_hasher.h" />
<ClInclude Include="crash_handler.h" /> <ClInclude Include="crash_handler.h" />
<ClInclude Include="cue_parser.h" />
<ClInclude Include="d3d11\shader_cache.h" /> <ClInclude Include="d3d11\shader_cache.h" />
<ClInclude Include="d3d11\shader_compiler.h" /> <ClInclude Include="d3d11\shader_compiler.h" />
<ClInclude Include="d3d11\staging_texture.h" /> <ClInclude Include="d3d11\staging_texture.h" />
@ -49,24 +45,16 @@
<ExcludedFromBuild Condition="'$(BuildingForUWP)'=='true'">true</ExcludedFromBuild> <ExcludedFromBuild Condition="'$(BuildingForUWP)'=='true'">true</ExcludedFromBuild>
</ClInclude> </ClInclude>
<ClInclude Include="image.h" /> <ClInclude Include="image.h" />
<ClInclude Include="iso_reader.h" />
<ClInclude Include="jit_code_buffer.h" />
<ClInclude Include="log.h" /> <ClInclude Include="log.h" />
<ClInclude Include="lru_cache.h" /> <ClInclude Include="lru_cache.h" />
<ClInclude Include="make_array.h" /> <ClInclude Include="make_array.h" />
<ClInclude Include="md5_digest.h" /> <ClInclude Include="md5_digest.h" />
<ClInclude Include="null_audio_stream.h" />
<ClInclude Include="path.h" /> <ClInclude Include="path.h" />
<ClInclude Include="pbp_types.h" /> <ClInclude Include="pbp_types.h" />
<ClInclude Include="platform.h" /> <ClInclude Include="platform.h" />
<ClInclude Include="progress_callback.h" /> <ClInclude Include="progress_callback.h" />
<ClInclude Include="memory_arena.h" />
<ClInclude Include="page_fault_handler.h" />
<ClInclude Include="rectangle.h" /> <ClInclude Include="rectangle.h" />
<ClInclude Include="cd_subchannel_replacement.h" />
<ClInclude Include="scope_guard.h" /> <ClInclude Include="scope_guard.h" />
<ClInclude Include="shiftjis.h" />
<ClInclude Include="state_wrapper.h" />
<ClInclude Include="string.h" /> <ClInclude Include="string.h" />
<ClInclude Include="string_util.h" /> <ClInclude Include="string_util.h" />
<ClInclude Include="thirdparty\StackWalker.h"> <ClInclude Include="thirdparty\StackWalker.h">
@ -74,7 +62,6 @@
</ClInclude> </ClInclude>
<ClInclude Include="timer.h" /> <ClInclude Include="timer.h" />
<ClInclude Include="types.h" /> <ClInclude Include="types.h" />
<ClInclude Include="cd_xa.h" />
<ClInclude Include="minizip_helpers.h" /> <ClInclude Include="minizip_helpers.h" />
<ClInclude Include="vulkan\builders.h" /> <ClInclude Include="vulkan\builders.h" />
<ClInclude Include="vulkan\context.h" /> <ClInclude Include="vulkan\context.h" />
@ -88,7 +75,6 @@
<ClInclude Include="vulkan\swap_chain.h" /> <ClInclude Include="vulkan\swap_chain.h" />
<ClInclude Include="vulkan\texture.h" /> <ClInclude Include="vulkan\texture.h" />
<ClInclude Include="vulkan\util.h" /> <ClInclude Include="vulkan\util.h" />
<ClInclude Include="wav_writer.h" />
<ClInclude Include="win32_progress_callback.h"> <ClInclude Include="win32_progress_callback.h">
<ExcludedFromBuild Condition="'$(BuildingForUWP)'=='true'">true</ExcludedFromBuild> <ExcludedFromBuild Condition="'$(BuildingForUWP)'=='true'">true</ExcludedFromBuild>
</ClInclude> </ClInclude>
@ -97,22 +83,8 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="assert.cpp" /> <ClCompile Include="assert.cpp" />
<ClCompile Include="audio_stream.cpp" />
<ClCompile Include="byte_stream.cpp" /> <ClCompile Include="byte_stream.cpp" />
<ClCompile Include="cd_image.cpp" />
<ClCompile Include="cd_image_bin.cpp" />
<ClCompile Include="cd_image_chd.cpp" />
<ClCompile Include="cd_image_cue.cpp" />
<ClCompile Include="cd_image_device.cpp" />
<ClCompile Include="cd_image_ecm.cpp" />
<ClCompile Include="cd_image_hasher.cpp" />
<ClCompile Include="cd_image_m3u.cpp" />
<ClCompile Include="cd_image_mds.cpp" />
<ClCompile Include="cd_image_memory.cpp" />
<ClCompile Include="cd_image_pbp.cpp" />
<ClCompile Include="crash_handler.cpp" /> <ClCompile Include="crash_handler.cpp" />
<ClCompile Include="cue_parser.cpp" />
<ClCompile Include="cd_image_ppf.cpp" />
<ClCompile Include="d3d11\shader_cache.cpp" /> <ClCompile Include="d3d11\shader_cache.cpp" />
<ClCompile Include="d3d11\shader_compiler.cpp" /> <ClCompile Include="d3d11\shader_compiler.cpp" />
<ClCompile Include="d3d11\staging_texture.cpp" /> <ClCompile Include="d3d11\staging_texture.cpp" />
@ -144,19 +116,10 @@
<ExcludedFromBuild Condition="'$(BuildingForUWP)'=='true'">true</ExcludedFromBuild> <ExcludedFromBuild Condition="'$(BuildingForUWP)'=='true'">true</ExcludedFromBuild>
</ClCompile> </ClCompile>
<ClCompile Include="image.cpp" /> <ClCompile Include="image.cpp" />
<ClCompile Include="iso_reader.cpp" />
<ClCompile Include="jit_code_buffer.cpp" />
<ClCompile Include="cd_subchannel_replacement.cpp" />
<ClCompile Include="log.cpp" /> <ClCompile Include="log.cpp" />
<ClCompile Include="md5_digest.cpp" /> <ClCompile Include="md5_digest.cpp" />
<ClCompile Include="minizip_helpers.cpp" /> <ClCompile Include="minizip_helpers.cpp" />
<ClCompile Include="null_audio_stream.cpp" />
<ClCompile Include="progress_callback.cpp" /> <ClCompile Include="progress_callback.cpp" />
<ClCompile Include="shiftjis.cpp" />
<ClCompile Include="memory_arena.cpp" />
<ClCompile Include="page_fault_handler.cpp" />
<ClCompile Include="state_wrapper.cpp" />
<ClCompile Include="cd_xa.cpp" />
<ClCompile Include="string.cpp" /> <ClCompile Include="string.cpp" />
<ClCompile Include="string_util.cpp" /> <ClCompile Include="string_util.cpp" />
<ClCompile Include="thirdparty\StackWalker.cpp"> <ClCompile Include="thirdparty\StackWalker.cpp">
@ -174,7 +137,6 @@
<ClCompile Include="vulkan\swap_chain.cpp" /> <ClCompile Include="vulkan\swap_chain.cpp" />
<ClCompile Include="vulkan\texture.cpp" /> <ClCompile Include="vulkan\texture.cpp" />
<ClCompile Include="vulkan\util.cpp" /> <ClCompile Include="vulkan\util.cpp" />
<ClCompile Include="wav_writer.cpp" />
<ClCompile Include="win32_progress_callback.cpp"> <ClCompile Include="win32_progress_callback.cpp">
<ExcludedFromBuild Condition="'$(BuildingForUWP)'=='true'">true</ExcludedFromBuild> <ExcludedFromBuild Condition="'$(BuildingForUWP)'=='true'">true</ExcludedFromBuild>
</ClCompile> </ClCompile>

View file

@ -3,11 +3,7 @@
<ItemGroup> <ItemGroup>
<ClInclude Include="bitfield.h" /> <ClInclude Include="bitfield.h" />
<ClInclude Include="types.h" /> <ClInclude Include="types.h" />
<ClInclude Include="jit_code_buffer.h" />
<ClInclude Include="state_wrapper.h" />
<ClInclude Include="fifo_queue.h" /> <ClInclude Include="fifo_queue.h" />
<ClInclude Include="audio_stream.h" />
<ClInclude Include="cd_xa.h" />
<ClInclude Include="heap_array.h" /> <ClInclude Include="heap_array.h" />
<ClInclude Include="gl\program.h"> <ClInclude Include="gl\program.h">
<Filter>gl</Filter> <Filter>gl</Filter>
@ -31,10 +27,6 @@
<Filter>d3d11</Filter> <Filter>d3d11</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="rectangle.h" /> <ClInclude Include="rectangle.h" />
<ClInclude Include="iso_reader.h" />
<ClInclude Include="cd_image.h" />
<ClInclude Include="cd_subchannel_replacement.h" />
<ClInclude Include="null_audio_stream.h" />
<ClInclude Include="log.h" /> <ClInclude Include="log.h" />
<ClInclude Include="string.h" /> <ClInclude Include="string.h" />
<ClInclude Include="byte_stream.h" /> <ClInclude Include="byte_stream.h" />
@ -49,7 +41,6 @@
</ClInclude> </ClInclude>
<ClInclude Include="hash_combine.h" /> <ClInclude Include="hash_combine.h" />
<ClInclude Include="progress_callback.h" /> <ClInclude Include="progress_callback.h" />
<ClInclude Include="wav_writer.h" />
<ClInclude Include="gl\shader_cache.h"> <ClInclude Include="gl\shader_cache.h">
<Filter>gl</Filter> <Filter>gl</Filter>
</ClInclude> </ClInclude>
@ -62,7 +53,6 @@
<Filter>gl</Filter> <Filter>gl</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="window_info.h" /> <ClInclude Include="window_info.h" />
<ClInclude Include="cd_image_hasher.h" />
<ClInclude Include="vulkan\texture.h"> <ClInclude Include="vulkan\texture.h">
<Filter>vulkan</Filter> <Filter>vulkan</Filter>
</ClInclude> </ClInclude>
@ -99,9 +89,6 @@
<ClInclude Include="minizip_helpers.h" /> <ClInclude Include="minizip_helpers.h" />
<ClInclude Include="win32_progress_callback.h" /> <ClInclude Include="win32_progress_callback.h" />
<ClInclude Include="make_array.h" /> <ClInclude Include="make_array.h" />
<ClInclude Include="shiftjis.h" />
<ClInclude Include="memory_arena.h" />
<ClInclude Include="page_fault_handler.h" />
<ClInclude Include="thirdparty\StackWalker.h"> <ClInclude Include="thirdparty\StackWalker.h">
<Filter>thirdparty</Filter> <Filter>thirdparty</Filter>
</ClInclude> </ClInclude>
@ -111,7 +98,6 @@
<ClInclude Include="pbp_types.h" /> <ClInclude Include="pbp_types.h" />
<ClInclude Include="error.h" /> <ClInclude Include="error.h" />
<ClInclude Include="platform.h" /> <ClInclude Include="platform.h" />
<ClInclude Include="cue_parser.h" />
<ClInclude Include="d3d12\staging_texture.h"> <ClInclude Include="d3d12\staging_texture.h">
<Filter>d3d12</Filter> <Filter>d3d12</Filter>
</ClInclude> </ClInclude>
@ -149,13 +135,6 @@
</ClInclude> </ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="jit_code_buffer.cpp" />
<ClCompile Include="state_wrapper.cpp" />
<ClCompile Include="cd_image.cpp" />
<ClCompile Include="audio_stream.cpp" />
<ClCompile Include="cd_xa.cpp" />
<ClCompile Include="cd_image_cue.cpp" />
<ClCompile Include="cd_image_bin.cpp" />
<ClCompile Include="gl\program.cpp"> <ClCompile Include="gl\program.cpp">
<Filter>gl</Filter> <Filter>gl</Filter>
</ClCompile> </ClCompile>
@ -177,9 +156,6 @@
<ClCompile Include="d3d11\shader_compiler.cpp"> <ClCompile Include="d3d11\shader_compiler.cpp">
<Filter>d3d11</Filter> <Filter>d3d11</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="iso_reader.cpp" />
<ClCompile Include="cd_subchannel_replacement.cpp" />
<ClCompile Include="null_audio_stream.cpp" />
<ClCompile Include="string.cpp" /> <ClCompile Include="string.cpp" />
<ClCompile Include="byte_stream.cpp" /> <ClCompile Include="byte_stream.cpp" />
<ClCompile Include="log.cpp" /> <ClCompile Include="log.cpp" />
@ -191,9 +167,7 @@
<ClCompile Include="d3d11\shader_cache.cpp"> <ClCompile Include="d3d11\shader_cache.cpp">
<Filter>d3d11</Filter> <Filter>d3d11</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="cd_image_chd.cpp" />
<ClCompile Include="progress_callback.cpp" /> <ClCompile Include="progress_callback.cpp" />
<ClCompile Include="wav_writer.cpp" />
<ClCompile Include="gl\shader_cache.cpp"> <ClCompile Include="gl\shader_cache.cpp">
<Filter>gl</Filter> <Filter>gl</Filter>
</ClCompile> </ClCompile>
@ -204,7 +178,6 @@
<ClCompile Include="gl\context.cpp"> <ClCompile Include="gl\context.cpp">
<Filter>gl</Filter> <Filter>gl</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="cd_image_hasher.cpp" />
<ClCompile Include="vulkan\texture.cpp"> <ClCompile Include="vulkan\texture.cpp">
<Filter>vulkan</Filter> <Filter>vulkan</Filter>
</ClCompile> </ClCompile>
@ -236,24 +209,14 @@
<Filter>vulkan</Filter> <Filter>vulkan</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="image.cpp" /> <ClCompile Include="image.cpp" />
<ClCompile Include="cd_image_memory.cpp" />
<ClCompile Include="minizip_helpers.cpp" /> <ClCompile Include="minizip_helpers.cpp" />
<ClCompile Include="win32_progress_callback.cpp" /> <ClCompile Include="win32_progress_callback.cpp" />
<ClCompile Include="shiftjis.cpp" />
<ClCompile Include="memory_arena.cpp" />
<ClCompile Include="page_fault_handler.cpp" />
<ClCompile Include="thirdparty\StackWalker.cpp"> <ClCompile Include="thirdparty\StackWalker.cpp">
<Filter>thirdparty</Filter> <Filter>thirdparty</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="crash_handler.cpp" /> <ClCompile Include="crash_handler.cpp" />
<ClCompile Include="cd_image_ecm.cpp" />
<ClCompile Include="cd_image_mds.cpp" />
<ClCompile Include="cd_image_pbp.cpp" />
<ClCompile Include="error.cpp" /> <ClCompile Include="error.cpp" />
<ClCompile Include="cd_image_m3u.cpp" />
<ClCompile Include="window_info.cpp" /> <ClCompile Include="window_info.cpp" />
<ClCompile Include="cue_parser.cpp" />
<ClCompile Include="cd_image_ppf.cpp" />
<ClCompile Include="d3d12\staging_texture.cpp"> <ClCompile Include="d3d12\staging_texture.cpp">
<Filter>d3d12</Filter> <Filter>d3d12</Filter>
</ClCompile> </ClCompile>
@ -275,7 +238,6 @@
<ClCompile Include="d3d12\shader_cache.cpp"> <ClCompile Include="d3d12\shader_cache.cpp">
<Filter>d3d12</Filter> <Filter>d3d12</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="cd_image_device.cpp" />
<ClCompile Include="http_downloader_winhttp.cpp" /> <ClCompile Include="http_downloader_winhttp.cpp" />
<ClCompile Include="http_downloader.cpp" /> <ClCompile Include="http_downloader.cpp" />
<ClCompile Include="http_downloader_uwp.cpp" /> <ClCompile Include="http_downloader_uwp.cpp" />

View file

@ -120,7 +120,7 @@ set(RECOMPILER_SRCS
target_include_directories(core PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/..") target_include_directories(core PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/..")
target_include_directories(core PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/..") target_include_directories(core PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/..")
target_link_libraries(core PUBLIC Threads::Threads common zlib) target_link_libraries(core PUBLIC Threads::Threads common util zlib)
target_link_libraries(core PRIVATE glad stb xxhash imgui) target_link_libraries(core PRIVATE glad stb xxhash imgui)
if(WIN32) if(WIN32)

View file

@ -1,10 +1,10 @@
#include "analog_controller.h" #include "analog_controller.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "host_interface.h" #include "host_interface.h"
#include "settings.h" #include "settings.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
#include <cmath> #include <cmath>
Log_SetChannel(AnalogController); Log_SetChannel(AnalogController);

View file

@ -1,9 +1,9 @@
#include "analog_joystick.h" #include "analog_joystick.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "host_interface.h" #include "host_interface.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
#include <cmath> #include <cmath>
Log_SetChannel(AnalogJoystick); Log_SetChannel(AnalogJoystick);

View file

@ -4,7 +4,6 @@
#include "common/assert.h" #include "common/assert.h"
#include "common/log.h" #include "common/log.h"
#include "common/make_array.h" #include "common/make_array.h"
#include "common/state_wrapper.h"
#include "cpu_code_cache.h" #include "cpu_code_cache.h"
#include "cpu_core.h" #include "cpu_core.h"
#include "cpu_core_private.h" #include "cpu_core_private.h"
@ -18,6 +17,7 @@
#include "sio.h" #include "sio.h"
#include "spu.h" #include "spu.h"
#include "timers.h" #include "timers.h"
#include "util/state_wrapper.h"
#include <cstdio> #include <cstdio>
#include <tuple> #include <tuple>
#include <utility> #include <utility>

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "common/bitfield.h" #include "common/bitfield.h"
#include "common/memory_arena.h" #include "util/memory_arena.h"
#include "types.h" #include "types.h"
#include <array> #include <array>
#include <bitset> #include <bitset>

View file

@ -1,15 +1,15 @@
#include "cdrom.h" #include "cdrom.h"
#include "common/align.h" #include "common/align.h"
#include "common/cd_image.h"
#include "common/log.h" #include "common/log.h"
#include "common/platform.h" #include "common/platform.h"
#include "common/state_wrapper.h"
#include "dma.h" #include "dma.h"
#include "imgui.h" #include "imgui.h"
#include "interrupt_controller.h" #include "interrupt_controller.h"
#include "settings.h" #include "settings.h"
#include "spu.h" #include "spu.h"
#include "system.h" #include "system.h"
#include "util/cd_image.h"
#include "util/state_wrapper.h"
#include <cmath> #include <cmath>
Log_SetChannel(CDROM); Log_SetChannel(CDROM);

View file

@ -1,11 +1,11 @@
#pragma once #pragma once
#include "cdrom_async_reader.h" #include "cdrom_async_reader.h"
#include "common/bitfield.h" #include "common/bitfield.h"
#include "common/cd_image.h"
#include "common/cd_xa.h"
#include "common/fifo_queue.h" #include "common/fifo_queue.h"
#include "common/heap_array.h" #include "common/heap_array.h"
#include "types.h" #include "types.h"
#include "util/cd_image.h"
#include "util/cd_xa.h"
#include <array> #include <array>
#include <string> #include <string>
#include <string_view> #include <string_view>

View file

@ -1,5 +1,5 @@
#pragma once #pragma once
#include "common/cd_image.h" #include "util/cd_image.h"
#include "types.h" #include "types.h"
#include <array> #include <array>
#include <atomic> #include <atomic>

View file

@ -1,13 +1,11 @@
#include "cheevos.h" #include "cheevos.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/cd_image.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/http_downloader.h" #include "common/http_downloader.h"
#include "common/log.h" #include "common/log.h"
#include "common/md5_digest.h" #include "common/md5_digest.h"
#include "common/path.h" #include "common/path.h"
#include "common/platform.h" #include "common/platform.h"
#include "common/state_wrapper.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "core/bios.h" #include "core/bios.h"
#include "core/bus.h" #include "core/bus.h"
@ -20,6 +18,8 @@
#include "rc_url.h" #include "rc_url.h"
#include "rcheevos.h" #include "rcheevos.h"
#include "scmversion/scmversion.h" #include "scmversion/scmversion.h"
#include "util/cd_image.h"
#include "util/state_wrapper.h"
#include <algorithm> #include <algorithm>
#include <cstdarg> #include <cstdarg>
#include <cstdlib> #include <cstdlib>

View file

@ -1,11 +1,11 @@
#include "controller.h" #include "controller.h"
#include "analog_controller.h" #include "analog_controller.h"
#include "analog_joystick.h" #include "analog_joystick.h"
#include "common/state_wrapper.h"
#include "digital_controller.h" #include "digital_controller.h"
#include "namco_guncon.h" #include "namco_guncon.h"
#include "negcon.h" #include "negcon.h"
#include "playstation_mouse.h" #include "playstation_mouse.h"
#include "util/state_wrapper.h"
Controller::Controller() = default; Controller::Controller() = default;

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\common\common.props" /> <Import Project="..\util\util.props" />
<ItemDefinitionGroup> <ItemDefinitionGroup>
<ClCompile> <ClCompile>
@ -19,7 +19,7 @@
<ItemDefinitionGroup> <ItemDefinitionGroup>
<Lib> <Lib>
<AdditionalDependencies>$(RootBuildDir)rcheevos\rcheevos.lib;$(RootBuildDir)imgui\imgui.lib;$(RootBuildDir)stb\stb.lib;$(RootBuildDir)xxhash\xxhash.lib;$(RootBuildDir)zlib\zlib.lib;$(RootBuildDir)common\common.lib;%(AdditionalDependencies)</AdditionalDependencies> <AdditionalDependencies>$(RootBuildDir)rcheevos\rcheevos.lib;$(RootBuildDir)imgui\imgui.lib;$(RootBuildDir)stb\stb.lib;$(RootBuildDir)xxhash\xxhash.lib;$(RootBuildDir)zlib\zlib.lib;$(RootBuildDir)util\util.lib;$(RootBuildDir)common\common.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies Condition="('$(BuildingForUWP)'!='true' And '$(Platform)'!='ARM64')">$(RootBuildDir)rainterface\rainterface.lib;%(AdditionalDependencies)</AdditionalDependencies> <AdditionalDependencies Condition="('$(BuildingForUWP)'!='true' And '$(Platform)'!='ARM64')">$(RootBuildDir)rainterface\rainterface.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies Condition="'$(Platform)'=='ARM64'">$(RootBuildDir)vixl\vixl.lib;%(AdditionalDependencies)</AdditionalDependencies> <AdditionalDependencies Condition="'$(Platform)'=='ARM64'">$(RootBuildDir)vixl\vixl.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Lib> </Lib>

View file

@ -1,9 +1,9 @@
#pragma once #pragma once
#include "bus.h" #include "bus.h"
#include "common/bitfield.h" #include "common/bitfield.h"
#include "common/jit_code_buffer.h"
#include "common/page_fault_handler.h"
#include "cpu_types.h" #include "cpu_types.h"
#include "util/jit_code_buffer.h"
#include "util/page_fault_handler.h"
#include <array> #include <array>
#include <map> #include <map>
#include <memory> #include <memory>
@ -97,10 +97,7 @@ struct CodeBlock
const u32 GetPC() const { return key.GetPC(); } const u32 GetPC() const { return key.GetPC(); }
const u32 GetSizeInBytes() const { return static_cast<u32>(instructions.size()) * sizeof(Instruction); } const u32 GetSizeInBytes() const { return static_cast<u32>(instructions.size()) * sizeof(Instruction); }
const u32 GetStartPageIndex() const { return (key.GetPCPhysicalAddress() / HOST_PAGE_SIZE); } const u32 GetStartPageIndex() const { return (key.GetPCPhysicalAddress() / HOST_PAGE_SIZE); }
const u32 GetEndPageIndex() const const u32 GetEndPageIndex() const { return ((key.GetPCPhysicalAddress() + GetSizeInBytes()) / HOST_PAGE_SIZE); }
{
return ((key.GetPCPhysicalAddress() + GetSizeInBytes()) / HOST_PAGE_SIZE);
}
bool IsInRAM() const bool IsInRAM() const
{ {
// TODO: Constant // TODO: Constant

View file

@ -3,7 +3,6 @@
#include "common/align.h" #include "common/align.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "cpu_core_private.h" #include "cpu_core_private.h"
#include "cpu_disasm.h" #include "cpu_disasm.h"
#include "cpu_recompiler_thunks.h" #include "cpu_recompiler_thunks.h"
@ -13,6 +12,7 @@
#include "settings.h" #include "settings.h"
#include "system.h" #include "system.h"
#include "timing_event.h" #include "timing_event.h"
#include "util/state_wrapper.h"
#include <cstdio> #include <cstdio>
Log_SetChannel(CPU::Core); Log_SetChannel(CPU::Core);

View file

@ -4,7 +4,7 @@
#include <utility> #include <utility>
#include <vector> #include <vector>
#include "common/jit_code_buffer.h" #include "util/jit_code_buffer.h"
#include "cpu_code_cache.h" #include "cpu_code_cache.h"
#include "cpu_recompiler_register_cache.h" #include "cpu_recompiler_register_cache.h"

View file

@ -1,8 +1,8 @@
#include "digital_controller.h" #include "digital_controller.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/state_wrapper.h"
#include "host_interface.h" #include "host_interface.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
DigitalController::DigitalController() = default; DigitalController::DigitalController() = default;

View file

@ -2,7 +2,6 @@
#include "bus.h" #include "bus.h"
#include "cdrom.h" #include "cdrom.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "cpu_code_cache.h" #include "cpu_code_cache.h"
#include "cpu_core.h" #include "cpu_core.h"
@ -13,6 +12,7 @@
#include "pad.h" #include "pad.h"
#include "spu.h" #include "spu.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
Log_SetChannel(DMA); Log_SetChannel(DMA);
static u32 GetAddressMask() static u32 GetAddressMask()

View file

@ -2,7 +2,6 @@
#include "common/file_system.h" #include "common/file_system.h"
#include "common/heap_array.h" #include "common/heap_array.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "dma.h" #include "dma.h"
#include "host_display.h" #include "host_display.h"
@ -13,6 +12,7 @@
#include "stb_image_write.h" #include "stb_image_write.h"
#include "system.h" #include "system.h"
#include "timers.h" #include "timers.h"
#include "util/state_wrapper.h"
#include <cmath> #include <cmath>
Log_SetChannel(GPU); Log_SetChannel(GPU);

View file

@ -1,9 +1,9 @@
#include "gpu_backend.h" #include "gpu_backend.h"
#include "common/align.h" #include "common/align.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/timer.h" #include "common/timer.h"
#include "settings.h" #include "settings.h"
#include "util/state_wrapper.h"
Log_SetChannel(GPUBackend); Log_SetChannel(GPUBackend);
std::unique_ptr<GPUBackend> g_gpu_backend; std::unique_ptr<GPUBackend> g_gpu_backend;

View file

@ -2,13 +2,13 @@
#include "common/align.h" #include "common/align.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "cpu_core.h" #include "cpu_core.h"
#include "gpu_sw_backend.h" #include "gpu_sw_backend.h"
#include "imgui.h" #include "imgui.h"
#include "pgxp.h" #include "pgxp.h"
#include "settings.h" #include "settings.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
#include <cmath> #include <cmath>
#include <sstream> #include <sstream>
#include <tuple> #include <tuple>

View file

@ -2,7 +2,6 @@
#include "common/assert.h" #include "common/assert.h"
#include "common/d3d11/shader_compiler.h" #include "common/d3d11/shader_compiler.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/timer.h" #include "common/timer.h"
#include "gpu_hw_shadergen.h" #include "gpu_hw_shadergen.h"
#include "gpu_sw_backend.h" #include "gpu_sw_backend.h"
@ -10,6 +9,7 @@
#include "host_interface.h" #include "host_interface.h"
#include "shader_cache_version.h" #include "shader_cache_version.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
Log_SetChannel(GPU_HW_D3D11); Log_SetChannel(GPU_HW_D3D11);
GPU_HW_D3D11::GPU_HW_D3D11() = default; GPU_HW_D3D11::GPU_HW_D3D11() = default;

View file

@ -1,13 +1,13 @@
#include "gpu_hw_opengl.h" #include "gpu_hw_opengl.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/timer.h" #include "common/timer.h"
#include "gpu_hw_shadergen.h" #include "gpu_hw_shadergen.h"
#include "host_display.h" #include "host_display.h"
#include "shader_cache_version.h" #include "shader_cache_version.h"
#include "system.h" #include "system.h"
#include "texture_replacements.h" #include "texture_replacements.h"
#include "util/state_wrapper.h"
Log_SetChannel(GPU_HW_OpenGL); Log_SetChannel(GPU_HW_OpenGL);
GPU_HW_OpenGL::GPU_HW_OpenGL() : GPU_HW() {} GPU_HW_OpenGL::GPU_HW_OpenGL() : GPU_HW() {}

View file

@ -2,7 +2,6 @@
#include "common/assert.h" #include "common/assert.h"
#include "common/log.h" #include "common/log.h"
#include "common/scope_guard.h" #include "common/scope_guard.h"
#include "common/state_wrapper.h"
#include "common/timer.h" #include "common/timer.h"
#include "common/vulkan/builders.h" #include "common/vulkan/builders.h"
#include "common/vulkan/context.h" #include "common/vulkan/context.h"
@ -12,6 +11,7 @@
#include "host_display.h" #include "host_display.h"
#include "host_interface.h" #include "host_interface.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
Log_SetChannel(GPU_HW_Vulkan); Log_SetChannel(GPU_HW_Vulkan);
GPU_HW_Vulkan::GPU_HW_Vulkan() = default; GPU_HW_Vulkan::GPU_HW_Vulkan() = default;

View file

@ -1,7 +1,7 @@
#include "gte.h" #include "gte.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/bitutils.h" #include "common/bitutils.h"
#include "common/state_wrapper.h" #include "util/state_wrapper.h"
#include "cpu_core.h" #include "cpu_core.h"
#include "cpu_core_private.h" #include "cpu_core_private.h"
#include "host_display.h" #include "host_display.h"

View file

@ -1,7 +1,6 @@
#include "host_interface.h" #include "host_interface.h"
#include "bios.h" #include "bios.h"
#include "cdrom.h" #include "cdrom.h"
#include "common/audio_stream.h"
#include "common/byte_stream.h" #include "common/byte_stream.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/image.h" #include "common/image.h"
@ -21,6 +20,7 @@
#include "spu.h" #include "spu.h"
#include "system.h" #include "system.h"
#include "texture_replacements.h" #include "texture_replacements.h"
#include "util/audio_stream.h"
#include <cmath> #include <cmath>
#include <cstring> #include <cstring>
#include <cwchar> #include <cwchar>

View file

@ -1,7 +1,7 @@
#include "interrupt_controller.h" #include "interrupt_controller.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "cpu_core.h" #include "cpu_core.h"
#include "util/state_wrapper.h"
Log_SetChannel(InterruptController); Log_SetChannel(InterruptController);
InterruptController g_interrupt_controller; InterruptController g_interrupt_controller;

View file

@ -1,11 +1,11 @@
#include "mdec.h" #include "mdec.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "cpu_core.h" #include "cpu_core.h"
#include "dma.h" #include "dma.h"
#include "imgui.h" #include "imgui.h"
#include "interrupt_controller.h" #include "interrupt_controller.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
Log_SetChannel(MDEC); Log_SetChannel(MDEC);
MDEC g_mdec; MDEC g_mdec;

View file

@ -2,10 +2,10 @@
#include "common/byte_stream.h" #include "common/byte_stream.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "host_interface.h" #include "host_interface.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
#include <cstdio> #include <cstdio>
Log_SetChannel(MemoryCard); Log_SetChannel(MemoryCard);

View file

@ -3,11 +3,11 @@
#include "common/file_system.h" #include "common/file_system.h"
#include "common/log.h" #include "common/log.h"
#include "common/path.h" #include "common/path.h"
#include "common/shiftjis.h"
#include "common/state_wrapper.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "host_interface.h" #include "host_interface.h"
#include "system.h" #include "system.h"
#include "util/shiftjis.h"
#include "util/state_wrapper.h"
#include <algorithm> #include <algorithm>
#include <cstdio> #include <cstdio>
#include <optional> #include <optional>

View file

@ -1,10 +1,10 @@
#include "multitap.h" #include "multitap.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/types.h" #include "common/types.h"
#include "controller.h" #include "controller.h"
#include "memory_card.h" #include "memory_card.h"
#include "pad.h" #include "pad.h"
#include "util/state_wrapper.h"
Log_SetChannel(Multitap); Log_SetChannel(Multitap);
Multitap::Multitap() Multitap::Multitap()

View file

@ -1,8 +1,8 @@
#pragma once #pragma once
#include "common/state_wrapper.h"
#include "common/types.h" #include "common/types.h"
#include "controller.h" #include "controller.h"
#include "memory_card.h" #include "memory_card.h"
#include "util/state_wrapper.h"
#include <array> #include <array>
class Multitap final class Multitap final

View file

@ -1,12 +1,12 @@
#include "namco_guncon.h" #include "namco_guncon.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "gpu.h" #include "gpu.h"
#include "host_display.h" #include "host_display.h"
#include "host_interface.h" #include "host_interface.h"
#include "resources.h" #include "resources.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
#include <array> #include <array>
Log_SetChannel(NamcoGunCon); Log_SetChannel(NamcoGunCon);

View file

@ -1,8 +1,8 @@
#include "negcon.h" #include "negcon.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "host_interface.h" #include "host_interface.h"
#include "util/state_wrapper.h"
#include <array> #include <array>
#include <cmath> #include <cmath>

View file

@ -1,12 +1,12 @@
#include "pad.h" #include "pad.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "controller.h" #include "controller.h"
#include "host_interface.h" #include "host_interface.h"
#include "interrupt_controller.h" #include "interrupt_controller.h"
#include "memory_card.h" #include "memory_card.h"
#include "multitap.h" #include "multitap.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
Log_SetChannel(Pad); Log_SetChannel(Pad);
Pad g_pad; Pad g_pad;

View file

@ -1,11 +1,11 @@
#include "playstation_mouse.h" #include "playstation_mouse.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "gpu.h" #include "gpu.h"
#include "host_display.h" #include "host_display.h"
#include "host_interface.h" #include "host_interface.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
#include <array> #include <array>
Log_SetChannel(PlayStationMouse); Log_SetChannel(PlayStationMouse);

View file

@ -1,10 +1,10 @@
#include "sio.h" #include "sio.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "controller.h" #include "controller.h"
#include "host_interface.h" #include "host_interface.h"
#include "interrupt_controller.h" #include "interrupt_controller.h"
#include "memory_card.h" #include "memory_card.h"
#include "util/state_wrapper.h"
Log_SetChannel(SIO); Log_SetChannel(SIO);
SIO g_sio; SIO g_sio;

View file

@ -1,15 +1,15 @@
#include "spu.h" #include "spu.h"
#include "cdrom.h" #include "cdrom.h"
#include "common/audio_stream.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "common/wav_writer.h"
#include "dma.h" #include "dma.h"
#include "host_interface.h" #include "host_interface.h"
#include "imgui.h" #include "imgui.h"
#include "interrupt_controller.h" #include "interrupt_controller.h"
#include "system.h" #include "system.h"
#include "util/audio_stream.h"
#include "util/state_wrapper.h"
#include "util/wav_writer.h"
Log_SetChannel(SPU); Log_SetChannel(SPU);
SPU g_spu; SPU g_spu;

View file

@ -3,14 +3,11 @@
#include "bus.h" #include "bus.h"
#include "cdrom.h" #include "cdrom.h"
#include "cheats.h" #include "cheats.h"
#include "common/audio_stream.h"
#include "common/error.h" #include "common/error.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/iso_reader.h"
#include "common/log.h" #include "common/log.h"
#include "common/make_array.h" #include "common/make_array.h"
#include "common/path.h" #include "common/path.h"
#include "common/state_wrapper.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "controller.h" #include "controller.h"
#include "cpu_code_cache.h" #include "cpu_code_cache.h"
@ -34,6 +31,9 @@
#include "spu.h" #include "spu.h"
#include "texture_replacements.h" #include "texture_replacements.h"
#include "timers.h" #include "timers.h"
#include "util/audio_stream.h"
#include "util/iso_reader.h"
#include "util/state_wrapper.h"
#include "xxhash.h" #include "xxhash.h"
#include <cctype> #include <cctype>
#include <cinttypes> #include <cinttypes>

View file

@ -1,10 +1,10 @@
#include "timers.h" #include "timers.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "gpu.h" #include "gpu.h"
#include "imgui.h" #include "imgui.h"
#include "interrupt_controller.h" #include "interrupt_controller.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
Log_SetChannel(Timers); Log_SetChannel(Timers);
Timers g_timers; Timers g_timers;

View file

@ -1,10 +1,10 @@
#include "timing_event.h" #include "timing_event.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/log.h" #include "common/log.h"
#include "common/state_wrapper.h"
#include "cpu_core.h" #include "cpu_core.h"
#include "cpu_core_private.h" #include "cpu_core_private.h"
#include "system.h" #include "system.h"
#include "util/state_wrapper.h"
Log_SetChannel(TimingEvents); Log_SetChannel(TimingEvents);
namespace TimingEvents { namespace TimingEvents {

View file

@ -1,7 +1,7 @@
#include "audiosettingswidget.h" #include "audiosettingswidget.h"
#include "common/audio_stream.h"
#include "settingsdialog.h" #include "settingsdialog.h"
#include "settingwidgetbinder.h" #include "settingwidgetbinder.h"
#include "util/audio_stream.h"
#include <cmath> #include <cmath>
AudioSettingsWidget::AudioSettingsWidget(QtHostInterface* host_interface, QWidget* parent, SettingsDialog* dialog) AudioSettingsWidget::AudioSettingsWidget(QtHostInterface* host_interface, QWidget* parent, SettingsDialog* dialog)

View file

@ -1,9 +1,9 @@
#include "consolesettingswidget.h" #include "consolesettingswidget.h"
#include "common/cd_image.h"
#include "core/system.h" #include "core/system.h"
#include "qtutils.h" #include "qtutils.h"
#include "settingsdialog.h" #include "settingsdialog.h"
#include "settingwidgetbinder.h" #include "settingwidgetbinder.h"
#include "util/cd_image.h"
#include <QtWidgets/QMessageBox> #include <QtWidgets/QMessageBox>
ConsoleSettingsWidget::ConsoleSettingsWidget(QtHostInterface* host_interface, QWidget* parent, SettingsDialog* dialog) ConsoleSettingsWidget::ConsoleSettingsWidget(QtHostInterface* host_interface, QWidget* parent, SettingsDialog* dialog)
@ -72,7 +72,8 @@ ConsoleSettingsWidget::ConsoleSettingsWidget(QtHostInterface* host_interface, QW
tr("Selects the percentage of the normal clock speed the emulated hardware will run at.")); tr("Selects the percentage of the normal clock speed the emulated hardware will run at."));
dialog->registerWidgetHelp( dialog->registerWidgetHelp(
m_ui.enable8MBRAM, tr("Enable 8MB RAM (Dev Console)"), tr("Unchecked"), m_ui.enable8MBRAM, tr("Enable 8MB RAM (Dev Console)"), tr("Unchecked"),
tr("Enables an additional 6MB of RAM to obtain a total of 2+6 = 8MB, usually present on dev consoles. Games have to use a larger heap size for " tr("Enables an additional 6MB of RAM to obtain a total of 2+6 = 8MB, usually present on dev consoles. Games have "
"to use a larger heap size for "
"this additional RAM to be usable. Titles which rely on memory mirrors may break, so it should only be used " "this additional RAM to be usable. Titles which rely on memory mirrors may break, so it should only be used "
"with compatible mods.")); "with compatible mods."));
dialog->registerWidgetHelp( dialog->registerWidgetHelp(

View file

@ -1,6 +1,4 @@
#include "gamepropertiesdialog.h" #include "gamepropertiesdialog.h"
#include "common/cd_image.h"
#include "common/cd_image_hasher.h"
#include "common/string_util.h" #include "common/string_util.h"
#include "core/settings.h" #include "core/settings.h"
#include "core/system.h" #include "core/system.h"
@ -11,6 +9,8 @@
#include "qtutils.h" #include "qtutils.h"
#include "rapidjson/document.h" #include "rapidjson/document.h"
#include "scmversion/scmversion.h" #include "scmversion/scmversion.h"
#include "util/cd_image.h"
#include "util/cd_image_hasher.h"
#include <QtGui/QClipboard> #include <QtGui/QClipboard>
#include <QtGui/QGuiApplication> #include <QtGui/QGuiApplication>
#include <QtWidgets/QFileDialog> #include <QtWidgets/QFileDialog>

View file

@ -3,7 +3,6 @@
#include "autoupdaterdialog.h" #include "autoupdaterdialog.h"
#include "cheatmanagerdialog.h" #include "cheatmanagerdialog.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/cd_image.h"
#include "core/host_display.h" #include "core/host_display.h"
#include "core/settings.h" #include "core/settings.h"
#include "core/system.h" #include "core/system.h"
@ -20,6 +19,7 @@
#include "scmversion/scmversion.h" #include "scmversion/scmversion.h"
#include "settingsdialog.h" #include "settingsdialog.h"
#include "settingwidgetbinder.h" #include "settingwidgetbinder.h"
#include "util/cd_image.h"
#ifdef WITH_CHEEVOS #ifdef WITH_CHEEVOS
#include "core/cheevos.h" #include "core/cheevos.h"

View file

@ -1,6 +1,5 @@
#include "qthostinterface.h" #include "qthostinterface.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/audio_stream.h"
#include "common/byte_stream.h" #include "common/byte_stream.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/log.h" #include "common/log.h"
@ -25,6 +24,7 @@
#include "qtdisplaywidget.h" #include "qtdisplaywidget.h"
#include "qtprogresscallback.h" #include "qtprogresscallback.h"
#include "qtutils.h" #include "qtutils.h"
#include "util/audio_stream.h"
#include <QtCore/QCoreApplication> #include <QtCore/QCoreApplication>
#include <QtCore/QDateTime> #include <QtCore/QDateTime>
#include <QtCore/QDebug> #include <QtCore/QDebug>

View file

@ -1,6 +1,5 @@
#include "regtest_host_interface.h" #include "regtest_host_interface.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/audio_stream.h"
#include "common/byte_stream.h" #include "common/byte_stream.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/log.h" #include "common/log.h"
@ -11,6 +10,7 @@
#include "frontend-common/game_settings.h" #include "frontend-common/game_settings.h"
#include "regtest_host_display.h" #include "regtest_host_display.h"
#include "scmversion/scmversion.h" #include "scmversion/scmversion.h"
#include "util/audio_stream.h"
#include <cstdio> #include <cstdio>
Log_SetChannel(RegTestHostInterface); Log_SetChannel(RegTestHostInterface);

View file

@ -1,7 +1,6 @@
#include "common_host_interface.h" #include "common_host_interface.h"
#include "IconsFontAwesome5.h" #include "IconsFontAwesome5.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/audio_stream.h"
#include "common/byte_stream.h" #include "common/byte_stream.h"
#include "common/crash_handler.h" #include "common/crash_handler.h"
#include "common/file_system.h" #include "common/file_system.h"
@ -35,6 +34,7 @@
#include "input_overlay_ui.h" #include "input_overlay_ui.h"
#include "save_state_selector_ui.h" #include "save_state_selector_ui.h"
#include "scmversion/scmversion.h" #include "scmversion/scmversion.h"
#include "util/audio_stream.h"
#include <cmath> #include <cmath>
#include <cstdio> #include <cstdio>
#include <cstring> #include <cstring>

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "common/audio_stream.h"
#include "cubeb/cubeb.h" #include "cubeb/cubeb.h"
#include "util/audio_stream.h"
#include <cstdint> #include <cstdint>
class CubebAudioStream final : public AudioStream class CubebAudioStream final : public AudioStream

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "common/cd_image_hasher.h"
#include "core/types.h" #include "core/types.h"
#include "util/cd_image_hasher.h"
#include <map> #include <map>
#include <string> #include <string>
#include <string_view> #include <string_view>

View file

@ -1,9 +1,7 @@
#include "game_list.h" #include "game_list.h"
#include "common/assert.h" #include "common/assert.h"
#include "common/byte_stream.h" #include "common/byte_stream.h"
#include "common/cd_image.h"
#include "common/file_system.h" #include "common/file_system.h"
#include "common/iso_reader.h"
#include "common/log.h" #include "common/log.h"
#include "common/make_array.h" #include "common/make_array.h"
#include "common/path.h" #include "common/path.h"
@ -14,6 +12,7 @@
#include "core/psf_loader.h" #include "core/psf_loader.h"
#include "core/settings.h" #include "core/settings.h"
#include "core/system.h" #include "core/system.h"
#include "util/cd_image.h"
#include <algorithm> #include <algorithm>
#include <array> #include <array>
#include <cctype> #include <cctype>

View file

@ -1,8 +1,8 @@
#pragma once #pragma once
#include "common/cd_image.h"
#include "core/types.h" #include "core/types.h"
#include "game_database.h" #include "game_database.h"
#include "game_settings.h" #include "game_settings.h"
#include "util/cd_image.h"
#include <ctime> #include <ctime>
#include <memory> #include <memory>
#include <optional> #include <optional>

View file

@ -1,5 +1,5 @@
#pragma once #pragma once
#include "common/audio_stream.h" #include "util/audio_stream.h"
#include <cstdint> #include <cstdint>
class SDLAudioStream final : public AudioStream class SDLAudioStream final : public AudioStream

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "common/audio_stream.h"
#include "common/windows_headers.h" #include "common/windows_headers.h"
#include "util/audio_stream.h"
#include <array> #include <array>
#include <cstdint> #include <cstdint>
#include <memory> #include <memory>

45
src/util/CMakeLists.txt Normal file
View file

@ -0,0 +1,45 @@
add_library(util
audio_stream.cpp
audio_stream.h
cd_image.cpp
cd_image.h
cd_image_bin.cpp
cd_image_cue.cpp
cd_image_chd.cpp
cd_image_device.cpp
cd_image_ecm.cpp
cd_image_hasher.cpp
cd_image_hasher.h
cd_image_m3u.cpp
cd_image_memory.cpp
cd_image_mds.cpp
cd_image_pbp.cpp
cd_image_ppf.cpp
cd_subchannel_replacement.cpp
cd_subchannel_replacement.h
cd_xa.cpp
cd_xa.h
cue_parser.cpp
cue_parser.h
iso_reader.cpp
iso_reader.h
jit_code_buffer.cpp
jit_code_buffer.h
null_audio_stream.cpp
null_audio_stream.h
memory_arena.cpp
memory_arena.h
page_fault_handler.cpp
page_fault_handler.h
shiftjis.cpp
shiftjis.h
state_wrapper.cpp
state_wrapper.h
wav_writer.cpp
wav_writer.h
)
target_include_directories(util PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/..")
target_include_directories(util PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/..")
target_link_libraries(util PUBLIC common)
target_link_libraries(util PRIVATE libchdr samplerate zlib)

View file

@ -1,6 +1,6 @@
#include "audio_stream.h" #include "audio_stream.h"
#include "assert.h" #include "assert.h"
#include "log.h" #include "common/log.h"
#include "samplerate.h" #include "samplerate.h"
#include <algorithm> #include <algorithm>
#include <cstring> #include <cstring>

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "fifo_queue.h" #include "common/fifo_queue.h"
#include "types.h" #include "common/types.h"
#include <atomic> #include <atomic>
#include <condition_variable> #include <condition_variable>
#include <memory> #include <memory>

View file

@ -1,9 +1,9 @@
#include "cd_image.h" #include "cd_image.h"
#include "assert.h" #include "common/assert.h"
#include "file_system.h" #include "common/file_system.h"
#include "log.h" #include "common/log.h"
#include "path.h" #include "common/path.h"
#include "string_util.h" #include "common/string_util.h"
#include <array> #include <array>
Log_SetChannel(CDImage); Log_SetChannel(CDImage);

View file

@ -1,7 +1,7 @@
#pragma once #pragma once
#include "bitfield.h" #include "common/bitfield.h"
#include "progress_callback.h" #include "common/progress_callback.h"
#include "types.h" #include "common/types.h"
#include <array> #include <array>
#include <memory> #include <memory>
#include <string> #include <string>

View file

@ -1,8 +1,8 @@
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "error.h" #include "common/error.h"
#include "file_system.h" #include "common/file_system.h"
#include "log.h" #include "common/log.h"
#include <cerrno> #include <cerrno>
Log_SetChannel(CDImageBin); Log_SetChannel(CDImageBin);

View file

@ -2,15 +2,15 @@
#define _CRT_SECURE_NO_WARNINGS #define _CRT_SECURE_NO_WARNINGS
#endif #endif
#include "align.h"
#include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "error.h" #include "common/align.h"
#include "file_system.h" #include "common/assert.h"
#include "common/error.h"
#include "common/file_system.h"
#include "common/log.h"
#include "common/platform.h"
#include "libchdr/chd.h" #include "libchdr/chd.h"
#include "log.h"
#include "platform.h"
#include <algorithm> #include <algorithm>
#include <cerrno> #include <cerrno>
#include <cstdio> #include <cstdio>

View file

@ -1,11 +1,11 @@
#include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "common/assert.h"
#include "common/error.h"
#include "common/file_system.h"
#include "common/log.h"
#include "common/path.h"
#include "cue_parser.h" #include "cue_parser.h"
#include "error.h"
#include "file_system.h"
#include "log.h"
#include "path.h"
#include <algorithm> #include <algorithm>
#include <cerrno> #include <cerrno>
#include <cinttypes> #include <cinttypes>

View file

@ -1,8 +1,8 @@
#include "assert.h" #include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "error.h" #include "common/error.h"
#include "log.h" #include "common/log.h"
#include "string_util.h" #include "common/string_util.h"
#include <algorithm> #include <algorithm>
#include <cerrno> #include <cerrno>
#include <cinttypes> #include <cinttypes>
@ -57,7 +57,7 @@ static void DeinterleaveSubcode(const u8* subcode_in, u8* subcode_out)
// The include order here is critical. // The include order here is critical.
// clang-format off // clang-format off
#include "windows_headers.h" #include "common/windows_headers.h"
#include <winioctl.h> #include <winioctl.h>
#include <ntddcdrm.h> #include <ntddcdrm.h>
#include <ntddscsi.h> #include <ntddscsi.h>

View file

@ -1,9 +1,9 @@
#include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "error.h" #include "common/assert.h"
#include "file_system.h" #include "common/error.h"
#include "log.h" #include "common/file_system.h"
#include "common/log.h"
#include <array> #include <array>
#include <cerrno> #include <cerrno>
#include <map> #include <map>

View file

@ -1,7 +1,7 @@
#include "cd_image_hasher.h" #include "cd_image_hasher.h"
#include "cd_image.h" #include "cd_image.h"
#include "md5_digest.h" #include "common/md5_digest.h"
#include "string_util.h" #include "common/string_util.h"
namespace CDImageHasher { namespace CDImageHasher {

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "progress_callback.h" #include "common/progress_callback.h"
#include "types.h" #include "common/types.h"
#include <array> #include <array>
#include <optional> #include <optional>
#include <string> #include <string>

View file

@ -1,10 +1,10 @@
#include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "error.h" #include "common/assert.h"
#include "file_system.h" #include "common/error.h"
#include "log.h" #include "common/file_system.h"
#include "path.h" #include "common/log.h"
#include "common/path.h"
#include <algorithm> #include <algorithm>
#include <cerrno> #include <cerrno>
#include <map> #include <map>

View file

@ -1,10 +1,10 @@
#include "assert.h" #include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "error.h" #include "common/error.h"
#include "file_system.h" #include "common/file_system.h"
#include "log.h" #include "common/log.h"
#include "path.h" #include "common/path.h"
#include <algorithm> #include <algorithm>
#include <cerrno> #include <cerrno>
#include <map> #include <map>

View file

@ -1,9 +1,9 @@
#include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "file_system.h" #include "common/assert.h"
#include "log.h" #include "common/file_system.h"
#include "path.h" #include "common/log.h"
#include "common/path.h"
#include <algorithm> #include <algorithm>
#include <cerrno> #include <cerrno>
Log_SetChannel(CDImageMemory); Log_SetChannel(CDImageMemory);

View file

@ -1,13 +1,13 @@
#include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "error.h" #include "common/assert.h"
#include "file_system.h" #include "common/error.h"
#include "log.h" #include "common/file_system.h"
#include "path.h" #include "common/log.h"
#include "common/path.h"
#include "common/string_util.h"
#include "pbp_types.h" #include "pbp_types.h"
#include "string.h" #include "string.h"
#include "string_util.h"
#include "zlib.h" #include "zlib.h"
#include <array> #include <array>
#include <cstdio> #include <cstdio>

View file

@ -1,8 +1,8 @@
#include "assert.h"
#include "cd_image.h" #include "cd_image.h"
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "file_system.h" #include "common/assert.h"
#include "log.h" #include "common/file_system.h"
#include "common/log.h"
#include <algorithm> #include <algorithm>
#include <cerrno> #include <cerrno>
#include <map> #include <map>

View file

@ -1,7 +1,7 @@
#include "cd_subchannel_replacement.h" #include "cd_subchannel_replacement.h"
#include "file_system.h" #include "common/file_system.h"
#include "log.h" #include "common/log.h"
#include "path.h" #include "common/path.h"
#include <algorithm> #include <algorithm>
#include <memory> #include <memory>
Log_SetChannel(CDSubChannelReplacement); Log_SetChannel(CDSubChannelReplacement);

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "cd_image.h" #include "cd_image.h"
#include "types.h" #include "common/types.h"
#include <array> #include <array>
#include <cstdio> #include <cstdio>
#include <unordered_map> #include <unordered_map>

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "bitfield.h" #include "common/bitfield.h"
#include "types.h" #include "common/types.h"
namespace CDXA { namespace CDXA {
enum enum

View file

@ -1,7 +1,7 @@
#include "cue_parser.h" #include "cue_parser.h"
#include "error.h" #include "common/error.h"
#include "log.h" #include "common/log.h"
#include "string_util.h" #include "common/string_util.h"
#include <cstdarg> #include <cstdarg>
Log_SetChannel(CueParser); Log_SetChannel(CueParser);

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "types.h"
#include "cd_image.h" #include "cd_image.h"
#include "common/types.h"
#include <optional> #include <optional>
#include <string_view> #include <string_view>
#include <utility> #include <utility>

View file

@ -1,6 +1,6 @@
#include "iso_reader.h" #include "iso_reader.h"
#include "cd_image.h" #include "cd_image.h"
#include "log.h" #include "common/log.h"
#include <cctype> #include <cctype>
Log_SetChannel(ISOReader); Log_SetChannel(ISOReader);

View file

@ -1,5 +1,5 @@
#pragma once #pragma once
#include "types.h" #include "common/types.h"
#include <memory> #include <memory>
#include <optional> #include <optional>
#include <string> #include <string>

View file

@ -1,13 +1,13 @@
#include "jit_code_buffer.h" #include "jit_code_buffer.h"
#include "align.h" #include "common/align.h"
#include "assert.h" #include "common/assert.h"
#include "log.h" #include "common/log.h"
#include "platform.h" #include "common/platform.h"
#include <algorithm> #include <algorithm>
Log_SetChannel(JitCodeBuffer); Log_SetChannel(JitCodeBuffer);
#if defined(_WIN32) #if defined(_WIN32)
#include "windows_headers.h" #include "common/windows_headers.h"
#else #else
#include <errno.h> #include <errno.h>
#include <sys/mman.h> #include <sys/mman.h>

View file

@ -1,5 +1,5 @@
#pragma once #pragma once
#include "types.h" #include "common/types.h"
class JitCodeBuffer class JitCodeBuffer
{ {

View file

@ -1,5 +1,5 @@
#pragma once #pragma once
#include "types.h" #include "common/types.h"
#include <atomic> #include <atomic>
#include <optional> #include <optional>

View file

@ -1,6 +1,6 @@
#include "page_fault_handler.h" #include "page_fault_handler.h"
#include "log.h" #include "common/log.h"
#include "platform.h" #include "common/platform.h"
#include <algorithm> #include <algorithm>
#include <cstring> #include <cstring>
#include <mutex> #include <mutex>
@ -8,7 +8,7 @@
Log_SetChannel(Common::PageFaultHandler); Log_SetChannel(Common::PageFaultHandler);
#if defined(_WIN32) #if defined(_WIN32)
#include "windows_headers.h" #include "common/windows_headers.h"
#elif defined(__linux__) || defined(__ANDROID__) #elif defined(__linux__) || defined(__ANDROID__)
#include <signal.h> #include <signal.h>
#include <ucontext.h> #include <ucontext.h>

View file

@ -1,5 +1,5 @@
#pragma once #pragma once
#include "types.h" #include "common/types.h"
namespace Common::PageFaultHandler { namespace Common::PageFaultHandler {
enum class HandlerResult enum class HandlerResult

View file

@ -1,5 +1,5 @@
#pragma once #pragma once
#include "types.h" #include "common/types.h"
#include <map> #include <map>
#include <string> #include <string>
#include <variant> #include <variant>

View file

@ -1,6 +1,6 @@
#include "state_wrapper.h" #include "state_wrapper.h"
#include "log.h" #include "common/log.h"
#include "string.h" #include "common/string.h"
#include <cinttypes> #include <cinttypes>
#include <cstring> #include <cstring>
Log_SetChannel(StateWrapper); Log_SetChannel(StateWrapper);

View file

@ -1,8 +1,8 @@
#pragma once #pragma once
#include "byte_stream.h" #include "common/byte_stream.h"
#include "fifo_queue.h" #include "common/fifo_queue.h"
#include "heap_array.h" #include "common/heap_array.h"
#include "types.h" #include "common/types.h"
#include <cstring> #include <cstring>
#include <deque> #include <deque>
#include <string> #include <string>

16
src/util/util.props Normal file
View file

@ -0,0 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\common\common.props" />
<ItemDefinitionGroup>
<ClCompile>
<AdditionalIncludeDirectories>$(SolutionDir)dep\libsamplerate\include;$(SolutionDir)dep\libchdr\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
</ItemDefinitionGroup>
<ItemDefinitionGroup>
<Link>
<AdditionalDependencies>$(RootBuildDir)libchdr\libchdr.lib;$(RootBuildDir)libsamplerate\libsamplerate.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
</Project>

58
src/util/util.vcxproj Normal file
View file

@ -0,0 +1,58 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\..\dep\msvc\vsprops\Configurations.props" />
<ItemGroup>
<ClInclude Include="audio_stream.h" />
<ClInclude Include="cd_image.h" />
<ClInclude Include="cd_image_hasher.h" />
<ClInclude Include="cue_parser.h" />
<ClInclude Include="iso_reader.h" />
<ClInclude Include="jit_code_buffer.h" />
<ClInclude Include="null_audio_stream.h" />
<ClInclude Include="pbp_types.h" />
<ClInclude Include="memory_arena.h" />
<ClInclude Include="page_fault_handler.h" />
<ClInclude Include="cd_subchannel_replacement.h" />
<ClInclude Include="shiftjis.h" />
<ClInclude Include="state_wrapper.h" />
<ClInclude Include="cd_xa.h" />
<ClInclude Include="wav_writer.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="audio_stream.cpp" />
<ClCompile Include="cd_image.cpp" />
<ClCompile Include="cd_image_bin.cpp" />
<ClCompile Include="cd_image_chd.cpp" />
<ClCompile Include="cd_image_cue.cpp" />
<ClCompile Include="cd_image_device.cpp" />
<ClCompile Include="cd_image_ecm.cpp" />
<ClCompile Include="cd_image_hasher.cpp" />
<ClCompile Include="cd_image_m3u.cpp" />
<ClCompile Include="cd_image_mds.cpp" />
<ClCompile Include="cd_image_memory.cpp" />
<ClCompile Include="cd_image_pbp.cpp" />
<ClCompile Include="cue_parser.cpp" />
<ClCompile Include="cd_image_ppf.cpp" />
<ClCompile Include="iso_reader.cpp" />
<ClCompile Include="jit_code_buffer.cpp" />
<ClCompile Include="cd_subchannel_replacement.cpp" />
<ClCompile Include="null_audio_stream.cpp" />
<ClCompile Include="shiftjis.cpp" />
<ClCompile Include="memory_arena.cpp" />
<ClCompile Include="page_fault_handler.cpp" />
<ClCompile Include="state_wrapper.cpp" />
<ClCompile Include="cd_xa.cpp" />
<ClCompile Include="wav_writer.cpp" />
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{57F6206D-F264-4B07-BAF8-11B9BBE1F455}</ProjectGuid>
</PropertyGroup>
<Import Project="..\..\dep\msvc\vsprops\StaticLibrary.props" />
<Import Project="util.props" />
<ItemDefinitionGroup>
<ClCompile>
<ObjectFileName>$(IntDir)/%(RelativeDir)/</ObjectFileName>
</ClCompile>
</ItemDefinitionGroup>
<Import Project="..\..\dep\msvc\vsprops\Targets.props" />
</Project>

View file

@ -0,0 +1,46 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<ClInclude Include="jit_code_buffer.h" />
<ClInclude Include="state_wrapper.h" />
<ClInclude Include="audio_stream.h" />
<ClInclude Include="cd_xa.h" />
<ClInclude Include="iso_reader.h" />
<ClInclude Include="cd_image.h" />
<ClInclude Include="cd_subchannel_replacement.h" />
<ClInclude Include="null_audio_stream.h" />
<ClInclude Include="wav_writer.h" />
<ClInclude Include="cd_image_hasher.h" />
<ClInclude Include="shiftjis.h" />
<ClInclude Include="memory_arena.h" />
<ClInclude Include="page_fault_handler.h" />
<ClInclude Include="pbp_types.h" />
<ClInclude Include="cue_parser.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="jit_code_buffer.cpp" />
<ClCompile Include="state_wrapper.cpp" />
<ClCompile Include="cd_image.cpp" />
<ClCompile Include="audio_stream.cpp" />
<ClCompile Include="cd_xa.cpp" />
<ClCompile Include="cd_image_cue.cpp" />
<ClCompile Include="cd_image_bin.cpp" />
<ClCompile Include="iso_reader.cpp" />
<ClCompile Include="cd_subchannel_replacement.cpp" />
<ClCompile Include="null_audio_stream.cpp" />
<ClCompile Include="cd_image_chd.cpp" />
<ClCompile Include="wav_writer.cpp" />
<ClCompile Include="cd_image_hasher.cpp" />
<ClCompile Include="cd_image_memory.cpp" />
<ClCompile Include="shiftjis.cpp" />
<ClCompile Include="memory_arena.cpp" />
<ClCompile Include="page_fault_handler.cpp" />
<ClCompile Include="cd_image_ecm.cpp" />
<ClCompile Include="cd_image_mds.cpp" />
<ClCompile Include="cd_image_pbp.cpp" />
<ClCompile Include="cd_image_m3u.cpp" />
<ClCompile Include="cue_parser.cpp" />
<ClCompile Include="cd_image_ppf.cpp" />
<ClCompile Include="cd_image_device.cpp" />
</ItemGroup>
</Project>

View file

@ -1,6 +1,6 @@
#include "wav_writer.h" #include "wav_writer.h"
#include "file_system.h" #include "common/file_system.h"
#include "log.h" #include "common/log.h"
Log_SetChannel(WAVWriter); Log_SetChannel(WAVWriter);
#pragma pack(push, 1) #pragma pack(push, 1)

Some files were not shown because too many files have changed in this diff Show more