00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef TEDDY__GRAPHICS__IMAGE_FILE_TEXTURE__H
00026 #define TEDDY__GRAPHICS__IMAGE_FILE_TEXTURE__H
00027
00028
00029 #include "Teddy/Graphics/Texture.h"
00030 #include "SDL_video.h"
00031
00032
00033 namespace Teddy {
00034 namespace Graphics {
00035
00036
00038 class ImageFileTexture : public Texture {
00039 public:
00040 static const unsigned long TEXTURE_NO_SCALE;
00041 static const unsigned long TEXTURE_MODE_COLOR;
00042 static const unsigned long TEXTURE_MODE_ALPHA;
00043
00044 public:
00045 ImageFileTexture( const std::string &fname, int mode = TEXTURE_MODE_COLOR, int flags = 0 );
00046
00047 protected:
00048 void copySdlSurface( SDL_Surface *source, int mode, int flags );
00049 };
00050
00051
00052 };
00053 };
00054
00055
00056 #endif // TEDDY__GRAPHICS__IMAGE_FILE_TEXTURE_H
00057