mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-12-13 07:08:49 +00:00
video_core: Add image support
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
#include "shader_recompiler/ir/attribute.h"
|
||||
#include "shader_recompiler/ir/reg.h"
|
||||
#include "shader_recompiler/ir/type.h"
|
||||
#include "video_core/amdgpu/pixel_format.h"
|
||||
#include "video_core/amdgpu/resource.h"
|
||||
|
||||
namespace Shader {
|
||||
|
||||
@@ -53,6 +53,22 @@ struct BufferResource {
|
||||
};
|
||||
using BufferResourceList = boost::container::static_vector<BufferResource, 8>;
|
||||
|
||||
struct ImageResource {
|
||||
u32 sgpr_base;
|
||||
u32 dword_offset;
|
||||
AmdGpu::ImageType type;
|
||||
AmdGpu::NumberFormat nfmt;
|
||||
bool is_storage;
|
||||
bool is_depth;
|
||||
};
|
||||
using ImageResourceList = boost::container::static_vector<ImageResource, 8>;
|
||||
|
||||
struct SamplerResource {
|
||||
u32 sgpr_base;
|
||||
u32 dword_offset;
|
||||
};
|
||||
using SamplerResourceList = boost::container::static_vector<SamplerResource, 8>;
|
||||
|
||||
struct Info {
|
||||
struct VsInput {
|
||||
AmdGpu::NumberFormat fmt;
|
||||
@@ -101,6 +117,9 @@ struct Info {
|
||||
AttributeFlags stores{};
|
||||
|
||||
BufferResourceList buffers;
|
||||
ImageResourceList images;
|
||||
SamplerResourceList samplers;
|
||||
|
||||
std::span<const u32> user_data;
|
||||
Stage stage;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user