2016-03-17 13:48:19 +00:00
|
|
|
/* GSK - The GTK Scene Kit
|
|
|
|
*
|
|
|
|
* Copyright 2016 Endless
|
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __GSK_RENDER_NODE_H__
|
|
|
|
#define __GSK_RENDER_NODE_H__
|
|
|
|
|
|
|
|
#if !defined (__GSK_H_INSIDE__) && !defined (GSK_COMPILATION)
|
|
|
|
#error "Only <gsk/gsk.h> can be included directly."
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <gsk/gsktypes.h>
|
|
|
|
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
|
|
|
|
#define GSK_TYPE_RENDER_NODE (gsk_render_node_get_type ())
|
|
|
|
|
|
|
|
#define GSK_RENDER_NODE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GSK_TYPE_RENDER_NODE, GskRenderNode))
|
|
|
|
#define GSK_IS_RENDER_NODE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GSK_TYPE_RENDER_NODE))
|
|
|
|
|
|
|
|
typedef struct _GskRenderNode GskRenderNode;
|
|
|
|
typedef struct _GskRenderNodeClass GskRenderNodeClass;
|
|
|
|
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GType gsk_render_node_get_type (void) G_GNUC_CONST;
|
|
|
|
|
2016-06-29 18:05:33 +00:00
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_ref (GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_render_node_unref (GskRenderNode *node);
|
2016-03-17 13:48:19 +00:00
|
|
|
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_get_parent (GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_get_first_child (GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_get_last_child (GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_get_next_sibling (GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_get_previous_sibling (GskRenderNode *node);
|
|
|
|
|
2016-06-22 16:30:36 +00:00
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_append_child (GskRenderNode *node,
|
|
|
|
GskRenderNode *child);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_prepend_child (GskRenderNode *node,
|
|
|
|
GskRenderNode *child);
|
2016-03-17 13:48:19 +00:00
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_insert_child_at_pos (GskRenderNode *node,
|
|
|
|
GskRenderNode *child,
|
|
|
|
int index_);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_insert_child_before (GskRenderNode *node,
|
|
|
|
GskRenderNode *child,
|
|
|
|
GskRenderNode *sibling);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_insert_child_after (GskRenderNode *node,
|
|
|
|
GskRenderNode *child,
|
|
|
|
GskRenderNode *sibling);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_remove_child (GskRenderNode *node,
|
|
|
|
GskRenderNode *child);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_replace_child (GskRenderNode *node,
|
|
|
|
GskRenderNode *new_child,
|
|
|
|
GskRenderNode *old_child);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_render_node_remove_all_children (GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
guint gsk_render_node_get_n_children (GskRenderNode *node);
|
|
|
|
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
gboolean gsk_render_node_contains (GskRenderNode *node,
|
|
|
|
GskRenderNode *descendant);
|
|
|
|
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_render_node_set_bounds (GskRenderNode *node,
|
|
|
|
const graphene_rect_t *bounds);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_render_node_set_transform (GskRenderNode *node,
|
|
|
|
const graphene_matrix_t *transform);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
2016-08-04 05:04:25 +00:00
|
|
|
void gsk_render_node_set_offset (GskRenderNode *node,
|
|
|
|
const graphene_point3d_t *offset);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
2016-03-17 13:48:19 +00:00
|
|
|
void gsk_render_node_set_child_transform (GskRenderNode *node,
|
|
|
|
const graphene_matrix_t *transform);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_render_node_set_opacity (GskRenderNode *node,
|
|
|
|
double opacity);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_render_node_set_hidden (GskRenderNode *node,
|
|
|
|
gboolean hidden);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
gboolean gsk_render_node_is_hidden (GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_render_node_set_opaque (GskRenderNode *node,
|
|
|
|
gboolean opaque);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
gboolean gsk_render_node_is_opaque (GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
cairo_t * gsk_render_node_get_draw_context (GskRenderNode *node);
|
|
|
|
|
2016-07-01 11:12:30 +00:00
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_render_node_set_blend_mode (GskRenderNode *node,
|
|
|
|
GskBlendMode blend_mode);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskBlendMode gsk_render_node_get_blend_mode (GskRenderNode *node);
|
|
|
|
|
2016-07-27 15:48:35 +00:00
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
int gsk_render_node_get_scale_factor (GskRenderNode *node);
|
|
|
|
|
2016-03-17 13:48:19 +00:00
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_render_node_set_name (GskRenderNode *node,
|
|
|
|
const char *name);
|
|
|
|
|
2016-06-29 18:05:33 +00:00
|
|
|
#define GSK_VALUE_HOLDS_RENDER_NODE(value) (G_VALUE_HOLDS (value, GSK_TYPE_RENDER_NODE))
|
|
|
|
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_value_set_render_node (GValue *value,
|
|
|
|
GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
void gsk_value_take_render_node (GValue *value,
|
|
|
|
GskRenderNode *node);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_value_get_render_node (const GValue *value);
|
|
|
|
GDK_AVAILABLE_IN_3_22
|
|
|
|
GskRenderNode * gsk_value_dup_render_node (const GValue *value);
|
|
|
|
|
2016-03-17 13:48:19 +00:00
|
|
|
G_END_DECLS
|
|
|
|
|
|
|
|
#endif /* __GSK_RENDER_NODE_H__ */
|