[mkgmap-dev] Splitter details question
From Chris Miller chris.miller at kbcfp.com on Wed Jan 13 08:11:27 GMT 2010
Hi WanMil, W> ok, I understand. W> For me it's no problem if points that fall outside the bounding box W> are included in the tile. They can be easily filtered. W> I have the following requirements: W> 1st and most important: All nodes that fall inside the bounding box W> should reliably be contained in the tile. In my previous mail I W> mentioned two nodes where this wasn't the case. Ah, I hadn't realised this from your original description, apologies for missing that. Indeed, this should not be happening. Would it be possible for you to make the OSM file you're using available, or send me a link to it? It's not obvious to me why nodes are being excluded so having the same OSM file as you will make debugging much easier. W> 2nd: Ways should be included if they intersect the bounding box. W> For me it would be perfect if ways are included with all nodes. But I've investigated doing this in the past however it's very tricky to do correctly without having a huge impact on performance and/or memory requirements. I do have one idea that might work without too much slowdown. If I was to build up a big disk index of all nodes (there is already a disk cache of node details, but it's not currently indexed), I could then lookup all nodes that weren't found in the current tile and write them out too. It's a reasonable amount of work to build the b-tree index efficiently but it's sort-of on the todo list already anyway since I'm aware of other uses for something like this too. W> it W> is also ok if all inner nodes and for all parts of the way the first W> node out of the bounding box is included. This enables me (and W> others) W> to calculate the intersection point with the bounding box. Sure, as I understand it that's why the overlap handling exists in the first place. As it currently stands it's not robust though, there are various corner cases where it gets things wrong (eg if the first node of a way that falls outside a tile also falls outside the overlap area then the way will appear to stop before the tile edge). I can think of a few ways to improve the splitter to help with this, will try to take a look once I find a bit of spare time. Cheers, Chris
- Previous message: [mkgmap-dev] Splitter details question
- Next message: [mkgmap-dev] Splitter details question
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the mkgmap-dev mailing list