00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00024
00025 #ifndef SFML_RENDERTEXTURE_HPP
00026 #define SFML_RENDERTEXTURE_HPP
00027
00029
00031 #include <SFML/Graphics/Texture.hpp>
00032 #include <SFML/Graphics/RenderTarget.hpp>
00033
00034
00035 namespace sf
00036 {
00037 namespace priv
00038 {
00039 class RenderTextureImpl;
00040 }
00041
00046 class SFML_API RenderTexture : public RenderTarget
00047 {
00048 public :
00049
00059 RenderTexture();
00060
00065 virtual ~RenderTexture();
00066
00085 bool Create(unsigned int width, unsigned int height, bool depthBuffer = false);
00086
00098 void SetSmooth(bool smooth);
00099
00108 bool IsSmooth() const;
00109
00125 bool SetActive(bool active = true);
00126
00136 void Display();
00137
00149 virtual unsigned int GetWidth() const;
00150
00162 virtual unsigned int GetHeight() const;
00163
00178 const Texture& GetTexture() const;
00179
00180 private :
00181
00193 virtual bool Activate(bool active);
00194
00196
00198 Texture myTexture;
00199 priv::RenderTextureImpl* myRenderTexture;
00200 };
00201
00202 }
00203
00204
00205 #endif // SFML_RENDERTEXTURE_HPP
00206
00207