Core: Add resources file

Currently includes a crosshair icon.
This commit is contained in:
Connor McLaughlin 2020-07-01 00:35:02 +10:00
parent ed6065d7f5
commit f0c1dfefe7
5 changed files with 1049 additions and 0 deletions

View file

@ -64,6 +64,8 @@ add_library(core
playstation_mouse.h
psf_loader.cpp
psf_loader.h
resources.cpp
resources.h
save_state_version.h
settings.cpp
settings.h

View file

@ -82,6 +82,7 @@
<ClCompile Include="controller.cpp" />
<ClCompile Include="playstation_mouse.cpp" />
<ClCompile Include="psf_loader.cpp" />
<ClCompile Include="resources.cpp" />
<ClCompile Include="settings.cpp" />
<ClCompile Include="sio.cpp" />
<ClCompile Include="spu.cpp" />
@ -126,6 +127,7 @@
<ClInclude Include="controller.h" />
<ClInclude Include="playstation_mouse.h" />
<ClInclude Include="psf_loader.h" />
<ClInclude Include="resources.h" />
<ClInclude Include="save_state_version.h" />
<ClInclude Include="settings.h" />
<ClInclude Include="sio.h" />

View file

@ -45,6 +45,7 @@
<ClCompile Include="playstation_mouse.cpp" />
<ClCompile Include="negcon.cpp" />
<ClCompile Include="gpu_hw_vulkan.cpp" />
<ClCompile Include="resources.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="types.h" />
@ -91,6 +92,7 @@
<ClInclude Include="playstation_mouse.h" />
<ClInclude Include="negcon.h" />
<ClInclude Include="gpu_hw_vulkan.h" />
<ClInclude Include="resources.h" />
</ItemGroup>
<ItemGroup>
<None Include="cpu_core.inl" />

1031
src/core/resources.cpp Normal file

File diff suppressed because it is too large Load diff

12
src/core/resources.h Normal file
View file

@ -0,0 +1,12 @@
#pragma once
#include "types.h"
#include <array>
namespace Resources {
// Adapted from https://icons8.com/icon/15970/target
constexpr u32 CROSSHAIR_IMAGE_WIDTH = 96;
constexpr u32 CROSSHAIR_IMAGE_HEIGHT = 96;
extern const std::array<u32, CROSSHAIR_IMAGE_WIDTH * CROSSHAIR_IMAGE_HEIGHT> CROSSHAIR_IMAGE_DATA;
} // namespace Resources