Andrea,

Many thanks for your feedback, detailing the various drawbacks. Having given 
the idea some thought myself while off-line, I reckon the current approach is 
good as it is. Indeed, you want point symbols to have the same size 
irrespective of the markfactory or font-specific metrics. If you want to use a 
font and its metrics, I should use the TextSymbolizer instead.

Kind regards,

Edward

Date: Thu, 2 Aug 2012 09:20:34 +0200
Subject: Re: [Geoserver-users] Character size difference TextSymbolizer vs 
PointSymbolizer w/ TTFMarkFactory
From: [email protected]
To: [email protected]
CC: [email protected]

On Wed, Aug 1, 2012 at 8:44 PM, Edward Mac Gillavry <[email protected]> 
wrote:






Andrea,

Many thanks for confirming my observations. Your explanation of the inner 
workings certainly indicates it is font-specific. If I understand it correctly 
in case of the TTFMarkFactory, the first scaling transformation (so the largest 
side of the bbox becomes size 1) introduces the seemingly random adjustment 
factor?



Would changing the current behaviour introduce any unforeseen/unwanted effects? 
From a cartographic design point of view, it would be great to have 
these two symbolizers have the same, predictable output size.


Every mark factory is supposed to generate a 1x1 symbol, changing that would 
break the current API...
I could go for that, but there is a side effect that is grave: it would 
invalidate all exisiting SLD styles


already using this functionality, forcing every user to manually re-adjust 
their SLDs on upgrade.

I can see two ways forward if someone wants to code that change:
- make the new behaviour controlled by a global flag, and disabled by default


- add an extra bit in the ttf:// url that disables the rescaling, something 
like ttf://myfont#code?rescale=false

I cannot guarantee that would give you exactly the same size though, one thing 
is getting
a Font object at size 1, vectorize and rescale, then scale up to the desired 
size(the rescaling to the desidered size is done out of the shape factories, 
the factories are supposedto give out rescalable vector representations so it's 
not their responsibility to match the requested
size), another is asking for a font at a specific size instead.
Cheers
Andrea

-- 
==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for more 
information.==
Ing. Andrea Aime @geowolf

Technical Lead
GeoSolutions S.A.S.Via Poggio alle Viti 118755054  Massarosa (LU)Italyphone: 
+39 0584 962313
fax:   +39 0584 962313
mob:   +39  339 8844549
http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------
                                          
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to