diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/video_core/engines/maxwell_3d.cpp | 2 | ||||
| -rw-r--r-- | src/video_core/textures/texture.h | 18 |
2 files changed, 16 insertions, 4 deletions
diff --git a/src/video_core/engines/maxwell_3d.cpp b/src/video_core/engines/maxwell_3d.cpp index 124753032..2d7c3152f 100644 --- a/src/video_core/engines/maxwell_3d.cpp +++ b/src/video_core/engines/maxwell_3d.cpp | |||
| @@ -231,6 +231,8 @@ Texture::TICEntry Maxwell3D::GetTICEntry(u32 tic_index) const { | |||
| 231 | 231 | ||
| 232 | // TODO(Subv): Different data types for separate components are not supported | 232 | // TODO(Subv): Different data types for separate components are not supported |
| 233 | ASSERT(r_type == g_type && r_type == b_type && r_type == a_type); | 233 | ASSERT(r_type == g_type && r_type == b_type && r_type == a_type); |
| 234 | // TODO(Subv): Only UNORM formats are supported for now. | ||
| 235 | ASSERT(r_type == Texture::ComponentType::UNORM); | ||
| 234 | 236 | ||
| 235 | return tic_entry; | 237 | return tic_entry; |
| 236 | } | 238 | } |
diff --git a/src/video_core/textures/texture.h b/src/video_core/textures/texture.h index 1145e39f8..c12ed6e1d 100644 --- a/src/video_core/textures/texture.h +++ b/src/video_core/textures/texture.h | |||
| @@ -37,6 +37,16 @@ enum class TICHeaderVersion : u32 { | |||
| 37 | BlockLinearColorKey = 4, | 37 | BlockLinearColorKey = 4, |
| 38 | }; | 38 | }; |
| 39 | 39 | ||
| 40 | enum class ComponentType : u32 { | ||
| 41 | SNORM = 1, | ||
| 42 | UNORM = 2, | ||
| 43 | SINT = 3, | ||
| 44 | UINT = 4, | ||
| 45 | SNORM_FORCE_FP16 = 5, | ||
| 46 | UNORM_FORCE_FP16 = 6, | ||
| 47 | FLOAT = 7 | ||
| 48 | }; | ||
| 49 | |||
| 40 | union TextureHandle { | 50 | union TextureHandle { |
| 41 | u32 raw; | 51 | u32 raw; |
| 42 | BitField<0, 20, u32> tic_id; | 52 | BitField<0, 20, u32> tic_id; |
| @@ -48,10 +58,10 @@ struct TICEntry { | |||
| 48 | union { | 58 | union { |
| 49 | u32 raw; | 59 | u32 raw; |
| 50 | BitField<0, 7, TextureFormat> format; | 60 | BitField<0, 7, TextureFormat> format; |
| 51 | BitField<7, 3, u32> r_type; | 61 | BitField<7, 3, ComponentType> r_type; |
| 52 | BitField<10, 3, u32> g_type; | 62 | BitField<10, 3, ComponentType> g_type; |
| 53 | BitField<13, 3, u32> b_type; | 63 | BitField<13, 3, ComponentType> b_type; |
| 54 | BitField<16, 3, u32> a_type; | 64 | BitField<16, 3, ComponentType> a_type; |
| 55 | }; | 65 | }; |
| 56 | u32 address_low; | 66 | u32 address_low; |
| 57 | union { | 67 | union { |