]> mj.ucw.cz Git - libucw.git/blobdiff - images/sig-txt.c
experiment - store relative centroid position for each image region
[libucw.git] / images / sig-txt.c
index 0429b7390162c31e9938b7fc829690600f33e180..0202e601d2ff294bdb51e48b9884a265abd917f2 100644 (file)
@@ -7,7 +7,7 @@
  *     of the GNU Lesser General Public License.
  */
 
-#define LOCAL_DEBUG
+#undef LOCAL_DEBUG
 
 #include "sherlock/sherlock.h"
 #include "images/images.h"
@@ -31,6 +31,12 @@ image_sig_detect_textured(struct image_sig_data *data)
   uns i, j;
   u32 cnt[IMAGE_REG_MAX];
 
+  if (cell_cols * cell_rows < 4)
+    {
+      DBG("Image is not textured.");
+      return;
+    }
+
   DBG("Detecting textured image... cols=%u rows=%u cell_cols=%u cell_rows=%u", cols, rows, cell_cols, cell_rows);
   
   /* Compute cells boundaries */