Debian Codegraph @

clutter/x11/clutter-x11-texture-pixmap.h

raw
1 /*
2 * Clutter.
3 *
4 * An OpenGL based 'interactive canvas' library.
5 *
6 * Authored By Johan Bilien <[email protected]>
7 *
8 * Copyright (C) 2007 OpenedHand
9 *
10 * This library is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU Lesser General Public
12 * License as published by the Free Software Foundation; either
13 * version 2 of the License, or (at your option) any later version.
14 *
15 * This library is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 * Lesser General Public License for more details.
19 *
20 * You should have received a copy of the GNU Lesser General Public
21 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
22 *
23 *
24 */
25
26 #ifndef __CLUTTER_X11_TEXTURE_PIXMAP_H__
27 #define __CLUTTER_X11_TEXTURE_PIXMAP_H__
28
29 #include <glib.h>
30 #include <glib-object.h>
31 #include <clutter/clutter.h>
32
33 #include <X11/Xlib.h>
34
35 G_BEGIN_DECLS
36
37 #define CLUTTER_X11_TYPE_TEXTURE_PIXMAP (clutter_x11_texture_pixmap_get_type ())
38 #define CLUTTER_X11_TEXTURE_PIXMAP(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), CLUTTER_X11_TYPE_TEXTURE_PIXMAP, ClutterX11TexturePixmap))
39 #define CLUTTER_X11_TEXTURE_PIXMAP_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), CLUTTER_X11_TYPE_TEXTURE_PIXMAP, ClutterX11TexturePixmapClass))
40 #define CLUTTER_X11_IS_TEXTURE_PIXMAP(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), CLUTTER_X11_TYPE_TEXTURE_PIXMAP))
41 #define CLUTTER_X11_IS_TEXTURE_PIXMAP_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), CLUTTER_X11_TYPE_TEXTURE_PIXMAP))
42 #define CLUTTER_X11_TEXTURE_PIXMAP_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), CLUTTER_X11_TYPE_TEXTURE_PIXMAP, ClutterX11TexturePixmapClass))
43
44 typedef struct _ClutterX11TexturePixmap ClutterX11TexturePixmap;
45 typedef struct _ClutterX11TexturePixmapClass ClutterX11TexturePixmapClass;
46 typedef struct _ClutterX11TexturePixmapPrivate ClutterX11TexturePixmapPrivate;
47
48 /**
49 * ClutterX11TexturePixmap:
50 *
51 * The #ClutterX11TexturePixmap structure contains only private data
52 *
53 * Since: 0.8
54 */
55 struct _ClutterX11TexturePixmap
56 {
57 /*< private >*/
58 ClutterTexture parent;
59
60 ClutterX11TexturePixmapPrivate *priv;
61 };
62
63 /**
64 * ClutterX11TexturePixmapClass:
65 * @update_area: virtual function for updating the area of the texture
66 *
67 * The #ClutterX11TexturePixmapClass structure contains only private data
68 *
69 * Since: 0.8
70 */
71 struct _ClutterX11TexturePixmapClass
72 {
73 /*< private >*/
74 ClutterTextureClass parent_class;
75
76 /*< public >*/
77 void (* update_area) (ClutterX11TexturePixmap *texture,
78 gint x,
79 gint y,
80 gint width,
81 gint height);
82 };
83
84 CLUTTER_AVAILABLE_IN_ALL
85 GType clutter_x11_texture_pixmap_get_type (void) G_GNUC_CONST;
86
87 CLUTTER_AVAILABLE_IN_ALL
88 ClutterActor *clutter_x11_texture_pixmap_new (void);
89 CLUTTER_AVAILABLE_IN_ALL
90 ClutterActor *clutter_x11_texture_pixmap_new_with_pixmap (Pixmap pixmap);
91 CLUTTER_AVAILABLE_IN_ALL
92 ClutterActor *clutter_x11_texture_pixmap_new_with_window (Window window);
93
94 CLUTTER_AVAILABLE_IN_ALL
95 void clutter_x11_texture_pixmap_set_automatic (ClutterX11TexturePixmap *texture,
96 gboolean setting);
97 CLUTTER_AVAILABLE_IN_ALL
98 void clutter_x11_texture_pixmap_set_pixmap (ClutterX11TexturePixmap *texture,
99 Pixmap pixmap);
100 CLUTTER_AVAILABLE_IN_ALL
101 void clutter_x11_texture_pixmap_set_window (ClutterX11TexturePixmap *texture,
102 Window window,
103 gboolean automatic);
104
105 CLUTTER_AVAILABLE_IN_ALL
106 void clutter_x11_texture_pixmap_sync_window (ClutterX11TexturePixmap *texture);
107 CLUTTER_AVAILABLE_IN_ALL
108 void clutter_x11_texture_pixmap_update_area (ClutterX11TexturePixmap *texture,
109 gint x,
110 gint y,
111 gint width,
112 gint height);
113
114 G_END_DECLS
115
116 #endif