[mapserver-users] mapcache of non-jpeg/png formats
Enzmann, Alexander R.
xander at mitre.org
Thu Jan 5 05:21:11 PST 2012
The JPEG and PNG formats are a subset of “web formats”. How about GIF, Tiff, SVG, PDF...? Also, if you look at what MapServer itself supports (especially if you include GDAL), mapcache only supports a small fraction of the raster formats you might generate. There’s also no reason not to cache vector content that can be geographically divided (e.g., geonames).
Mapcache (like TileCache, MapProxy, …) also behaves as a WMS server. In that regard it may be feeding a client that wants GeoTIFF, terrain information, etc. These clients (OpenLayers, Worldwind, Quantum GIS, …) typically are looking for tiles with standard geographic boundaries.
Re, "...help me think out of the box and give me a bit of context..."
When I use Worldwind as a part of an application, I can define raster and vector layers that are based on WMS or WFS sources. The raster layers are most often PNG format, but for terrain Worldwind uses BIL. Often the source terrain data is an ASC or greyscale GeoTIFF format with 16 bit integer "pixels" (they are posts, not pixels, but that's another discussion). Using MapServer I can provide a WMS service that automatically selects from high resolution terrain information where it exists, moderate over most landmasses (e.g., 1 arcsecond ASTER) or coarse anywhere on Earth (e.g., 30 arcsecond SRTM or GTOPO). The output terrain tiles are generated using the same resolution/hierarchy approach as image layers.
If the (currently "experimental") direct connection between mapcache and mapserver could be really exploited, then in the future it would be really nice to see mapcache providing a tiled/cached front end to everything that mapserver can do as a WMS/WFS server. In particular I would want to see the ability to generate terrain tiles and geographically bounded vector content.
I currently use other tile caching solutions together with MapServer, so it seemed reasonable to support one that has a direct relationship. Building and deploying to Apache was pretty straightforward - it looks like it is heading in the right direction.
Xander
-----Original Message-----
From: thomas bonfort [mailto:thomas.bonfort at gmail.com]
Sent: Thursday, January 05, 2012 4:16 AM
To: Enzmann, Alexander R.
Cc: mapserver-users at lists.osgeo.org
Subject: Re: [mapserver-users] mapcache of non-jpeg/png formats
On Wed, Jan 4, 2012 at 23:11, Enzmann, Alexander R. <xander at mitre.org> wrote:
> It appears that mapcache has exactly two supported storage formats, JPEG and
> PNG. Is there any way to have it store something else (e.g., TIFF, BIL)
> without adding explicit code like that in imageio_jpeg.c and imageio_png.c?
Explicit code would have to be added. In the general case, the imageio
functions take in an array of raw pixels (8bit unsigned rgba
quadruplets) and return the encoded data ready to be written to disk.
Conversely, they input an encoded stream of data and return an 8bit
rgba array.
>
> Any thoughts to having mapcache handle whatever formats GDAL supports, much
> like mapserver itself?
Can you help me think out of the box and give me a bit of context on
what you are trying to achieve? Mapcache serves image tiles to be
displayed on a browser, so any format other than png/jpg/gif is
currently out of scope.
That said, there would be no technical limitation in adding any other
image format for specific use-cases, provided the image data remains
8bit rgba. If you are aiming for supporting non 8bit data, the task
will become more involved as it will impact all the image manipulating
operations coded into mapcache (metatile chopping into single tiles,
and tile merging/assembling for full wms support).
--
thomas
>
>
>
> Xander
>
>
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
More information about the MapServer-users
mailing list