xglcomp
annotate src/texture.h @ 8:b0081a0c211f
damage issues
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Sat, 30 Jan 2016 07:58:07 +0200 |
parents | |
children |
rev | line source |
---|---|
nuclear@4 | 1 #ifndef TEXTURE_H_ |
nuclear@4 | 2 #define TEXTURE_H_ |
nuclear@4 | 3 |
nuclear@4 | 4 #include <X11/Xlib.h> |
nuclear@4 | 5 |
nuclear@4 | 6 class Texture { |
nuclear@4 | 7 private: |
nuclear@4 | 8 unsigned int tex; |
nuclear@4 | 9 int width, height; |
nuclear@4 | 10 |
nuclear@4 | 11 public: |
nuclear@4 | 12 Texture(); |
nuclear@4 | 13 ~Texture(); |
nuclear@4 | 14 |
nuclear@4 | 15 void set_image(int x, int y, unsigned char *pix = 0); |
nuclear@4 | 16 void set_image(Display *dpy, Pixmap pixmap); |
nuclear@4 | 17 |
nuclear@4 | 18 int get_width() const; |
nuclear@4 | 19 int get_height() const; |
nuclear@4 | 20 |
nuclear@4 | 21 unsigned int get_id() const; |
nuclear@4 | 22 }; |
nuclear@4 | 23 |
nuclear@4 | 24 #endif // TEXTURE_H_ |