1 // Copyright Timothy Goya 2007.
2 // Distributed under the Boost Software License, Version 1.0.
3 // (See accompanying file LICENSE_1_0.txt or copy at
4 // http://www.boost.org/LICENSE_1_0.txt)
6 #ifndef UNISON_VIDEO_OPENGL_TEXTURE_HPP
7 #define UNISON_VIDEO_OPENGL_TEXTURE_HPP
9 #include <unison/video/backend/Texture.hpp>
10 #include <unison/video/Surface.hpp>
24 class Texture : public Backend::Texture
27 Texture(const Surface &surface);
28 //Texture(const Surface &surface, const std::string &name);
29 //Texture(Backend::Texture *texture);
33 const Surface get_surface();
35 void blit(const Surface &src, const Point &dst_pos, const Rect &src_rect, const RenderOptions &options);
36 void blit(const Video::Texture &src, const Point &dst_pos, const Rect &src_rect, const RenderOptions &options);
37 void fill(const Color &color, const Rect &rect);
38 void fill_blend(const Color &color, const Rect &rect);
40 void blit_draw_buffer(const Rect &src_rect, const Point &dst_pos, const RenderOptions &options);
47 std::vector<Handle> handles;
49 static Handle create_handle(const Surface &surface, const Rect &rect);