summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/HiresTextures.h
diff options
context:
space:
mode:
authoriwubcode <iwubcode@users.noreply.github.com>2023-02-28 20:28:27 -0600
committeriwubcode <iwubcode@users.noreply.github.com>2023-03-01 12:11:04 -0600
commit42cb3f39046af5d0cfe3fae05e2e2ba98d80d367 (patch)
tree03554c670e0b53e0f453bbf263fa55096ccc8137 /Source/Core/VideoCommon/HiresTextures.h
parent3e352559834b070feb89a7b9e47de54aaa7ab528 (diff)
VideoCommon: remove HiResTexture DDS loading, update hirestexture logic to use custom texture data
Diffstat (limited to 'Source/Core/VideoCommon/HiresTextures.h')
-rw-r--r--Source/Core/VideoCommon/HiresTextures.h19
1 files changed, 5 insertions, 14 deletions
diff --git a/Source/Core/VideoCommon/HiresTextures.h b/Source/Core/VideoCommon/HiresTextures.h
index bcd889e18c..2381d24bd6 100644
--- a/Source/Core/VideoCommon/HiresTextures.h
+++ b/Source/Core/VideoCommon/HiresTextures.h
@@ -9,6 +9,7 @@
#include <vector>
#include "Common/CommonTypes.h"
+#include "VideoCommon/GraphicsModSystem/Runtime/CustomTextureData.h"
#include "VideoCommon/TextureConfig.h"
#include "VideoCommon/TextureInfo.h"
@@ -29,31 +30,21 @@ public:
static std::string GenBaseName(const TextureInfo& texture_info, bool dump = false);
- static u32 CalculateMipCount(u32 width, u32 height);
-
~HiresTexture();
AbstractTextureFormat GetFormat() const;
bool HasArbitraryMipmaps() const;
- struct Level
- {
- std::vector<u8> data;
- AbstractTextureFormat format = AbstractTextureFormat::RGBA8;
- u32 width = 0;
- u32 height = 0;
- u32 row_length = 0;
- };
- std::vector<Level> m_levels;
+ VideoCommon::CustomTextureData& GetData() { return m_data; }
+ const VideoCommon::CustomTextureData& GetData() const { return m_data; }
private:
static std::unique_ptr<HiresTexture> Load(const std::string& base_filename, u32 width,
u32 height);
- static bool LoadDDSTexture(HiresTexture* tex, const std::string& filename);
- static bool LoadDDSTexture(Level& level, const std::string& filename, u32 mip_level);
- static bool LoadTexture(Level& level, const std::vector<u8>& buffer);
static void Prefetch();
HiresTexture() = default;
+
+ VideoCommon::CustomTextureData m_data;
bool m_has_arbitrary_mipmaps = false;
};