shader: Implement TEXS
This commit is contained in:
parent
71f96fa636
commit
17a82b56d7
8 changed files with 287 additions and 7 deletions
|
@ -512,6 +512,14 @@ Value IREmitter::UnpackFloat2x16(const U32& value) {
|
|||
return Inst(Opcode::UnpackFloat2x16, value);
|
||||
}
|
||||
|
||||
U32 IREmitter::PackHalf2x16(const Value& vector) {
|
||||
return Inst<U32>(Opcode::PackHalf2x16, vector);
|
||||
}
|
||||
|
||||
Value IREmitter::UnpackHalf2x16(const U32& value) {
|
||||
return Inst(Opcode::UnpackHalf2x16, value);
|
||||
}
|
||||
|
||||
F64 IREmitter::PackDouble2x32(const Value& vector) {
|
||||
return Inst<F64>(Opcode::PackDouble2x32, vector);
|
||||
}
|
||||
|
|
|
@ -115,6 +115,9 @@ public:
|
|||
[[nodiscard]] U32 PackFloat2x16(const Value& vector);
|
||||
[[nodiscard]] Value UnpackFloat2x16(const U32& value);
|
||||
|
||||
[[nodiscard]] U32 PackHalf2x16(const Value& vector);
|
||||
[[nodiscard]] Value UnpackHalf2x16(const U32& value);
|
||||
|
||||
[[nodiscard]] F64 PackDouble2x32(const Value& vector);
|
||||
[[nodiscard]] Value UnpackDouble2x32(const F64& value);
|
||||
|
||||
|
|
|
@ -36,7 +36,8 @@ union TextureInstInfo {
|
|||
u32 raw;
|
||||
BitField<0, 8, TextureType> type;
|
||||
BitField<8, 1, u32> has_bias;
|
||||
BitField<16, 1, u32> has_lod_clamp;
|
||||
BitField<9, 1, u32> has_lod_clamp;
|
||||
BitField<10, 1, u32> relaxed_precision;
|
||||
};
|
||||
static_assert(sizeof(TextureInstInfo) <= sizeof(u32));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue