Fixed resource loader
This commit is contained in:
@ -6,6 +6,7 @@
|
||||
#include <mutex>
|
||||
#include <atomic>
|
||||
#include <unordered_map>
|
||||
#include "../resources/ResourceManager.h"
|
||||
|
||||
// Lightweight AssetLoader scaffold.
|
||||
// Responsibilities:
|
||||
@ -22,6 +23,7 @@ public:
|
||||
void shutdown();
|
||||
|
||||
void setBasePath(const std::string& basePath);
|
||||
void setResourceManager(resources::ResourceManager* mgr);
|
||||
|
||||
// Queue a texture path (relative to base path) for loading.
|
||||
void queueTexture(const std::string& path);
|
||||
@ -49,6 +51,7 @@ public:
|
||||
private:
|
||||
SDL_Renderer* m_renderer = nullptr;
|
||||
std::string m_basePath;
|
||||
resources::ResourceManager* m_resourceManager = nullptr;
|
||||
|
||||
// queued paths (simple FIFO)
|
||||
std::vector<std::string> m_queue;
|
||||
|
||||
Reference in New Issue
Block a user