[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [udig-devel] thoughts about projection
|
Hi Andrea,
The default projection of the uDig map is lat-long (unless you change
the preferences). But the FeatureStore always returns the features
in the same projection as the layer (at least right now). It is a
pain and there is work to make Query's take a Destination CRS so that
you can request the projection from the datastore and not have to
reproject. But that has to be put in all the datastores so will take
a little while yet.
To reproject a Geometry:
JTS.transform( Geometry, MathTransform ).
A transform can be created from a layer or by calling:
CRS.findMathTransform( from, to )
Jesse
On Apr 22, 2007, at 6:40 PM, Andrea Antonello wrote:
while I was testing a piece of code it occurred to me the following:
- I had loaded a grass raster, which was in gauss-boaga (I loaded that
first, since that doesn't support on the fly reprojection)
- after that I loaded a shapfile in UTM
- they fit perfectly
- the piece of code at a certain point needs to get the elevations of
the shape nodesextracted from the raster (dtm)
What happens is that the features I got from the layer are in their
original reference system and obviously do not fit the raster.
Is that how it should be? I was expecting to get what I saw.
Anyone any thought about that?
Thanks,
Andrea
_______________________________________________
User-friendly Desktop Internet GIS (uDig)
http://udig.refractions.net
http://lists.refractions.net/mailman/listinfo/udig-devel