[mutter/gbsneto/more-clutter-api: 8/10] clutter/paint-node: Expose clutter_paint_node_paint()



commit 0f1c84d888ee13696f9735df3f2fd5cc12a9b4ce
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Mon Jan 28 12:59:03 2019 -0200

    clutter/paint-node: Expose clutter_paint_node_paint()
    
    When painting to an offscreen framebuffer, MetaShapedTexture will
    need to have full control of the painting routines of paint nodes.
    As such, expose clutter_paint_node_paint() to allow forcing a
    paint nodes paint from MetaShapedTexture.
    
    https://gitlab.gnome.org/GNOME/mutter/merge_requests/405

 clutter/clutter/clutter-actor.c              | 2 +-
 clutter/clutter/clutter-paint-node-private.h | 1 -
 clutter/clutter/clutter-paint-node.c         | 8 ++++----
 clutter/clutter/clutter-paint-node.h         | 3 +++
 4 files changed, 8 insertions(+), 6 deletions(-)
---
diff --git a/clutter/clutter/clutter-actor.c b/clutter/clutter/clutter-actor.c
index 7de72e633..f01199519 100644
--- a/clutter/clutter/clutter-actor.c
+++ b/clutter/clutter/clutter-actor.c
@@ -3779,7 +3779,7 @@ clutter_actor_paint_node (ClutterActor     *actor,
     }
 #endif /* CLUTTER_ENABLE_DEBUG */
 
-  _clutter_paint_node_paint (root);
+  clutter_paint_node_paint (root);
 
   return TRUE;
 }
diff --git a/clutter/clutter/clutter-paint-node-private.h b/clutter/clutter/clutter-paint-node-private.h
index feecdd811..e6573ecd9 100644
--- a/clutter/clutter/clutter-paint-node-private.h
+++ b/clutter/clutter/clutter-paint-node-private.h
@@ -116,7 +116,6 @@ ClutterPaintNode *      _clutter_root_node_new                          (CoglFra
 ClutterPaintNode *      _clutter_transform_node_new                     (const CoglMatrix            
*matrix);
 ClutterPaintNode *      _clutter_dummy_node_new                         (ClutterActor                *actor);
 
-void                    _clutter_paint_node_paint                       (ClutterPaintNode            *root);
 void                    _clutter_paint_node_dump_tree                   (ClutterPaintNode            *root);
 
 G_GNUC_INTERNAL
diff --git a/clutter/clutter/clutter-paint-node.c b/clutter/clutter/clutter-paint-node.c
index c31a0c702..e731ca60a 100644
--- a/clutter/clutter/clutter-paint-node.c
+++ b/clutter/clutter/clutter-paint-node.c
@@ -989,15 +989,15 @@ clutter_paint_node_add_primitive (ClutterPaintNode *node,
   g_array_append_val (node->operations, operation);
 }
 
-/*< private >
- * _clutter_paint_node_paint:
+/**
+ * clutter_paint_node_paint:
  * @node: a #ClutterPaintNode
  *
  * Paints the @node using the class implementation, traversing
  * its children, if any.
  */
 void
-_clutter_paint_node_paint (ClutterPaintNode *node)
+clutter_paint_node_paint (ClutterPaintNode *node)
 {
   ClutterPaintNodeClass *klass = CLUTTER_PAINT_NODE_GET_CLASS (node);
   ClutterPaintNode *iter;
@@ -1014,7 +1014,7 @@ _clutter_paint_node_paint (ClutterPaintNode *node)
        iter != NULL;
        iter = iter->next_sibling)
     {
-      _clutter_paint_node_paint (iter);
+      clutter_paint_node_paint (iter);
     }
 
   if (res)
diff --git a/clutter/clutter/clutter-paint-node.h b/clutter/clutter/clutter-paint-node.h
index e459e74ed..c42abbc3d 100644
--- a/clutter/clutter/clutter-paint-node.h
+++ b/clutter/clutter/clutter-paint-node.h
@@ -49,6 +49,9 @@ ClutterPaintNode *      clutter_paint_node_ref                          (Clutter
 CLUTTER_EXPORT
 void                    clutter_paint_node_unref                        (ClutterPaintNode      *node);
 
+CLUTTER_EXPORT
+void                    clutter_paint_node_paint                        (ClutterPaintNode      *node);
+
 CLUTTER_EXPORT
 void                    clutter_paint_node_set_name                     (ClutterPaintNode      *node,
                                                                          const char            *name);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]