mirror of
https://github.com/openshwprojects/OpenBK7231T_App.git
synced 2026-03-10 09:17:57 +01:00
win tool very early draft
This commit is contained in:
18
src/sim/TextureManager.cpp
Normal file
18
src/sim/TextureManager.cpp
Normal file
@@ -0,0 +1,18 @@
|
||||
#ifdef WINDOWS
|
||||
|
||||
#include "TextureManager.h"
|
||||
#include "Texture.h"
|
||||
|
||||
Texture2D *TextureManager::registerTexture(const char *fname) {
|
||||
for (int i = 0; i < loaded.size(); i++) {
|
||||
if (!stricmp(loaded[i]->getName(), fname))
|
||||
return loaded[i];
|
||||
}
|
||||
Texture2D *t = new Texture2D();
|
||||
t->loadTexture(fname);
|
||||
loaded.push_back(t);
|
||||
return t;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user