Hello all,

I'm having some problems reprojecting the MapContext.  Specifically, the
WMS layers are grabbed and put into the GraphicEnhancedMapContext, but
they are in WGS84.  For them to work correctly with Google, they need to
be in Google Mercator.  After the ReferencedEnvelope is done being
created in the map's CRS, the map is sent to a StreamingRenderer and the
image is sent out to savedimage1.jpg.

After the first image is created, the Google Mercator CRS is created
from the WKT created by Andrea, back in '08.  The old ReferenceEnvelope
and the new CRS are passed into CRS.transform(), spitting out an
Envelope that is used to created the new ReferenceEnvelope.  The new CRS
is set into the GraphicEnhancedMapContext, and the new map and
ReferenceEnvelope are sent into a new StreamingRenderer to be sent into
saveimage2.jpg

The problem is that the two images are identical.  When a given layer is
looked at with both projections via different calls to the GeoServer,
there is a noticeable difference.  However, for some odd reason the
second image looks like the first, the one created under WGS84.

If you would like, I could send in the code, but this is the basics of
it.  As there's not a whole lot of this type of problem being expressed
in the mailing lists, I'm not even sure I'm doing this correctly. The
CRS Lab would help with the features that I'm drawing on the map, but
does nothing for the WMS layers.

Any help would be appreciated,
Jeremiah
_____________________________________
Jeremiah Lewis

Programmer Intern, GIS Programming Unit

Dept. of Natural Resources, IRM Section
550 West 7th Ave., Suite 706
Anchorage, AK 99501
(907)269-8863
E-mail:[email protected]


------------------------------------------------------------------------------
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