gegl r2500 - in branches/branch_zhangjb: . operations/frequency/tools tests/frequency tests/images



Author: zhangjb
Date: Thu Jun 26 13:19:57 2008
New Revision: 2500
URL: http://svn.gnome.org/viewvc/gegl?rev=2500&view=rev

Log:
* operations/frequency/tools/component.c: fixed a bug that used int as
long.
* tests/frequency/hello-world-fourier.c: 
* tests/images/lena_bw_4x4.png: new
* tests/images/lena_rgb_4x4.png: new
* tests/images/lena_rgba.png: deleted
* tests/images/lena_rgb_5x5.png: new


Added:
   branches/branch_zhangjb/tests/images/lena_bw_4x4.png   (contents, props changed)
   branches/branch_zhangjb/tests/images/lena_rgb_4x4.png   (contents, props changed)
   branches/branch_zhangjb/tests/images/lena_rgb_5x5.png   (contents, props changed)
Removed:
   branches/branch_zhangjb/tests/images/lena_rgba.png
Modified:
   branches/branch_zhangjb/ChangeLog
   branches/branch_zhangjb/operations/frequency/tools/component.c
   branches/branch_zhangjb/tests/frequency/hello-world-fourier.c

Modified: branches/branch_zhangjb/operations/frequency/tools/component.c
==============================================================================
--- branches/branch_zhangjb/operations/frequency/tools/component.c	(original)
+++ branches/branch_zhangjb/operations/frequency/tools/component.c	Thu Jun 26 13:19:57 2008
@@ -17,17 +17,17 @@
  */
 
 gboolean get_rgba_component(gdouble* src_buf, gdouble* comp_buf, gint place,
-                            gint samples);
+                            glong samples);
 gboolean set_rgba_component(gdouble* comp_buf, gdouble* dst_buf, gint place,
-                            gint samples);
+                            glong samples);
 gboolean get_freq_component(gdouble* src_buf, gdouble* comp_buf, gint place,
-                            gint samples);
+                            glong samples);
 gboolean set_freq_component(gdouble* comp_buf, gdouble* dst_buf, gint place,
-                            gint samples);
+                            glong samples);
 
 gboolean
 get_rgba_component(gdouble* src_buf, gdouble *comp_buf, gint place,
-                   gint samples)
+                   glong samples)
 {
   src_buf += place;
   while (samples--)
@@ -39,7 +39,7 @@
 }
   
 gboolean
-set_rgba_component(gdouble* comp_buf, gdouble* dst_buf, gint place, gint samples)
+set_rgba_component(gdouble* comp_buf, gdouble* dst_buf, gint place, glong samples)
 {
   dst_buf += place;
   while (samples--)
@@ -52,7 +52,7 @@
 
 gboolean
 get_freq_component(gdouble* src_buf, gdouble *comp_buf, gint place,
-                   gint samples)
+                   glong samples)
 {
   src_buf += place*2;
   while (samples--)
@@ -66,7 +66,7 @@
   
 gboolean
 set_freq_component(gdouble* comp_buf, gdouble* dst_buf, gint place,
-                   gint samples)
+                   glong samples)
 {
   dst_buf += place*2;
   while (samples--)

Modified: branches/branch_zhangjb/tests/frequency/hello-world-fourier.c
==============================================================================
--- branches/branch_zhangjb/tests/frequency/hello-world-fourier.c	(original)
+++ branches/branch_zhangjb/tests/frequency/hello-world-fourier.c	Thu Jun 26 13:19:57 2008
@@ -12,19 +12,22 @@
     char image_3[50] = "tests/images/lena_bw_10x9.png";
     char image_4[50] = "tests/images/lena_bw.png";
     char image_5[50] = "tests/images/lena_rgb.png";
+    char image_6[50] = "tests/images/lena_rgb_5x5.png";
+    char image_7[50] = "tests/images/lena_rgb_4x4.png";
+    char image_8[50] = "tests/images/lena_bw_4x4.png";
 
     GeglNode *display = gegl_node_create_child(gegl, "display");
     GeglNode *image = gegl_node_new_child(gegl,
                                           "operation",
                                           "load",
                                           "path",
-                                          image_5,
+                                          image_8,
                                           NULL);
     GeglNode *dft = gegl_node_new_child(gegl, "operation", "dft", NULL);
     GeglNode *idft = gegl_node_new_child(gegl, "operation", "dft-inverse",
                                          NULL);
-    GeglNode *preview = gegl_node_new_child(gegl, "operation",
-                                            "preview-frequency", NULL);
+    /* GeglNode *preview = gegl_node_new_child(gegl, "operation",
+                                            "preview-frequency", NULL);*/
     GeglNode *grey = gegl_node_new_child(gegl, "operation", "grey", NULL);
     GeglNode *save = gegl_node_new_child(gegl,
                                          "operation",
@@ -33,7 +36,7 @@
                                          "test_result.png",
                                          NULL);
 
-    gegl_node_link_many(image, dft, preview, save, NULL);
+    gegl_node_link_many(image, dft, idft, save, NULL);
     gegl_node_process(save);
 
     g_object_unref(gegl);

Added: branches/branch_zhangjb/tests/images/lena_bw_4x4.png
==============================================================================
Binary file. No diff available.

Added: branches/branch_zhangjb/tests/images/lena_rgb_4x4.png
==============================================================================
Binary file. No diff available.

Added: branches/branch_zhangjb/tests/images/lena_rgb_5x5.png
==============================================================================
Binary file. No diff available.



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