On Tue, Feb 1, 2011 at 9:38 AM, Frank Gasdorf
<[email protected]> wrote:
> Hi List, Hi Jody
> First of all, sorry for cross-posting!
>
> Last Night I had a look at the iText Project [1] Jody has mentioned and I
> have to dive deeper to get a clue what it does and which part of the API is
> currently used by geotools/geoserver.
> What I like to get is a pdf file where the user could use (but not required)
> the free terrago toolbar [2] to measure distances and areas and type lat/lon
> coordinates to jump to locations within the pdf. But it is required to have
> CRS information about the data/content within the document. In addition it
> would be great to have layers in the hierarchy view (Index) and search
> capabilities on the feature content (attribute values).
> But however, would't that be nice features for all geoserver/geotools folks
> and end-users to get a ready to go pdf for the field and have these
> capabilities.
> Maybe some of you could point me to the code where the pdf stuff is taking
> place ... I'm going to read the adope pdf documentation [4] to find a hint
> if some TAGs are missed to act like a geopdf. And properly it's already
> supported by iText to create the meta information. An other relevant
> documentation is "PDF Geo-registration Encoding Best Practice Version
> 2.2" at OGC standards best practices home [3].
> Do you think we could create an enhancement in geotools/geoserver for that?

I don't know, didn't had the time to investigate the links you provided.
Howerver, the code that generates PDF in GeoServer is here:
http://svn.codehaus.org/geoserver/trunk/src/wms/src/main/java/org/geoserver/wms/map/PDFMapResponse.java

Basically we ask iText to give up a Graphics2D object and then we draw
on top of it as if it was a java2d one.

That does not give an occasion to do anything in between layers
getting rendered.
I guess one could split the map into n single maps, yet that would break
labeling solid (as it has to happen at the end of the rendering to
have all labels
conflict resolve with each other and stay on top).
That too can be handled somehow but it would require splitting the styles
into components with text symbolizers and components without....

As for setting in the necessary metadata, I hope iText provides the
necessary support for that (but I'm confident it might)

Cheers
Andrea

PS: ah, another possible hack is to create a custom label cache that
just wraps the standard one. This is because the label cache is informed
on layers starting and stopping being rendered.
Yet another possibility would be to make streaming renderer subclassable,
but it's not on purpose, not really though to be a base class

-- 
Ing. Andrea Aime
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584962313
fax:     +39 0584962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

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

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to