00001
00002
00003 #ifndef _GDKMM_GL_PIXMAP_H
00004 #define _GDKMM_GL_PIXMAP_H
00005
00006 #include <glibmm.h>
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 #include <gdkmm/gl/defs.h>
00028
00029 #include <gdkmm/drawable.h>
00030 #include <gdkmm/pixmap.h>
00031
00032 #include <gdkmm/gl/config.h>
00033 #include <gdkmm/gl/drawable.h>
00034
00035
00036 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00037 typedef struct _GdkGLPixmap GdkGLPixmap;
00038 typedef struct _GdkGLPixmapClass GdkGLPixmapClass;
00039 #endif
00040
00041
00042 namespace Gdk
00043 {
00044
00045 namespace GL
00046 { class Pixmap_Class; }
00047
00048 }
00049 namespace Gdk
00050 {
00051 namespace GL
00052 {
00053
00054
00055
00056
00057
00058
00059
00060 class Pixmap : public Gdk::Drawable,
00061 public Gdk::GL::Drawable
00062 {
00063
00064 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00065
00066 public:
00067 typedef Pixmap CppObjectType;
00068 typedef Pixmap_Class CppClassType;
00069 typedef GdkGLPixmap BaseObjectType;
00070 typedef GdkGLPixmapClass BaseClassType;
00071
00072 private:
00073 friend class Pixmap_Class;
00074 static CppClassType pixmap_class_;
00075
00076
00077 Pixmap(const Pixmap&);
00078 Pixmap& operator=(const Pixmap&);
00079
00080 protected:
00081 explicit Pixmap(const Glib::ConstructParams& construct_params);
00082 explicit Pixmap(GdkGLPixmap* castitem);
00083
00084 #endif
00085
00086 public:
00087 virtual ~Pixmap();
00088
00089 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00090 static GType get_type() G_GNUC_CONST;
00091 static GType get_base_type() G_GNUC_CONST;
00092 #endif
00093
00094 GdkGLPixmap* gobj() { return reinterpret_cast<GdkGLPixmap*>(gobject_); }
00095 const GdkGLPixmap* gobj() const { return reinterpret_cast<GdkGLPixmap*>(gobject_); }
00096
00097 GdkGLPixmap* gobj_copy();
00098
00099 private:
00100
00101
00102 protected:
00103 Pixmap(const Glib::RefPtr<const Config>& glconfig,
00104 const Glib::RefPtr<const Gdk::Pixmap>& pixmap,
00105 const int* attrib_list = 0);
00106
00107 public:
00108
00109 static Glib::RefPtr<Pixmap> create(const Glib::RefPtr<const Config>& glconfig, const Glib::RefPtr<const Gdk::Pixmap>& pixmap, const int* attrib_list);
00110
00111
00112 public:
00113
00114
00115
00116
00117
00118
00119
00120
00121 Glib::RefPtr<Gdk::Pixmap> get_pixmap();
00122
00123
00124
00125
00126
00127
00128
00129
00130 Glib::RefPtr<const Gdk::Pixmap> get_pixmap() const;
00131
00132 public:
00133
00134
00135
00136
00137
00138
00139
00140
00141
00142
00143
00144 static Glib::RefPtr<Pixmap> set_gl_capability(const Glib::RefPtr<Gdk::Pixmap>& pixmap, const Glib::RefPtr<const Config>& glconfig, const int* attrib_list = 0);
00145
00146
00147
00148
00149
00150 static void unset_gl_capability(const Glib::RefPtr<Gdk::Pixmap>& pixmap);
00151
00152
00153
00154
00155
00156 static bool is_gl_capable(const Glib::RefPtr<const Gdk::Pixmap>& pixmap);
00157
00158
00159
00160
00161
00162 static Glib::RefPtr<Pixmap> get_gl_pixmap(const Glib::RefPtr<const Gdk::Pixmap>& pixmap);
00163
00164
00165 static Glib::RefPtr<Gdk::GL::Drawable> get_gl_drawable(const Glib::RefPtr<const Gdk::Pixmap>& pixmap);
00166
00167
00168 public:
00169
00170 public:
00171
00172
00173 protected:
00174
00175
00176
00177
00178
00179 };
00180
00181
00182
00183
00184
00185
00186
00187
00188
00189
00190
00191
00192
00193
00194 }
00195 }
00196
00197
00198 namespace Glib
00199 {
00200
00201 Glib::RefPtr<Gdk::GL::Pixmap> wrap(GdkGLPixmap* object, bool take_copy = false);
00202 }
00203
00204
00205 #endif
00206