pdb: in plug_in_compat.pdb, set underlying op nodes

In plug_in_compat.pdb, when wrapping an op node inside a graph, set
the op node as the graph node's underlying operation.  This allows
gimp_gegl_apply_operation() to perform certain optimizations.
This commit is contained in:
Ell
2020-01-07 10:49:24 +02:00
parent 8b7bafa43a
commit e74994feaf
2 changed files with 12 additions and 0 deletions

View File

@ -72,6 +72,8 @@ wrap_in_graph (GeglNode *node)
gegl_node_add_child (new_node, node);
g_object_unref (node);
gimp_gegl_node_set_underlying_operation (new_node, node);
input = gegl_node_get_input_proxy (new_node, "input");
output = gegl_node_get_output_proxy (new_node, "output");
@ -105,6 +107,8 @@ wrap_in_selection_bounds (GeglNode *node,
gegl_node_add_child (new_node, node);
g_object_unref (node);
gimp_gegl_node_set_underlying_operation (new_node, node);
input = gegl_node_get_input_proxy (new_node, "input");
output = gegl_node_get_output_proxy (new_node, "output");
@ -168,6 +172,8 @@ wrap_in_gamma_cast (GeglNode *node,
gegl_node_add_child (new_node, node);
g_object_unref (node);
gimp_gegl_node_set_underlying_operation (new_node, node);
input = gegl_node_get_input_proxy (new_node, "input");
output = gegl_node_get_output_proxy (new_node, "output");

View File

@ -5081,6 +5081,8 @@ wrap_in_graph (GeglNode *node)
gegl_node_add_child (new_node, node);
g_object_unref (node);
gimp_gegl_node_set_underlying_operation (new_node, node);
input = gegl_node_get_input_proxy (new_node, "input");
output = gegl_node_get_output_proxy (new_node, "output");
@ -5114,6 +5116,8 @@ wrap_in_selection_bounds (GeglNode *node,
gegl_node_add_child (new_node, node);
g_object_unref (node);
gimp_gegl_node_set_underlying_operation (new_node, node);
input = gegl_node_get_input_proxy (new_node, "input");
output = gegl_node_get_output_proxy (new_node, "output");
@ -5177,6 +5181,8 @@ wrap_in_gamma_cast (GeglNode *node,
gegl_node_add_child (new_node, node);
g_object_unref (node);
gimp_gegl_node_set_underlying_operation (new_node, node);
input = gegl_node_get_input_proxy (new_node, "input");
output = gegl_node_get_output_proxy (new_node, "output");