kml2gmt re-uses previous <name>...</name> value
|Target version:||Candidate for next bugfix release|
If there is a missing <name>...</name> KML tag kml2gmt re-uses previous name tag value or dreams up what he wants.
I'll prefer a -L"" or no -L at all.
Also in the second example, the coordinates are replaced with 0,0.
Examples files attached. I've tested the KML examples with Google Maps and ogr2ogr without complains.
#1 Updated by Paul about 6 years ago
- Status changed from New to Resolved
- Assignee set to Paul
I now reset the internal name and description to NULL after each output coordinate so now there will be no -L or -D is none is set via <name> and <description>.
Also, there was an assumption that single points would be listed on one line as <coordinates>x,y,z</coordinates> and not as in your basic.kml example. We now consider both possibilities. In r13543, let me know if OK for you.
#2 Updated by Anonymous about 6 years ago
<Folder> <name>Point Features</name> <description>Point Features</description> <Placemark> <description>CAPA</description> <styleUrl>#point11</styleUrl> <Point> <coordinates>-57.9407034317,-34.943600809,0</coordinates> </Point> </Placemark>
the first <Placemark> has not a <name> but kml2gmt is using the value which appears after <Folder>, the other <Placemark> instances are fine.
In basic.kml, the coordinates are fine, but why appears Next Point in the segment separator?
#4 Updated by Anonymous about 6 years ago
The option -Fs|l|p works great!
With this KML file
<?xml version="1.0" encoding="UTF-8"?> <kml xmlns="http://earth.google.com/kml/2.2"> <Document> <Placemark> <Point> <coordinates> -1.5,55 </coordinates> </Point> </Placemark> </Document> </kml>
> Next Point -1.5 55
That is the program intent as I can see in
if (!GMT->current.io.segment_header) sprintf (GMT->current.io.segment_header, "Next Point");