MQEngine
载入中...
搜索中...
未找到
TextureCacheSystem.h
浏览该文件的文档.
1//
2// Created by Administrator on 2025/1/20.
3//
4
5#ifndef TEXTURERENDERYSTEM_H
6#define TEXTURERENDERYSTEM_H
8#include "../data/Component.h"
9#include <unordered_map>
10#include <vector>
11
12namespace MQEngine {
13
15 public:
16 TextureCacheSystem(FCT::Context* ctx, DataManager* dataManager);
18
19 void update();
20 void collectTextures();
21 void loadTexture(const std::string& modelUuid, const std::string& texturePath);
22
23
24 private:
25 FCT::Context* m_ctx;
27 FCT::ModelLoader* m_modelLoader;
28
29 std::unordered_map<std::string, FCT::Image*> m_loadedTextures; // key: modelUuid + "|" + texturePath
30 };
31}
32
33#endif //TEXTURERENDERYSTEM_H
#define ENGINE_API
定义 EnginePCH.h:14
定义 DataManager.h:58
void loadTexture(const std::string &modelUuid, const std::string &texturePath)
定义 TextureCacheSystem.cpp:60
void collectTextures()
定义 TextureCacheSystem.cpp:32
FCT::ModelLoader * m_modelLoader
定义 TextureCacheSystem.h:27
TextureCacheSystem(FCT::Context *ctx, DataManager *dataManager)
定义 TextureCacheSystem.cpp:11
DataManager * m_dataManager
定义 TextureCacheSystem.h:26
void update()
定义 TextureCacheSystem.cpp:28
std::unordered_map< std::string, FCT::Image * > m_loadedTextures
定义 TextureCacheSystem.h:29
FCT::Context * m_ctx
定义 TextureCacheSystem.h:25
定义 application.h:5