gegl r2462 - in trunk: . gegl/process
- From: martinn svn gnome org
- To: svn-commits-list gnome org
- Subject: gegl r2462 - in trunk: . gegl/process
- Date: Sat, 14 Jun 2008 20:16:54 +0000 (UTC)
Author: martinn
Date: Sat Jun 14 20:16:53 2008
New Revision: 2462
URL: http://svn.gnome.org/viewvc/gegl?rev=2462&view=rev
Log:
2008-06-14 Martin Nordholts <martinn svn gnome org>
* gegl/process/gegl-processor.c: Further general cleanup.
Modified:
trunk/ChangeLog
trunk/gegl/process/gegl-processor.c
Modified: trunk/gegl/process/gegl-processor.c
==============================================================================
--- trunk/gegl/process/gegl-processor.c (original)
+++ trunk/gegl/process/gegl-processor.c Sat Jun 14 20:16:53 2008
@@ -62,14 +62,14 @@
GeglNode *input;
GeglNodeContext *context;
- GeglRegion *valid_region; /* used when doing unbuffered rendering */
- GeglRegion *queued_region;
- GSList *dirty_rectangles;
- gint chunk_size;
-
- GThread *thread;
- gboolean thread_done;
- gdouble progress;
+ GeglRegion *valid_region; /* used when doing unbuffered rendering */
+ GeglRegion *queued_region;
+ GSList *dirty_rectangles;
+ gint chunk_size;
+
+ GThread *thread;
+ gboolean thread_done;
+ gdouble progress;
};
@@ -165,12 +165,13 @@
if (processor->node->operation &&
GEGL_IS_OPERATION_SINK (processor->node->operation))
{
- GeglCache *cache;
+ GeglCache *cache;
if (!gegl_operation_sink_needs_full (processor->node->operation))
{
return object;
}
+
cache = gegl_node_get_cache (processor->input);
processor->context = gegl_node_add_context (processor->node, cache);
@@ -378,6 +379,7 @@
dr->y += band_size;
processor->dirty_rectangles = g_slist_prepend (processor->dirty_rectangles, fragment);
+
return TRUE;
}
else
@@ -396,6 +398,7 @@
dr->x += band_size;
processor->dirty_rectangles = g_slist_prepend (processor->dirty_rectangles, fragment);
+
return TRUE;
}
}
@@ -404,9 +407,9 @@
if (!dr->width || !dr->height)
{
g_slice_free (GeglRectangle, dr);
+
return TRUE;
}
-
if (buffered)
{
@@ -552,6 +555,7 @@
{
gboolean more_work = render_rectangle (processor);
+
if (more_work == TRUE)
{
if (progress)
@@ -578,6 +582,7 @@
}
wanted = 1;
}
+
return more_work;
}
}
@@ -614,6 +619,7 @@
rect_area (rectangle));
return TRUE;
}
+
return FALSE;
}
else if (!gegl_region_empty (processor->queued_region) &&
@@ -638,6 +644,7 @@
processor->dirty_rectangles = g_slist_prepend (processor->dirty_rectangles,
g_slice_dup (GeglRectangle, &roi));
}
+
g_free (rectangles);
}
@@ -673,7 +680,10 @@
gegl_node_remove_context (processor->node, cache);
processor->context = NULL;
if (progress)
- *progress = 1.0;
+ {
+ *progress = 1.0;
+ }
+
return TRUE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]