[Tilesathome] t at h server next generation

Kai Krueger kakrueger at gmail.com
Sun Jul 6 15:07:58 BST 2008


The new server code looks good, so it would be great to see it go live 
at some point.

> Tileset file description
> ========================
> I have a converter that converts the single tiles into tileset files. Tileset files contain.
> 
> 0: a tileset file version(currently 1), so I can modify the file format at a later point
> 2: user id of user who uploaded the thing
> 4: offset of tile 1 (z0x0y0)
> 8: offeset of tile 2  (z1x0y0)
> 12 offset of file 3 (z1x1y0)
> ...
> 5468:offset after tile 1365(points to end of file)
> 5472:data png1

Do you think it would make sense to add some more metadata to the file? 
E.g. client version number

Another useful piece of information might be to have the min_z and max_z 
values in the structure. Given that not all layers have the same number 
of zoom levels, I guess one needs the information of how many tiles 
should be in the tileset.

Will the caption / captionless layers cause any problems? Aren't those 
zoom levels a bit strange with respect to the z0, z6 and z12 structure 
of the tilesets?

> ...
> 
> offset is either a pointer to the file position where the png data is, or it can also be a blankness value:
> 0=unknown
> 1=land
> 2=sea
> 3=transparent (not implemented yet)

Hmm, I think there is a tiny bug in the serve_tiles.py, it checks for 
the offset being larger than 1 for special case tiles. Both sea and 
transparent tiles would therefore try and load a tile with an invalid 
offset. Shouldn't it be greater than 3?

> 
> There are no recursive blankness lookups, all blank tiles in a tilesetfile will have the blankness set. I plan to maintain a database of completely blank tilesets, to save the 6kb files in the pacific ocean etc, but that's not implemented yet.

It seems like the oceantiles file is a good start for a database of 
blank tiles info. I have attached a patch (in case this is useful), that 
in the case of not finding a tileset, looks up the info in the 
oceantiles file. For zoom levels 12 and higher, it simply returns the 
sea/land type specified in the oceantiles file. For lower level files it 
will check to see if all corresponding z12 tiles are of the same type, 
in which case it returns that type. Otherwise it returns unknown.


I was wandering what the plans for the transition period are. I have 
seen that you have a converter script to take the existing tiles and 
convert them to the one file per tileset. Are you planning on converting 
all of the files during transition or, will the two types of tiles go 
side by side? Adding a fall-back to the serve_tiles.py shouldn't be hard 
in case of gradually transitioning.

Kai

> 
> spaetz
> 
> P.S. I will try to put all this in the wiki soon

That would be great. A short instruction of how to get all of this 
running might be good as well.

> 
> _______________________________________________
> Tilesathome mailing list
> Tilesathome at openstreetmap.org
> http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/tilesathome


-------------- next part --------------
A non-text attachment was scrubbed...
Name: blankness.patch
Type: text/x-diff
Size: 2185 bytes
Desc: not available
URL: <http://lists.openstreetmap.org/pipermail/tilesathome/attachments/20080706/ea533c58/attachment.patch>


More information about the Tilesathome mailing list