WKT Invalid

Feb 15, 2015 at 3:56 PM
I am using a shape file that I want to output the WKT of my shapes. Using QGIS I get a WKT. Using Shape2SQL, I get a similar WKT for the shape, but not exact. Using DotSpatial, I am getting yet a third format. However, with DotSpatial, the STIsValid returns false, while the other packages return true/valid.

Here is the code I am using to get the WKT. Is there just a bug in the WKT routine that it creates invalid text? Or, if it is Invalid, should I do a MakeValid on it? Visually, the shapes come across as identical, but the actual points in the polygons are slightly different. That worries me.

var shape = fs.GetShape(i, true);
                    var geometry = shape.ToGeometry();
                    var wkt = writer.Write((Geometry)geometry);