Hi Jin,

> can we crop a grid using a irregular polygon rather than a bounding box?

If you want to keep the grid as a grid then you're stuck with a
rectangular boundary.

A couple of options:

1. create a new grid with values equal to the source grid within the
polygon and some "no data" value (Double.NaN for instance) outside

2. sample the grid within the polygon and save the resulting values as
a collection of vector features (points or rectangular polygons).

Do either of those fit your use case ?

Michael

------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to