Open gwlucastrig opened 1 year ago
The main problem turned out to be the shapefile index file (the .shx file). Tinfour's ShapfileWriter updated the record-indexing section of that file, but it did not update the coordinate bounds section in the index file header. QGIS treated this as meaning that the geometry for the shapefile was not available. However, the ShapefileWriter did correctly update the same section of the main file (the .shp file). So I simply consolidated the code for performing flush operations on the two files into a single method that was used consistently for both.
I have pushed up changes for the shapefile-related classes.
I am still investigating some geometry validation errors being reported about the contour files. The cause is not yet known.
Recent attempts to import the contour-files output from the SVM module into QGIS failed due to geometry problems in the shapefiles produced by SVM. Problems were traced back to two sets of errors. First, some of the contours produced by the ContourBuilder had self-intersecting lines. Second, the API for writing shapefiles has some coding errors. This issue proposes to fix both these problems.