mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-08-02 23:42:43 +00:00
Testing Shaders
This commit is contained in:
parent
270e89c3ea
commit
148e1dcfdc
@ -6,7 +6,6 @@
|
|||||||
"configurationType": "Release",
|
"configurationType": "Release",
|
||||||
"buildRoot": "${projectDir}\\Build\\${name}",
|
"buildRoot": "${projectDir}\\Build\\${name}",
|
||||||
"installRoot": "${projectDir}\\Install\\${name}",
|
"installRoot": "${projectDir}\\Install\\${name}",
|
||||||
"cmakeCommandArgs": "",
|
|
||||||
"buildCommandArgs": "",
|
"buildCommandArgs": "",
|
||||||
"ctestCommandArgs": "",
|
"ctestCommandArgs": "",
|
||||||
"inheritEnvironments": [ "clang_cl_x64_x64" ]
|
"inheritEnvironments": [ "clang_cl_x64_x64" ]
|
||||||
|
@ -14,7 +14,6 @@ constexpr std::size_t MaxDisplayBuffers = 16;
|
|||||||
constexpr std::size_t MaxDisplayBufferGroups = 4;
|
constexpr std::size_t MaxDisplayBufferGroups = 4;
|
||||||
|
|
||||||
enum class PixelFormat : u32 {
|
enum class PixelFormat : u32 {
|
||||||
Unknown,
|
|
||||||
A8R8G8B8Srgb = 0x80000000,
|
A8R8G8B8Srgb = 0x80000000,
|
||||||
A8B8G8R8Srgb = 0x80002200,
|
A8B8G8R8Srgb = 0x80002200,
|
||||||
A2R10G10B10 = 0x88060000,
|
A2R10G10B10 = 0x88060000,
|
||||||
@ -28,7 +27,7 @@ enum class TilingMode : s32 {
|
|||||||
Linear = 1,
|
Linear = 1,
|
||||||
};
|
};
|
||||||
|
|
||||||
constexpr std::string_view GetPixelFormatString(PixelFormat format) {
|
constexpr fmt::string_view GetPixelFormatString(PixelFormat format) {
|
||||||
switch (format) {
|
switch (format) {
|
||||||
case PixelFormat::A8R8G8B8Srgb:
|
case PixelFormat::A8R8G8B8Srgb:
|
||||||
return "A8R8G8B8Srgb";
|
return "A8R8G8B8Srgb";
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
namespace Loader {
|
namespace Loader {
|
||||||
|
|
||||||
constexpr static u32 PkgMagic = 0x544e437f;
|
static constexpr u32 PkgMagic = 0x544e437f;
|
||||||
|
|
||||||
enum class FileTypes {
|
enum class FileTypes {
|
||||||
Unknown,
|
Unknown,
|
||||||
|
@ -77,7 +77,7 @@ struct Buffer {
|
|||||||
return GetStride() * num_records;
|
return GetStride() * num_records;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
static_assert(sizeof(Buffer) == 16); // 128bits
|
static_assert (sizeof(Buffer) == 16); // 256bits
|
||||||
|
|
||||||
enum class ImageType : u64 {
|
enum class ImageType : u64 {
|
||||||
Invalid = 0,
|
Invalid = 0,
|
||||||
@ -91,7 +91,7 @@ enum class ImageType : u64 {
|
|||||||
Color2DMsaaArray = 15,
|
Color2DMsaaArray = 15,
|
||||||
};
|
};
|
||||||
|
|
||||||
constexpr std::string_view NameOf(ImageType type) {
|
constexpr fmt::string_view NameOf(ImageType type) {
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case ImageType::Invalid:
|
case ImageType::Invalid:
|
||||||
return "Invalid";
|
return "Invalid";
|
||||||
@ -124,7 +124,7 @@ enum class TilingMode : u32 {
|
|||||||
Texture_MacroTiled = 0xEu,
|
Texture_MacroTiled = 0xEu,
|
||||||
};
|
};
|
||||||
|
|
||||||
constexpr std::string_view NameOf(TilingMode type) {
|
constexpr fmt::string_view NameOf(TilingMode type) {
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case TilingMode::Depth_MacroTiled:
|
case TilingMode::Depth_MacroTiled:
|
||||||
return "Depth_MacroTiled";
|
return "Depth_MacroTiled";
|
||||||
@ -134,8 +134,7 @@ constexpr std::string_view NameOf(TilingMode type) {
|
|||||||
return "Display_MacroTiled";
|
return "Display_MacroTiled";
|
||||||
case TilingMode::Texture_MicroTiled:
|
case TilingMode::Texture_MicroTiled:
|
||||||
return "Texture_MicroTiled";
|
return "Texture_MicroTiled";
|
||||||
case TilingMode::Texture_MacroTiled:
|
|
||||||
return "Texture_MacroTiled";
|
|
||||||
default:
|
default:
|
||||||
return "Unknown";
|
return "Unknown";
|
||||||
}
|
}
|
||||||
|
@ -179,7 +179,9 @@ const ComputePipeline* PipelineCache::GetComputePipeline() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool ShouldSkipShader(u64 shader_hash, const char* shader_type) {
|
bool ShouldSkipShader(u64 shader_hash, const char* shader_type) {
|
||||||
static constexpr std::array<u64, 0> skip_hashes = {};
|
static constexpr std::array<u32, 13> skip_hashes = {
|
||||||
|
0xa509af23, 0x42f2a521, 0x34d212e1, 0xa954e79d, 0x8634b077, 0x2da7fe60, 0xc1f28ebe, 0xb30dd24a, 0xc0cbc309, 0x8e3f8dc4,
|
||||||
|
0xb6e87124, 0x4ca76892, 0xc1f28ebe};
|
||||||
if (std::ranges::contains(skip_hashes, shader_hash)) {
|
if (std::ranges::contains(skip_hashes, shader_hash)) {
|
||||||
LOG_WARNING(Render_Vulkan, "Skipped {} shader hash {:#x}.", shader_type, shader_hash);
|
LOG_WARNING(Render_Vulkan, "Skipped {} shader hash {:#x}.", shader_type, shader_hash);
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user