aboutsummaryrefslogtreecommitdiff
path: root/src/video_core/texture_cache/surface_params.h
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2019-11-19 18:29:17 -0500
committerGitHub <noreply@github.com>2019-11-19 18:29:17 -0500
commitb0819e2ffb8df3f4ec25186c7f2487790ab557e6 (patch)
tree239818f90980fb8ee9a2201111aa81f169a9e6bb /src/video_core/texture_cache/surface_params.h
parent60993513af8e4436d7630eb3edda03ace4abc935 (diff)
parent4681381a3413554b861f44a768fca83e8ea74cff (diff)
Merge pull request #3086 from ReinUsesLisp/format-lookups
texture_cache: Use a flat table instead of switch for texture format lookups
Diffstat (limited to 'src/video_core/texture_cache/surface_params.h')
-rw-r--r--src/video_core/texture_cache/surface_params.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/video_core/texture_cache/surface_params.h b/src/video_core/texture_cache/surface_params.h
index c58e7f8a4..709aa0dc2 100644
--- a/src/video_core/texture_cache/surface_params.h
+++ b/src/video_core/texture_cache/surface_params.h
@@ -16,16 +16,20 @@
namespace VideoCommon {
+class FormatLookupTable;
+
using VideoCore::Surface::SurfaceCompression;
class SurfaceParams {
public:
/// Creates SurfaceCachedParams from a texture configuration.
- static SurfaceParams CreateForTexture(const Tegra::Texture::TICEntry& tic,
+ static SurfaceParams CreateForTexture(const FormatLookupTable& lookup_table,
+ const Tegra::Texture::TICEntry& tic,
const VideoCommon::Shader::Sampler& entry);
/// Creates SurfaceCachedParams from an image configuration.
- static SurfaceParams CreateForImage(const Tegra::Texture::TICEntry& tic,
+ static SurfaceParams CreateForImage(const FormatLookupTable& lookup_table,
+ const Tegra::Texture::TICEntry& tic,
const VideoCommon::Shader::Image& entry);
/// Creates SurfaceCachedParams for a depth buffer configuration.
@@ -248,7 +252,6 @@ public:
u32 num_levels;
u32 emulated_levels;
VideoCore::Surface::PixelFormat pixel_format;
- VideoCore::Surface::ComponentType component_type;
VideoCore::Surface::SurfaceType type;
VideoCore::Surface::SurfaceTarget target;