On Sun, Mar 29, 2015 at 12:53:27PM -0600, we recorded a bogon-computron
collision of the <[email protected]> flavor, containing:
>
> Thanks to Lee, K5DAT, who did the heavy lifting and testing of the new data
> sources, I have committed changes in CVS to support two new map sources now
> that we have deleted so many non-functional ones.
>
> "OSM_tiled_mapquest" is the mapquest rendering of OSM data.
This map is very pretty, but I just discovered that the data is incompatible
with how we do "png snapshots," or at least when used on a 24-bit TrueColor
display as I do.
Xastir dumps an XPM file of the current screen and uses GraphicsMagick or
ImageMagick to convert this XPM to PNG for the snapshot.
There is something about the image produced that GraphicsMagick hates,
complaining about an "Improper image header." ImageMagick's convert is happy
to convert the image, but the colors are all wrong. Either way, snapshots
are broken with the mapquest tiles.
This will not matter to you at all if you don't use PNG snapshots, but it
something to keep in mind if you do.
I certainly don't have time to investigate what is wrong with the map rendering
code and snapshot mechanism that makes this go wrong. It's got to be something
about how the .geo rendering code handles color space and chooses on-screen
pixel values. If someone wants to spend the time digging into it, that'd be
great. Otherwise, just be aware that if you want screen snapshots, you can't
use the mapquest tile server.
I do see, though, that there is a difference in the file format for the
same tiles from mapnik vs. mapquest:
> cd .xastir/OSMtiles/mapquest/14/3355
> identify 6489.png
6489.png JPEG 256x256 256x256+0+0 8-bit sRGB 6.58KB 0.000u 0:00.000
> gdalinfo 6489.png
Driver: JPEG/JPEG JFIF
Files: 6489.png
Size is 256, 256
Coordinate System is `'
Metadata:
COMMENT=CREATOR: gd-jpeg v1.0 (using IJG JPEG v62), quality = 80
Image Structure Metadata:
COMPRESSION=JPEG
INTERLEAVE=PIXEL
SOURCE_COLOR_SPACE=YCbCr
[...]
> pushd ~/.xastir/OSMtiles/mapnik/14/3355
> identify 6489.png
6489.png PNG 256x256 256x256+0+0 8-bit sRGB 254c 5.4KB 0.000u 0:00.000
> gdalinfo 6489.png
Driver: PNG/Portable Network Graphics
Files: 6489.png
Size is 256, 256
Coordinate System is `'
Corner Coordinates:
Upper Left ( 0.0, 0.0)
Lower Left ( 0.0, 256.0)
Upper Right ( 256.0, 0.0)
Lower Right ( 256.0, 256.0)
Center ( 128.0, 128.0)
Band 1 Block=256x1 Type=Byte, ColorInterp=Palette
Color Table (RGB with 254 entries)
0: 58,174,46,255
1: 52,175,72,255
[...]
253: 254,254,254,255
So mapquest is sending back full-color color jpeg tiles (even though identify
claims it's 8-bit), mapnik is returning true 8-bit png with 254 colors.
Somehow Xastir is scrambling the colors when it tries to create the XPM for
the mapquest version.
I also checked the fosm tile server, and these tiles are fine with snapshots.
It's just mapquest's JPEG tiles that break snapshots.
--
Tom Russo KM5VY SAR502 DM64ux http://www.swcp.com/~russo/
Tijeras, NM QRPL#1592 K2#398 SOC#236 http://kevan.org/brain.cgi?DDTNM
echo "prpv_a'rfg_cnf_har_cvcr" | sed -e 's/_/ /g' | tr [a-m][n-z] [n-z][a-m]
_______________________________________________
Xastir mailing list
[email protected]
http://xastir.org/mailman/listinfo/xastir