I’m trying to use mapproject to calculate distances from a point, and it looks as if the parsing options are getting mixed up, or at least are inconsistent with the documentation. I get equivalent results using 5.4.4 from the Centos 7 repository and from 6.0.0 built from source.
-G+v should calculate the positions between points in cols 1,2 and 3,4, but unless I specify a dummy fixed point as well it also then accumulates the distances, ie -G+v doesn’t produce expected results but -G0/0+v does. The point here is irrelevant, so I guess it means that the code when
if (n_slash == 1)
isn’t satisfied is going astray.
It looks as if in each of the other routes through the code GMT_MP_CUMUL_DIST is forced active unless GMT_MP_INCR_DIST has been explicitly chosen.
So to get the output that the doc suggests for -G+v I actually need to use -G+v+i
Similarly, the docs suggest that -G0/0 will give me distances from (0,0). However unless I add an apparently redundant optional parameter such as -G0/0+ue the code goes into old_G_parse and gives cumulative distances unless I use -G0/0/e- or similar.
-G0/0+ue does what I expect, but at present supplying 0 0 as columns 3,4 option -G+v+ue gives different result. Possibly -G+v should assume +i was intended unless +a was used?