[geotk] Re: Get envelope for a scale
martin.desruisseaux at geomatys.fr
Mon Sep 7 06:18:29 EDT 2009
Theuns Heydenrych a écrit :
> What exactly does this number mean, is it the size of a pixel
> representing one meter?
It is the amount of pixels in one metres. The inverse (23560) is the "real
world" size in metres of one pixel.
In order to compute a map scale, you need to know the physical size of one pixel
on your screen device. There is some API in Java2D that are supposed to give you
this information, but it seems to often fallback on 1/72 of inch as a default value.
If "ps" is the physical size in metre of one pixel on your screen, then
scale(objectiveToDisplay) * ps
should give you the map scale.
More information about the Geotoolkit