summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFernando Sahmkow <fsahmkow27@gmail.com>2020-03-27 19:08:54 +0100
committerGitHub <noreply@github.com>2020-03-27 19:08:54 +0100
commit7a2f60df264113b1bdcf885aebf4ed3d05b89bce (patch)
treea0966a4157ac4e87eb8b9d83a0e600de8287f9e7
parentMerge pull request #3564 from makigumo/maxwell_to_vk_sscaled (diff)
parentengines/const_buffer_engine_interface: Store image format type (diff)
downloadyuzu-7a2f60df264113b1bdcf885aebf4ed3d05b89bce.tar
yuzu-7a2f60df264113b1bdcf885aebf4ed3d05b89bce.tar.gz
yuzu-7a2f60df264113b1bdcf885aebf4ed3d05b89bce.tar.bz2
yuzu-7a2f60df264113b1bdcf885aebf4ed3d05b89bce.tar.lz
yuzu-7a2f60df264113b1bdcf885aebf4ed3d05b89bce.tar.xz
yuzu-7a2f60df264113b1bdcf885aebf4ed3d05b89bce.tar.zst
yuzu-7a2f60df264113b1bdcf885aebf4ed3d05b89bce.zip
-rw-r--r--src/video_core/engines/const_buffer_engine_interface.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/video_core/engines/const_buffer_engine_interface.h b/src/video_core/engines/const_buffer_engine_interface.h
index 724ee0fd6..ebe139504 100644
--- a/src/video_core/engines/const_buffer_engine_interface.h
+++ b/src/video_core/engines/const_buffer_engine_interface.h
@@ -18,10 +18,14 @@ struct SamplerDescriptor {
union {
u32 raw = 0;
BitField<0, 2, Tegra::Shader::TextureType> texture_type;
- BitField<2, 3, Tegra::Texture::ComponentType> component_type;
+ BitField<2, 3, Tegra::Texture::ComponentType> r_type;
BitField<5, 1, u32> is_array;
BitField<6, 1, u32> is_buffer;
BitField<7, 1, u32> is_shadow;
+ BitField<8, 3, Tegra::Texture::ComponentType> g_type;
+ BitField<11, 3, Tegra::Texture::ComponentType> b_type;
+ BitField<14, 3, Tegra::Texture::ComponentType> a_type;
+ BitField<17, 7, Tegra::Texture::TextureFormat> format;
};
bool operator==(const SamplerDescriptor& rhs) const noexcept {
@@ -36,9 +40,11 @@ struct SamplerDescriptor {
using Tegra::Shader::TextureType;
SamplerDescriptor result;
- // This is going to be used to determine the shading language type.
- // Because of that we don't care about all component types on color textures.
- result.component_type.Assign(tic.r_type.Value());
+ result.format.Assign(tic.format.Value());
+ result.r_type.Assign(tic.r_type.Value());
+ result.g_type.Assign(tic.g_type.Value());
+ result.b_type.Assign(tic.b_type.Value());
+ result.a_type.Assign(tic.a_type.Value());
switch (tic.texture_type.Value()) {
case Tegra::Texture::TextureType::Texture1D: