WCS 2.0.1 GetCoverage Subsetting request returns tiny image #5047

Closed
nmtoken opened this Issue Dec 8, 2014 · 7 comments

Comments

Projects
None yet
4 participants
@nmtoken

nmtoken commented Dec 8, 2014

WCS 2.0.1 subsetting request in MapServer 6.4.1 returns a tiny image. I can't work out if this is just a scaling issue or some other error.

WCS 2.0.1 GetCoverage ~ returns expected image

WCS 2.0.1 GetCoverage SUBSETing with lat(34.53627,38.88686) long(25.43366,31.32234) returns a tiny image

The same subsetting request on the same coverage (natively a 3-band tiff) using GeoServer returns the expected image.

GeoServer subsetting on the same coverage by comparison

@nmtoken

This comment has been minimized.

Show comment
Hide comment
@nmtoken

nmtoken Dec 8, 2014

I notice that if I supply the optional CRS part of the subset value I do get the expected image so this works

Requirement 27 of the WCS 2.0 specification tells me ... NO CRS parameter is foreseen in the core GetCoverage request; subsetting coordinates are always interpreted as being relative to the CRS in which the gml:Envelope coordinates are expressed; this CRS is listed in the srsName attribute of the gml:Envelope

In this instance the DescribeCoverage tells us that the CRS is http://www.opengis.net/def/crs/EPSG/0/4326, so this CRS shouldn't be required in the request.

<?xml version="1.0" encoding="ISO-8859-1"?>
<wcs:CoverageDescriptions xmlns:wcs="http://www.opengis.net/wcs/2.0" xmlns:ows="http://www.opengis.net/ows/2.0" xmlns:ogc="http://www.opengis.net/ogc" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:gml="http://www.opengis.net/gml/3.2" xmlns:gmlcov="http://www.opengis.net/gmlcov/1.0" xmlns:swe="http://www.opengis.net/swe/2.0" xsi:schemaLocation="http://www.opengis.net/wcs/2.0 http://schemas.opengis.net/wcs/2.0/wcsAll.xsd ">
  <wcs:CoverageDescription gml:id="BGS_EMODNET_AegeanLevantineSeas-MCol">
    <gml:boundedBy>
      <gml:Envelope srsName="http://www.opengis.net/def/crs/EPSG/0/4326" axisLabels="lat long" uomLabels="deg deg" srsDimension="2">
        <gml:lowerCorner>30.39790787 22.23541667</gml:lowerCorner>
        <gml:upperCorner>41.38958333 36.73542827</gml:upperCorner>
      </gml:Envelope>
    </gml:boundedBy>
    <wcs:CoverageId>BGS_EMODNET_AegeanLevantineSeas-MCol</wcs:CoverageId>

nmtoken commented Dec 8, 2014

I notice that if I supply the optional CRS part of the subset value I do get the expected image so this works

Requirement 27 of the WCS 2.0 specification tells me ... NO CRS parameter is foreseen in the core GetCoverage request; subsetting coordinates are always interpreted as being relative to the CRS in which the gml:Envelope coordinates are expressed; this CRS is listed in the srsName attribute of the gml:Envelope

In this instance the DescribeCoverage tells us that the CRS is http://www.opengis.net/def/crs/EPSG/0/4326, so this CRS shouldn't be required in the request.

<?xml version="1.0" encoding="ISO-8859-1"?>
<wcs:CoverageDescriptions xmlns:wcs="http://www.opengis.net/wcs/2.0" xmlns:ows="http://www.opengis.net/ows/2.0" xmlns:ogc="http://www.opengis.net/ogc" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:gml="http://www.opengis.net/gml/3.2" xmlns:gmlcov="http://www.opengis.net/gmlcov/1.0" xmlns:swe="http://www.opengis.net/swe/2.0" xsi:schemaLocation="http://www.opengis.net/wcs/2.0 http://schemas.opengis.net/wcs/2.0/wcsAll.xsd ">
  <wcs:CoverageDescription gml:id="BGS_EMODNET_AegeanLevantineSeas-MCol">
    <gml:boundedBy>
      <gml:Envelope srsName="http://www.opengis.net/def/crs/EPSG/0/4326" axisLabels="lat long" uomLabels="deg deg" srsDimension="2">
        <gml:lowerCorner>30.39790787 22.23541667</gml:lowerCorner>
        <gml:upperCorner>41.38958333 36.73542827</gml:upperCorner>
      </gml:Envelope>
    </gml:boundedBy>
    <wcs:CoverageId>BGS_EMODNET_AegeanLevantineSeas-MCol</wcs:CoverageId>
@sdlime

This comment has been minimized.

Show comment
Hide comment
@sdlime

sdlime Dec 18, 2014

Member

@Schpidi, another WCS one...--Steve

Member

sdlime commented Dec 18, 2014

@Schpidi, another WCS one...--Steve

@Schpidi

This comment has been minimized.

Show comment
Hide comment
@Schpidi

Schpidi Dec 23, 2014

Member

@nmtoken could you maybe test this with the current master? There we adjusted the subsetting syntax to the finally adopted extension. Now the parameter "subsettingcrs" is used to specify the CRS instead of giving it directly with the "subset" parameter. Not sure if your problem is solved there though. Maybe @constantinius could have look?

Member

Schpidi commented Dec 23, 2014

@nmtoken could you maybe test this with the current master? There we adjusted the subsetting syntax to the finally adopted extension. Now the parameter "subsettingcrs" is used to specify the CRS instead of giving it directly with the "subset" parameter. Not sure if your problem is solved there though. Maybe @constantinius could have look?

@constantinius

This comment has been minimized.

Show comment
Hide comment
@constantinius

constantinius Jan 7, 2015

Contributor

@nmtoken: Yes, MapServer currently does not conform to the standard. When no subsettingCrs is supplied, then the subsets will be treated as pixel-space subsets (and cast to integer). I think we implemented this during the time the standard was not fully adopted and we copied the functionality from the WCS 1.1 implementation. But I guess it is time to fix this.
@sdlime: You can assign this issue to me.

Contributor

constantinius commented Jan 7, 2015

@nmtoken: Yes, MapServer currently does not conform to the standard. When no subsettingCrs is supplied, then the subsets will be treated as pixel-space subsets (and cast to integer). I think we implemented this during the time the standard was not fully adopted and we copied the functionality from the WCS 1.1 implementation. But I guess it is time to fix this.
@sdlime: You can assign this issue to me.

constantinius added a commit to EOX-A/mapserver that referenced this issue Jun 2, 2015

constantinius added a commit to EOX-A/mapserver that referenced this issue Jun 2, 2015

@constantinius constantinius referenced this issue Jun 2, 2015

Merged

Issue5047 #5106

@Schpidi

This comment has been minimized.

Show comment
Hide comment
@Schpidi

Schpidi Jun 2, 2015

Member

@nmtoken please test and reopen if you find anything wrong. Thanks.

Member

Schpidi commented Jun 2, 2015

@nmtoken please test and reopen if you find anything wrong. Thanks.

@Schpidi Schpidi closed this Jun 2, 2015

@nmtoken
@Schpidi

This comment has been minimized.

Show comment
Hide comment
@Schpidi

Schpidi Jun 2, 2015

Member

@nmtoken sorry, I forgot to merge to master. Please use either latest branch-7-0 or master. Thanks.

Member

Schpidi commented Jun 2, 2015

@nmtoken sorry, I forgot to merge to master. Please use either latest branch-7-0 or master. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment