Hi Michaël, you point out the right troubles.

First I'd like to explain my idea for moving vertex and this could be
generalized.

It could be added a new snap option for Z vertex destination (snap Z for now)

With this option checked if you move a selected vertex on an existing
one it takes the Z of the destination vertex otherwise it takes just x
and y and keeps its Z.

And this snap can be use also for other behavior.

for intersection: with the snapZ the new vertex created from
intersection has the same Z of the interpolated points (mean of the Z
for instance or better one of them), but in my experience I don't need
that the new vertex has the same Z but surely I need that the it
constructs 2 new vertex in the interpolation point with same x and y,
and with 2 Z derived from the interpolation of the 2 line and so not
equal.

For union some aspect can be solved same way.

for JTS
Is not possible tho extend the JTS interpolation class to add this
feature keeping the same behavior for x and y so you can just switch
to this new class in the plugin without other changes?

Thanks all for going on whit this topics.

Luca


2009/12/11 Michaël Michaud <michael.mich...@free.fr>:
> Larry Becker a écrit :
>> I have added z interpolation to the "Add Vertex" tool for most
>> "normal" cases.  There are some boundary cases that still won't work
>> without further mods.  I have made those modifications to CoordUtil,
>> but won't commit them until the other developers approve since they
>> are called by many classes.  It is attached.
> Hi Larry an Luca,
>
> Thanks to Larry for this addition.

Thanks a lot from me too Larry!

> I think that in the second method average(Collection coordinates), the test
> if (Double.isNaN(coordinate.z))
> should be
> if (!Double.isNaN(coordinate.z))
>
> About the general request from Luca, I think there are many places where
> z can be handled in a better way, but one problem is that JTS algo don't
> interpolate z and what can be done for the Add Vertex Tool may be hard
> to generalize to other plugins :
> Examples :
> Intersection between linestring in a layer : I think z should be
> interpolated, but the plugin heavily use JTS so that interpolation may
> not be easy

> Union : added vertex may have two different interpolated z coming from
> two different geometries : what to do in this case ? choose one
> solution, a mean value or NaN ?
>
> Snap  new vertex to a feature with z : what to do if several points with
> different z are located where one want to snap ?
>
> My 2 cents
>
> Michaël

------------------------------------------------------------------------------
Return on Information:
Google Enterprise Search pays you back
Get the facts.
http://p.sf.net/sfu/google-dev2dev
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to