[Mapserver-users] WMS Problems...

Daniel Morissette dmorissette at dmsolutions.ca
Wed Mar 3 12:27:08 PST 2004


(Should we move this discussion to mapserver-dev?)

Frank Warmerdam wrote:
> 
> OK, looking in the code I see the following logic. Basically, because the
> WMS 1.0.0 format names are ideosyncratic I guess someone (perhaps me?) made
> the decision to just hardcode and support a few formats.   

That was me.  (Not the decision on the format names, but the limited 
implementation)


> 
> One is, should we fix 1.0.0 WMS support to emit entries for all
> declared formats?  Perhaps using the name of the outputformat
> converted to upper case?  This would give us the "well known" names
> for the default GIF, PNG and JPEG formats and would allow arbitrary
> other formats to be listed.
> 

That would be a good idea... as Frank suggested, a bug should be filed 
if someone really cares about custom formats being listed in WMS 1.0.0


> The other issue is that there is currently no way to prevent the various
> internally declared formats from appearing.  Basically, all the standard
> formats (if built in) will appear regardless of what output formats are
> declared in the map file.  The predefined ones are listed here (from
> mapoutput.c):
> 

There is already bug 455 which is indirectly related to that issue:

http://mapserver.gis.umn.edu/bugs/show_bug.cgi?id=455

> 
> If you see a need for being able to avoid pre-defined formats from
> showing up in the list in the capabilities then file another bug
> about this, but I think we should talk a bit about how to accomplish
> it without too much disruption.
> 

One possibility could be a flag in the outputformat object that 
indicates whether a given format should be visible in capabilities.  The 
set of pre-defined formats would have some valid default settings so 
that things like text/xml doesn't appear in capabilities (see bug 455)

In a previous message, Frank also wrote:
> 
> It seems to me there is some way of adding options to mime types.  Perhaps
> we could have something like a mime type of "image/tiff+24bit" or something.
> Anyone know more about this?
> 

There was a thread on this on WMS-Dev back in June/July of 2002:

http://www.intl-interfaces.net/pipermail/wms-dev/2002-June/000180.html

There were two proposals, one by you (Frank):

    <Format>image/png</Format>
    <Format>image/png; name=png8</Format>
    <Format>image/png; name=png24></Format>

and one by Craig Bruce from Cubewerx:

   image/png; PhotometricInterpretation=PaletteColor; SamplesPerPixel=1;
              BitsPerSample=8
   image/png; PhotometricInterpretation=RGB; SamplesPerPixel=3;
              BitsPerSample="8,8,8"
   image/png

It seemed that everyone agreed on the passing of additional parameters, 
but not on the name of the parameters to use.

Jeff DLB concluded that email thread by saying that he would include a 
note in the WMS spec.  I found the following note in the WMS 1.3.0 
discussion paper:

---
   The basic structure of a MIME type is a string of the form
   "type/subtype". MIME allows additional parameters in a string
   of the form "type/subtype; param1=value1; param2=value2". A server
   may include parameterized MIME types in its list of supported
   output formats. In addition to any parameterized variants, the
   server should offer the basic unparameterized version of the format.
---

However I didn't find anything specific to the name of the parameters to 
use to describe 8 bits vs 24 bits for instance.

Daniel
-- 
------------------------------------------------------------
  Daniel Morissette               dmorissette at dmsolutions.ca
  DM Solutions Group              http://www.dmsolutions.ca/
------------------------------------------------------------




More information about the MapServer-users mailing list