Re: [OpenMap Users] ImageTileLayer with large images

From: Don Dietrick <dfdietrick_at_gmail.com>
Date: Wed, 13 Oct 2010 09:32:36 -0400

Pete,

I ran some tests, and of course java handles the bmp files with a
world file - I modified the WorldFileImageReaderLoader to handle bmp
files. That change should be available soon.

To kind of echo what Chris said, I would only use the ImageTileLayer
for when you want to view a recently acquired image or set of images
on the map. If you are going to use many images as a background and
those images won't change that often, I would look into either using a
WMS server as Chris suggested, or using the MapTileLayer that uses
those tiles I wrote about earlier. The performance of the tiles is
really consistent over all scales. You can use GDAL to merge the
images and create the tiles (even from the bmp files, I think), or you
can use the com.bbn.openmap.dataAccess.mapTile.MapTileMaker.

The MapTileMaker takes whatever you have in a standard
openmap.properties file, and creates tiles from various layers at
different zoom levels (usually 1-14). You can add the
MapTileMakerComponent to the openmap.components property to see the
GUI front end for doing this, or you can run the MapTileMaker on a
properties file (javadocs explain how to add the appropriate
properties). The tiles are laid out the same way as OpenStreetMap
tiles, and can be deployed in a jar file. If you use the
MapTileMakerComponent, you can make settings for the different zoom
levels and see if your data is appropriate for different zoom levels.
Once you start getting to zoom level 13-14 and higher, the amount of
tiles created gets to be pretty large, so you'll want to run some
tests on a small number of tiles and look at them to make sure you're
not wasting your time.

- Don

On Wed, Oct 13, 2010 at 8:59 AM, Chris Allport <callport_at_dtiweb.net> wrote:
> Pete,
>
> Our program had some slightly different challenges with GeoTIFF, so we did things a little differently.  JAI is actually responsible for loading the GeoTIFFs themselves and is not needed for loading (and positioning) other types of geo-registered imagery.  Because of class loader issues, we did not want to include JAI, so we eliminated GeoTIFF support but still load geo-registered imagery as JPG (with JGW world files) and PNG (with PGW(?) world files).
>
> This, however, is really just a stop-gap solution for folks who really want the support for local files.  For our users, we recommend using a WMS Server (GeoServer) and loading all of their imagery (and additional databases, e.g. TIGER) into that.
>
> Regards,
>
> Chris
>
> -----Original Message-----
> From: Pete Flugstad [mailto:pete.flugstad_at_gmail.com]
> Sent: Monday, October 11, 2010 4:18 PM
> To: dfdietrick
> Cc: openmap-users_at_bbn.com
> Subject: Re: [OpenMap Users] ImageTileLayer with large images
>
> On Mon, Oct 11, 2010 at 1:47 PM, dfdietrick <dfdietrick_at_gmail.com> wrote:
>> The ImageTileLayer is at the mercy of JAI, and there are some images that,
>> for some reason, take a while to read.  I haven't found out what the difference
>> is between these image and other images that load and display quickly.
>
> They're just BMP's which I would expect to be quite fast.  Any feeling
> if they'll
> go faster if I convert them to GeoTiffs?  I've done that with some other images,
> and it feels like they go faster.
>
> I'm also seeing JAI take a LOT of RAM to read in these files.  It causes the JAI
> read to fail and fall back to the FileCache mechanism.
>
>> For your situation, I think there is another solution - the beta version has a new layer,
>
> Yup, I'm using the Beta already.
>
> FYI, I tried to use gdal_translate to turn my BMP's into GeoTiff's,
> but for some reason,
> OpenMap didn't like those Geotiff's - there was something missing.
> The data I have
> with the BMP's is the lat/long of the 4 corners of the image.
>
> So I punted and just added code to read my "worldfiles" like the
> current WorldFile
> code in OpenMap (and I've probably confused you now).
>
>> the com.bbn.openmap.layers.imageTile.MapTileLayer, which uses map tiles like
>> OpenStrretMap and Google maps.  You can use GDAL to make the tiles out of
>> your images, using gdal_merge and gdal2tiles.py.
>
> Thanks - I'll take a look at this.
>
>> I think the latest version in the repository
>> has the modification that lets the gdal tiles be used,
>
> The StandardMapTileFactory I have mentions GDAL.
>
>> if it doesn't there will be an
>> update checked in tomorrow.  The difference is, you have to add a transform to the
>> layer so it can figure out the right way to look up tiles for lat/lons.  Details are/will
>> be in the javadocs for the layer.
>
> I'll check again tomorrow to see if you check anything in.  Thanks!
>
>> Let me know if you have questions,
>
>>> Also, the background property in Layer - is that meant to work
>>> standalone, or do I need to create a BufferedLayer and put the
>>> layers i want to buffer in it?
>
> Pete
>
> --
> [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"]
>
> --
> [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"]
>

--
[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 Oct 13 2010 - 09:33:39 EDT

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