Changes between Version 2 and Version 3 of FdoGdalNotes


Ignore:
Timestamp:
06/13/07 22:07:07 (17 years ago)
Author:
jbirch
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • FdoGdalNotes

    v2 v3  
    11= FDOGDAL Raster Provider =
    22
    3 The fdogdal provider is the open source raster provider for FDO (and hence !MapGuide).  It is implemented on top of the [http://www.gdal.org/ GDAL] raster library.  Frank Warmerdam (warmerdam at pobox.com) is the primary author of fdogdal.  Questions about the provider may asked on the fdo or mapguide users lists. 
     3The fdogdal provider is the open source raster provider for FDO (and hence !MapGuide).  It is implemented on top of the [http://www.gdal.org/ GDAL] raster library.  Frank Warmerdam (warmerdam at pobox.com) is the primary author of fdogdal.  Questions about the provider may asked on the fdo or mapguide users lists.
    44
    55= Documents =
    66
    7  * [http://fdo.osgeo.org/fdo/index.html User Documentation]
     7 * [http://fdo.osgeo.org/fdogdal/index.html User Documentation]
     8 * [http://fdo.osgeo.org/files/fdo/docs/GDAL/index.html FDO API Documentation]
    89
    910= For !MapGuide Users =
    1011
    11 == Using fdogdal in Studio ==
     12== Using fdogdal in Autodesk !MapGuide Studio ==
    1213
    1314To publish rasters using the open source raster provider with [http://usa.autodesk.com/adsk/servlet/index?id=7176611&siteID=123112 Autodesk MapGuide Studio] use the following steps:
    14  1. Start Studio and connect to your MapGuide Open Source 1.1.0 server.
     15 1. Start Studio and connect to your !MapGuide Open Source 1.1.0 server.
    1516 2. Then do File > New > Data Connection...
    1617 3. In the Connect To Data dialog that comes up, select OSGeo FDO Provider for Raster, then press OK. An editor that says "Configure a Feature Resource using the Generic Editor" will display.
    17  4. In the Connection Properties grid, there is a DefaultRasterFileLocation property.  Click in the value column and enter the directory where your image files are. On Linux it has the form /home/thf/myimages and on Windows it has the form C:\myimages.
     18 4. In the Connection Properties grid, there is a !DefaultRasterFileLocation property.  Click in the value column and enter the directory where your image files are. On Linux it has the form /home/thf/myimages and on Windows it has the form C:\myimages.
    1819 5. The configuration of the raster source is now complete, save the resource and start using it.
    1920
    2021Notes:
    2122 * The layer definition preview will not show the raster.  In order to preview the data, create a map definition and set the extents of the map to contain the raster data.  If the extents are set correctly the raster data should show in the preview.
    22 
    23 == Frank's fdogdal Downloads ==
    24 
    25 Visit the Frank's '''fdogdal 3.2.0 updates for MapGuide 1.1.0''' download site for ecw, and mrsid support, as well as several bug fixes and features improvements:
    26 
    27 http://home.gdal.org/dl/mapguide/
    28 
    29 For MGOS 1.2.0, instead of using the mg_fdogdal_110.zip file found at the above location, unzip the contents of http://download.osgeo.org/mapguide/releases/1.2.0-rc1/MGOS1.2.0GDALPatch.zip to C:\Program Files\!MapGuideOpenSource\Server\Bin. If you have accidently unzipped mg_fdogdal_110.zip, using this zip file will undo your changes.
    3023
    3124== Debugging with Rasters ==
     
    4033  mgserver run
    4134}}}
     35
     36== Frank's fdogdal Downloads ==
     37
     38=== !MapGuide 1.1.0 ===
     39
     40Visit the Frank's '''fdogdal 3.2.0 updates for !MapGuide 1.1.0''' download site for ecw, and mrsid support, as well as several bug fixes and features improvements:
     41
     42http://home.gdal.org/dl/mapguide/
     43
     44There are instructions in these packages, but basically you just unzip into the C:\Program Files\!MapGuideOpenSource\Server\Bin directory.
     45
     46=== !MapGuide 1.2.0 ===
     47
     48!MapGuide 1.2.0 uses FDO 3.2.2, and requires a slightly different procedure.  Do '''not''' download the mg_fdogdal_110.zip file from Frank's site.  First, download and apply the ECW and MrSID packages from Frank's site as above.  Second, obtain the [http://download.osgeo.org/mapguide/releases/1.2.0-rc1/MGOS1.2.0GDALPatch.zip MapGuide 1.2.0 gdalfdo patch] and apply it in the same manner.
     49
     50== Raster performance enhancements ==
     51
     52Raster performance in the current released provider degrades when accessing many image files for a single layer.  This is because there was no way of referencing the spatial bounds of each image without opening the image and asking it "Image, what are your bounds?". 
     53
     54In order to address this problem, the raster provider's config file schema was extended (initially to meet the same need with the proprietary Autodesk raster provider) to store bounding boxes for the images in the feature source.  Using this new schema as a guideline, Frank has added preliminary bounds support to the fdogdal provider, and this has been sucessfully tested in several environments.  Further testing is encouraged.
     55
     56=== Downloads ===
     57
     58(coming soon)
     59
     60These files are required to test the bounds functionality:
     61
     62* The new fdogdal package for Jason's site (for now), which includes the same gdal.dll as is in the 1.2.0 patch package
     63
     64* The ECW and MrSID packages from Frank's site if desired
     65
     66* Jason's really crude (to be refined) php script for generating a config document which includes image boundaries.
     67
     68=== Usage ===
     69
     701. Install the new fdogdal package into the C:\Program Files\!MapGuideOpenSource\Server\Bin\FDO directory
     71
     722. If desired install the ECW and MrSID packages according to the instructions on Frank's site
     73
     743. Extend the setting for maximum_execution_time in the php.ini file to at least two minutes.  This file is located at C:\Program Files\!MapGuideOpenSource\!WebServerExtensions\Php\php.ini by default
     75
     764. Place Jason's script in the C:\Program Files\!MapGuideOpenSource\!WebServerExtensions\www directory.  Edit the script to point the image path to your locally stored images.  Make sure to specify a trailing slash.
     77
     785. Run this script in your web browser by pointing to your !MapGuide installation (e.g. http://localhost:8008/mapguide/rasterconfig.php ).  If all goes well, you should be prompted to download a config.xml file.
     79
     806. Create an OSGeo Raster Provider !DataSource (following the instructions at the top of this page) that points to the same location for the images as the config file that you generated.
     81
     827. Use the !MapAgent (http://localhost:8008/mapguide/mapagent/index.html) or Studio to download the existing !DataSource as an XML file, using the !GetResourceContent call.  Edit the file, inserting a !ConfigurationDocument line, so that it looks something like this:
     83
     84{{{
     85
     86<?xml version="1.0" encoding="utf-8"?>
     87<FeatureSource xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xsi:noNamespaceSchemaLocation="FeatureSource-1.0.0.xsd">
     88  <Provider>OSGeo.Gdal</Provider>
     89  <Parameter>
     90    <Name>DefaultRasterFileLocation</Name>
     91    <Value>c:\RasterTest\nanaimo</Value>
     92  </Parameter>
     93  <ConfigurationDocument>config.xml</ConfigurationDocument> 
     94</FeatureSource>
     95
     96}}}
     97
     988. Again, using the !MapAgent (or Studio if you can figure it out), use the !SetResourceData operation to upload the config.xml file and associate it with your modified !DataSource.  Make sure that you specify the same name for the file as you entered in the !ConfigurationDocument line above.  For simplicity, it's recommended to leave it as config.xml.
     99
     100Please, let us know how this works on the !MapGuide users, or FDO users mailing lists.
     101
     102=== Known Issues ===
     103
     104* Currently, !MapGuide no longer checks each image when first loading the map, but the first time it does fetch the layer, each image is still enumerated.  Subsequent fetches only address the images required for the area that the user is zoomed to.
     105