Opened 6 years ago

Closed 6 years ago

#1833 closed enhancement (fixed)

WCPS_Support clip() with corridor on 3D+ coverage by polygon/linestring

Reported by: Bang Pham Huu Owned by: Bang Pham Huu
Priority: major Milestone: 9.7
Component: petascope Version: development
Keywords: Cc: Dimitar Misev, Vlad Merticariu, bbell
Complexity: Medium

Description

The syntax will be:

clip(coverageExpression, 
     corridor(
       projection(axisLabel1, axisLabel2),
       lineString(point1, point2,...pointN), -- called a trackline and each point is a set of coordinates on coverage's axes. At least, point1's coordinates specified on axisLabel1 and axisLabel2 need to be inside the bounding box of polygon/linestring mask.
       polygon/linetring mask((point1, point2,...pointN) -- each point is a set of coordinates on 2 axes specified in projection()
       [, discrete] -- optional parameter to reduce the size of the first axis in the output by only returning the specified point in the trackline.
     ) 
     [, CRS ] -- optional parameter to transform for the mask from this CRS to coverage's geoXY axes' CRS.
   )

The output is always 3D for polygon/linestring mask. With domain of the first grid axis in the output is:
+ The length of the linestring (trackline) if discrete flag is not added.
+ The number of points specified in trackline if discrete flag is added.

Example of a corridor query in a 3D coverage with CRSs: time&EPSG:4326 and geo axes order (time, Lat, Long).

for c in (test_eobstest) return encode(
  clip(c,
     corridor(projection(Lat, Long),
              LineString("1950-01-01" 20 40, "1950-01-02" 30 50, "1950-01-03" 35 60),
              polygon((20 40, 20 60, 40 60, 40 40))
             ),
       )
     "csv")

The output of this coverage will have these CRSs: Index1D&EPSG:4326.

Change History (1)

comment:1 by Bang Pham Huu, 6 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.