diff options
author | Perttu Ahola <celeron55@gmail.com> | 2011-02-11 19:55:42 +0200 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2011-02-11 19:55:42 +0200 |
commit | 52d99fef31daa60903053bc565b6b9d3a31a2bc8 (patch) | |
tree | 248831e2e4f78df073f667c3d843d1695e3926b3 /src/tile.h | |
parent | 804b2647ced20b8af1e632f1e99d54f905fa8ce0 (diff) | |
download | minetest-52d99fef31daa60903053bc565b6b9d3a31a2bc8.tar.gz minetest-52d99fef31daa60903053bc565b6b9d3a31a2bc8.tar.bz2 minetest-52d99fef31daa60903053bc565b6b9d3a31a2bc8.zip |
fully working i guess
Diffstat (limited to 'src/tile.h')
-rw-r--r-- | src/tile.h | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/src/tile.h b/src/tile.h index 2a342313d..1e339806f 100644 --- a/src/tile.h +++ b/src/tile.h @@ -104,9 +104,27 @@ struct SourceAtlasPointer }; /* + Implementation (to be used as a no-op on the server) +*/ +class ITextureSource +{ +public: + ITextureSource(){} + virtual ~ITextureSource(){} + virtual u32 getTextureId(const std::string &name){return 0;} + virtual u32 getTextureIdDirect(const std::string &name){return 0;} + virtual std::string getTextureName(u32 id){return "";} + virtual AtlasPointer getTexture(u32 id){return AtlasPointer(0);} + virtual AtlasPointer getTexture(const std::string &name) + {return AtlasPointer(0);} + virtual video::ITexture* getTextureRaw(const std::string &name) + {return NULL;} +}; + +/* Creates and caches textures. */ -class TextureSource +class TextureSource : public ITextureSource { public: TextureSource(IrrlichtDevice *device); |