[OSM-talk] osmarender bounding box cropping

Thom Shannon thom at glow-internet.com
Tue Oct 30 16:12:10 GMT 2007


Yes I am basically building a custom tile maker here! I should probably 
just hack a copy of tiles at home, I used to do a lot of perl so I'll have 
a crack at that. Thanks

Dirk-Lüder Kreie wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Thom Shannon schrieb:
>   
>> When you download your osm data based on a bounding box you get the 
>> whole of any ways with nodes in that box, which is of course quite 
>> sensible. But when you render your SVG, the map you were hoping up ends 
>> up down in the corner somewhere because of a big bit of coast or 
>> motorway sticking out.
>>
>> I'm thinking if I go through the nodes in the osm data and find the 
>> extreme outer points in all four directions, then work backwards I can 
>> figure out the coordinates in the SVG document where my original 
>> bounding box would be. The only problem is I'm not sure what kind 
>> projection osmarender uses to convert the lat/lon coords to a grid.
>>
>> Any ideas on the best way to do this?
>>     
>
> This is the exact same problem tilesAtHome has solved already. I'd have
> to look at the code to tell you what exactly is done. to get the right
> bbox...
>
> - --
>
> Dirk-Lüder "Deelkar" Kreie
> Bremen - 53.0952°N 8.8652°E
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.7 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFHJ1WGFUbODdpRVDwRAt4VAKCfnNgKHmdWo1LLJcei3Ahac0FWJwCdFScM
> eQgAdxR3DGahJK45eEekCYs=
> =5ZPA
> -----END PGP SIGNATURE-----
>
>
>   

-- 
*** OPEN COFFEE 6 - with FACT - http://upcoming.yahoo.com/event/307022 ***

Glow New Media
t: 0151 707 9770
m: 07730 987 574
www.glow-internet.com

Suite 712 Gostins Building
32-36 Hanover Street
Liverpool
L1 4LN

Map: http://tinyurl.com/2f5nxd
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/talk/attachments/20071030/44dc88f9/attachment.html>


More information about the talk mailing list