[OpenMap Users] Re: OmScalingRaster

From: Don Dietrick <dietrick_at_bbn.com>
Date: Wed, 8 Dec 2004 09:18:33 -0500

Hi David,

There are two parts to this. The first part of making the
OMScalingRaster working accurately involves using a cylindrical equal
arc projection, where the lat/lon changes are constant in both
directions. The only two OpenMap projections that fall into this
category are the LLXY projection and the CADRG projection. In the
mercator projection, as an example of what isn't acurate, the changes
in latitude are not constant across vertical pixels.

Since all images have their own inherent projection, the
OMScalingRaster needs to also contain an image where the pixels reflect
constant change in lat/lon in order to be totally accurate.

If these two thing are true, then the image will appear to be made for
the displayed map and will scale properly. If either of these two
things are not true, you may see some errors, or differences when you

Your other option is to do what the
com.bbn.openmap.plugin.earthImage.EarthImagePlugIn, where a new image
is created for every projection change, and the source image is
consulted for pixel values at every lat/lon - this warps the source
image to any displayed projection. But you need to be able to figure
out the pixel coordinates of the source image, which is why that plugin
assumes a -180/90 to 180/90 mercator projection for the source image
(it's somewhat common to find images like that for the earth).

Hope this helps,


On Dec 6, 2004, at 3:40 PM, Marklund David wrote:

> Hi all,
> I have asked this before, but since I have not got it working yet, I
> will ask again.
> I am using a OMScalingRaster to display a depth colored layer.
> (http://labba.smhi.se/seatrack user openmap, passwd openmap)
> The depth layer does not seem to center around the same point each time
> you zoom or pan.
> It looks like the depth layer moves a bit compared to the coastline and
> other layers.
> This from the source file of OMScalingRaster
> * This is an extension to OMRaster that automatically scales itelf to
> * match the current projection. It is only lat/lon based, and takes
> * the coordinates of the upper left and lower right corners of the
> * image. It does straight scaling - it does not force the image
> * projection to match the map projection! So, your mileage may vary
> * - you have to understand the projection of the image, and know how
> * it fits the projection type of the map. Of course, at larger
> * scales, it might not matter so much.
> But what does this mean ? 'Understand the projection of the image'
> What should I look for ?
> /
> David

Don Dietrick, dietrick_at_bbn.com
BBN Technologies, Cambridge, MA

[To unsubscribe to this list send an email to "majdart_at_bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Wed Dec 08 2004 - 09:19:40 EST

This archive was generated by hypermail 2.3.0 : Tue Mar 28 2017 - 23:25:06 EDT