gallium/tgsi: Add resource write-back support.

Define a new STORE opcode with a role dual to the LOAD opcode, and add
flags to specify that a shader resource is intended for writing.
This commit is contained in:
Francisco Jerez
2012-04-30 20:20:29 +02:00
parent 82c90b2da8
commit b8e808f1ef
8 changed files with 45 additions and 4 deletions

View File

@@ -170,7 +170,8 @@ struct tgsi_declaration_semantic
struct tgsi_declaration_resource {
unsigned Resource : 8; /**< one of TGSI_TEXTURE_ */
unsigned Raw : 1;
unsigned Padding : 23;
unsigned Writable : 1;
unsigned Padding : 22;
};
struct tgsi_declaration_sampler_view {
@@ -406,8 +407,9 @@ struct tgsi_property_data {
#define TGSI_OPCODE_ISSG 160
#define TGSI_OPCODE_LOAD 161
#define TGSI_OPCODE_STORE 162
#define TGSI_OPCODE_LAST 162
#define TGSI_OPCODE_LAST 163
#define TGSI_SAT_NONE 0 /* do not saturate */
#define TGSI_SAT_ZERO_ONE 1 /* clamp to [0,1] */