[GRASS-SVN] r38634 - in grass/trunk/lib/vector: Vlib diglib

svn_grass at osgeo.org svn_grass at osgeo.org
Fri Aug 7 14:28:29 EDT 2009


Author: mmetz
Date: 2009-08-07 14:28:29 -0400 (Fri, 07 Aug 2009)
New Revision: 38634

Modified:
   grass/trunk/lib/vector/Vlib/open.c
   grass/trunk/lib/vector/diglib/plus.c
   grass/trunk/lib/vector/diglib/spindex.c
Log:
sidx initialization consistent with topo initialization

Modified: grass/trunk/lib/vector/Vlib/open.c
===================================================================
--- grass/trunk/lib/vector/Vlib/open.c	2009-08-07 15:30:43 UTC (rev 38633)
+++ grass/trunk/lib/vector/Vlib/open.c	2009-08-07 18:28:29 UTC (rev 38634)
@@ -848,8 +848,6 @@
 	/* initialize spatial index */
 	Map->plus.Spidx_new = 0;
 
-	dig_spidx_init(Plus);
-
 	/* load head */
 	if (dig_Rd_spidx_head(&(Map->plus.spidx_fp), Plus) == -1) {
 	    fclose(Map->plus.spidx_fp.file);
@@ -884,8 +882,6 @@
 	/* open new spatial index */
 	Map->plus.Spidx_new = 1;
 
-	dig_spidx_init(Plus);
-
 	if (mode == 1) {
 	    /* load spatial index for update */
 	    if (dig_Rd_spidx(&(Map->plus.spidx_fp), Plus) == -1) {

Modified: grass/trunk/lib/vector/diglib/plus.c
===================================================================
--- grass/trunk/lib/vector/diglib/plus.c	2009-08-07 15:30:43 UTC (rev 38633)
+++ grass/trunk/lib/vector/diglib/plus.c	2009-08-07 18:28:29 UTC (rev 38634)
@@ -95,7 +95,7 @@
     Plus->Volume_spidx_offset = 0L;
     Plus->Hole_spidx_offset = 0L;
 
-    /* dig_spidx_init(Plus); */
+    dig_spidx_init(Plus);
     dig_cidx_init(Plus);
 
     return 1;

Modified: grass/trunk/lib/vector/diglib/spindex.c
===================================================================
--- grass/trunk/lib/vector/diglib/spindex.c	2009-08-07 15:30:43 UTC (rev 38633)
+++ grass/trunk/lib/vector/diglib/spindex.c	2009-08-07 18:28:29 UTC (rev 38634)
@@ -38,7 +38,6 @@
     ndims = Plus->with_z ? 3 : 2;
 
     G_debug(1, "dig_spidx_init()");
-    G_debug(1, "Plus->spidx_separate = %d", Plus->Spidx_new);
 
     Plus->Node_spidx = RTreeNewIndex(ndims);
     Plus->Line_spidx = RTreeNewIndex(ndims);
@@ -56,6 +55,8 @@
     Plus->Volume_spidx_offset = 0L;
     Plus->Hole_spidx_offset = 0L;
 
+    Plus->Spidx_built = 0;
+    
     return 1;
 }
 



More information about the grass-commit mailing list