[OpenLayers-Users] Mercator and getLonLatFromPixel

Ben Brehmer bbrehmer at refractions.net
Wed Jan 24 11:46:33 EST 2007


Thanks for your help everyone.

Ben

Tim Schaub wrote:
>> Right now the getLonLatFromPixel() function returns a 
>> latitude/longitude which is incorrect since my map is 
>> actually projected in mercator.
>>     
>
> When you see getLonLatFromPixel() think getMapPointFromScreenPoint() and if
> the return is OpenLayers.LonLat, think OpenLayers.MapPoint.  The units of an
> OpenLayers.LonLat are the same as your map units (meters for mercator).
> Ignore the fact that LonLat makes you think of longitude, latitude, and
> decimal degrees.  Instead you should think of x, y, and map units.
>
>   
>> Thanks,
>>
>> Ben
>>
>>
>> _______________________________________________
>> Users mailing list
>> Users at openlayers.org
>> http://openlayers.org/mailman/listinfo/users
>>
>>     
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>   




More information about the Users mailing list