On Wed, May 19, 2010 at 2:19 PM, Duane Zamrok <[email protected]> wrote:
> Thank you for the quick response, but I think you may have misunderstood my 
> question. The link that you sent me appears to deal with querying a database 
> for items whose location is within the bounds of a bounding box.

The last example contains the line
 polyCheck=ff.not(ff.disjoint(ff.property("the_geom"),ff.literal(
feature.getPrimaryGeometry() )));

which should be what you want. The joy of GeoTools is that it
abstracts the datastore you are using away from your code so it won't
matter what store you use, the code at the bottom of that page will
work on it.

>However, I'm not working with a database and my problem is much more closely 
>related to what coordinate system I should be using to perform the 
>calculations. From what I've read of JTS it is strictly a Cartesian geometry 
>library. It is unable to handle the transitions from -180 to 180 on the 
>longitude axis or the transition from -90 to 90 on the latitude axis. This 
>prompts me to believe that I must somehow transform my coordinates before 
>creating the polygon and doing the computation. However, I'm not sure what 
>coordinate system I should be using to maintain accuracy.
>

Someone else may be able to help you with that, I don't know if our
filters handle projections well (at all?).

Ian
-- 
Ian Turton

------------------------------------------------------------------------------

_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to