Archived
1
Fork 0
This repository has been archived on 2025-04-12. You can view files and clone it, but cannot push or open issues or pull requests.
graph/include/assetmanager.h

31 lines
582 B
C
Raw Normal View History

#pragma once
#include <string>
2018-12-19 12:19:52 -05:00
struct MeshAsset;
struct MaterialAsset;
class Renderer;
2019-01-08 22:27:42 -05:00
struct AudioAsset;
class AudioSystem;
class AssetManager {
public:
void setRenderer(Renderer* r) {
renderer = r;
}
2019-01-08 22:27:42 -05:00
void setAudioSystem(AudioSystem* a) {
audioSystem = a;
}
2018-12-25 23:46:16 -05:00
2018-12-19 12:19:52 -05:00
MeshAsset* loadMesh(const std::string& path);
MaterialAsset* loadMaterial(const std::string& path);
2019-01-08 22:27:42 -05:00
AudioAsset* loadAudio(const std::string& path);
2018-12-25 23:46:16 -05:00
private:
Renderer* renderer = nullptr;
2019-01-08 22:27:42 -05:00
AudioSystem* audioSystem = nullptr;
};
inline AssetManager assetManager;