logo separator

[mkgmap-dev] More method options for is_in function

From Ticker Berkin rwb-mkgmap at jagit.co.uk on Mon Feb 10 17:09:59 GMT 2020

Hi Gerd

I've re-implemented the POINT test within IsInFunction, using the
stopping methods etc, which are now coded, but only relevant for this
context at the moment. This implementation has other advantage in that
the method can control the onBoundary condition. Also the logic in
calcInsideness can give the wrong answer for POINT is_in(..., 'on').

I didn't want to change IsInUtil while you are working on it and I'm
not sure yet of the best way to handle the LINE/POLYGON versions.

There are a couple of aspects of these that occur to me:

It would be clearer to test for kind=POINT/LINE/POLYGON etc rather than
el instanceof.

w.isComplete(): 
- Will this will cause different answers depending on tile splitting,
or is the complete polygon represented; even the bits outside the tile?
- The ANY methods should be processed and will be correct.

Thanks for spotting my error with tstMethod.

This patch also improves the method error message; listing the possible
methods for the context.

Ticker

On Mon, 2020-02-10 at 13:14 +0000, Gerd Petermann wrote:
> Hi all,
> 
> see 
> http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4442
> 
> @Ticker:
> I assume you are working on an alternative implementation of the
> methods in IsInUtil?
> If not I'd like to remove all the code duplication introduced with
> the last patch.
> 
> Gerd
> _______________________________________________
> mkgmap-dev mailing list
> mkgmap-dev at lists.mkgmap.org.uk
> http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: is_in-function_v7.patch
Type: text/x-patch
Size: 5891 bytes
Desc: not available
URL: <http://www.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20200210/4944e86a/attachment.bin>


More information about the mkgmap-dev mailing list