From bedfeaf468ba60bba50a5f2ba89d8c974861c663 Mon Sep 17 00:00:00 2001 From: Idan Miara Date: Mon, 8 Feb 2021 21:29:51 +0200 Subject: [PATCH] MRR - fixes mrr.rst - reformat and doc syntax fixes gdal/frmts/makefile.vc - reformat gdal/nmake.opt - set MRR_LIB_LINK and add it to EXTERNAL_LIBS --- gdal/doc/source/drivers/raster/mrr.rst | 44 ++++++++++++++++---------- gdal/frmts/makefile.vc | 20 ++++++------ gdal/nmake.opt | 33 +++++++++++++------ 3 files changed, 61 insertions(+), 36 deletions(-) diff --git a/gdal/doc/source/drivers/raster/mrr.rst b/gdal/doc/source/drivers/raster/mrr.rst index da96eef8d8db..9bec586c05bf 100644 --- a/gdal/doc/source/drivers/raster/mrr.rst +++ b/gdal/doc/source/drivers/raster/mrr.rst @@ -5,7 +5,8 @@ MRR --- Multi Resolution Raster .. shortname:: MRR -This driver supports reading of MRR (Multiple Resolution Raster) file format developed by Precisely(MapInfo). This driver does not provide support for creating, writing or editing MRR files. +This driver supports reading of MRR (Multiple Resolution Raster) file format developed by Precisely(MapInfo). +This driver does not provide support for creating, writing or editing MRR files. Driver capabilities ------------------- @@ -29,14 +30,22 @@ Contents Overview of MRR (Multiple Resolution Raster) Driver: ---------------------------------------------------- -MRR unifies the storage of all types of raster data such as imagery, spectral imagery, continuous gridded data and thematic data. MRR extends the concept of a multi-banded raster to a “four dimensional” raster which may contain – - -- One or more fields, each of which contain a particular type of raster data. A field may contain multi-banded continuous grid data, multi-banded classified data, color imagery or color imagery utilizing a fixed size color palette. - -- One or more events, each of which contain an addition or modification to the field data at a specified time. Events provide a time dimension in MRR. -- One or more bands which contain data in one of many supported data types such as 1/2/4/8/16/32/64 bit integers and 32/64 bit floating point. Some data types, like color or complex numbers, may contain multiple components. These are exposed as virtual bands. -- A stack of overviews, referred to as resolutions levels. Level 0 contains the ‘base resolution’ raster data. Levels 1 upward contain overviews within which the cell size doubles at each level. Levels -1 downward contain underviews which are generated on demand by interpolation from the base level. -- MRR is designed to enable the creation of very large and high resolution rasters and the SDK ensures that access to data at any resolution level is constant. Raster data is stored in a sparse collection of tiles of equal size. Lossless compression codecs are employed to store data within each tile, and lossy image compression codec can be used for imagery fields. Each resolution level has a fixed cell size, but MRR supports a multi-resolution tile concept which allows the cell size to set in each tile separately. +MRR unifies the storage of all types of raster data such as imagery, spectral imagery, continuous gridded data and thematic data. +MRR extends the concept of a multi-banded raster to a "four dimensional" raster which may contain – + +- One or more fields, each of which contain a particular type of raster data. A field may contain multi-banded continuous grid data, + multi-banded classified data, color imagery or color imagery utilizing a fixed size color palette. +- One or more events, each of which contain an addition or modification to the field data at a specified time. + Events provide a time dimension in MRR. +- One or more bands which contain data in one of many supported data types such as 1/2/4/8/16/32/64 bit integers and 32/64 bit floating point. + Some data types, like color or complex numbers, may contain multiple components. These are exposed as virtual bands. +- A stack of overviews, referred to as resolutions levels. Level 0 contains the ‘base resolution’ raster data. + Levels 1 upward contain overviews within which the cell size doubles at each level. + Levels -1 downward contain underviews which are generated on demand by interpolation from the base level. +- MRR is designed to enable the creation of very large and high resolution rasters and the SDK ensures that access to data at any resolution level is constant. + Raster data is stored in a sparse collection of tiles of equal size. Lossless compression codecs are employed to store data within each tile, + and lossy image compression codec can be used for imagery fields. Each resolution level has a fixed cell size, + but MRR supports a multi-resolution tile concept which allows the cell size to set in each tile separately. NOTE: Some MRR features may not be accessible through GDAL driver. @@ -51,7 +60,8 @@ Issues and Limitations - The driver does not provide support for creating, writing or editing MRR files. - Although an MRR may contain multiple fields, this driver can only access the first field. -- Although an MRR may contain multiple events, this driver can only access data that represents the roll-up of all events. This represents the “final state” of the raster. +- Although an MRR may contain multiple events, this driver can only access data that represents the roll-up of all events. + This represents the "final state" of the raster. -------------- @@ -78,7 +88,7 @@ make plugin MapInfo Pro Advanced SDK Runtime -------------------------------- - + MRR driver needs MapInfo Pro Advanced SDK to be installed on the machine to work with GDAL. Download MapInfo Pro Advanced SDK by navigating to "https://www.pitneybowes.com/us/campaign/sdkrequest.html" @@ -91,19 +101,19 @@ SDK Zip folder Structure: MapInfo Pro Advanced SDK zip file contains following folders: - AmazonLinux --> 64 bit Binaries for AmazonLinux. - + - CentOS7 --> 64 bit Binaries for CentOS7. - + - OracleLinux --> 64 bit Binaries for OracleLinux. - Ubuntu --> 64 bit Binaries for Ubuntu. - + - Windows --> 64 bit Binaries for Windows. - -Choose the binaries for the desired platform from the "Raster GDAL" folder and copy all files into the folder containing GDAL binaries. + +Choose the binaries for the desired platform from the "Raster GDAL" folder and copy all files into the folder containing GDAL binaries. + - diff --git a/gdal/frmts/makefile.vc b/gdal/frmts/makefile.vc index d6d17fddea65..8032eae83538 100644 --- a/gdal/frmts/makefile.vc +++ b/gdal/frmts/makefile.vc @@ -18,7 +18,7 @@ EXTRAFLAGS = -DFRMT_ceos -DFRMT_aigrid -DFRMT_elas -DFRMT_hfa -DFRMT_gtiff\ -DFRMT_safe -DFRMT_sentinel2 -DFRMT_derived -DFRMT_prf \ -DFRMT_sigdem -DFRMT_ignfheightasciigrid -DFRMT_tga -DFRMT_stacta -MOREEXTRA = +MOREEXTRA = DIRLIST = $(EXTRAFLAGS:-DFRMT_=) @@ -56,7 +56,7 @@ EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_openjpeg !ENDIF !IFDEF KAKDIR -!IF "$(JP2KAK_PLUGIN)" != "YES" +!IF "$(JP2KAK_PLUGIN)" != "YES" EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_jp2kak -DFRMT_jpipkak !ELSE PLUGINFLAGS = $(PLUGINFLAGS) -DFRMT_jp2kak -DFRMT_jpipkak @@ -71,6 +71,14 @@ PLUGINFLAGS = $(PLUGINFLAGS) -DFRMT_ecw !ENDIF !ENDIF +!IFDEF MRR_ENABLED +!IF "$(MRR_PLUGIN)" != "YES" +EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_mrr +!ELSE +PLUGINFLAGS = $(PLUGINFLAGS) -DFRMT_mrr +!ENDIF +!ENDIF + !IFDEF LURATECH_CFLAGS !IF "$(JP2LURA_PLUGIN)" != "YES" EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_jp2lura @@ -149,14 +157,6 @@ EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_grib EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_wcs -DFRMT_wms -DFRMT_plmosaic -DFRMT_wmts -DFRMT_rda -DFRMT_eeda -DFRMT_daas -DFRMT_ogcapi !ENDIF -!IFDEF MRR_ENABLED -!IF "$(MRR_PLUGIN)" != "YES" -EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_mrr -!ELSE -PLUGINFLAGS = $(PLUGINFLAGS) -DFRMT_mrr -!ENDIF -!ENDIF - !IFDEF RASDAMAN_ENABLED EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_rasdaman !ENDIF diff --git a/gdal/nmake.opt b/gdal/nmake.opt index 3701faf32445..466f8f0032cd 100644 --- a/gdal/nmake.opt +++ b/gdal/nmake.opt @@ -417,6 +417,21 @@ JPEG12_SUPPORTED = 1 # /D_MBCS /D_UNICODE /DUNICODE /D_WINDOWS \ # /DLIBECWJ2 /DWIN32 /D_WINDLL -DNO_X86_MMI + +# Uncomment the following line to enable Pitney Bowes MRR support. +#MRR_ENABLED = YES +#MRR_VERSION=1 +#MRR_SDK = C:\MRRSDK\sdk +#MRR_INC = $(MRR_SDK)\include +#MRR_LIB = $(MRR_SDK)\lib\pe$(MRR_VERSION).lib \ +# $(MRR_SDK)\lib\sde$(MRR_VERSION).lib $(MRR_SDK)\lib\sg$(MRR_VERSION).lib + +# To build MRR support as a plugin uncomment the following, and make sure +# to do "nmake /f makefile.vc plugin" in gdal/frmts/mrr and copy the two +# resulting DLLs to an appropriate place. +#MRR_PLUGIN = YES + + # DWG support using the Open Design Alliance Teigha Libraries # Two versions are supported: # - ODA >= 2021 (tested with 2021.2), defined immediately @@ -712,14 +727,6 @@ OCI_INCLUDE = -I$(ORACLE_HOME)\oci\include !ENDIF !ENDIF -#MRR_PLUGIN = YES -#MRR_ENABLED = YES -#MRR_VERSION=1 -#MRR_SDK = C:\MRRSDK\sdk -#MRR_INC = $(MRR_SDK)\include -#MRR_LIB = $(MRR_SDK)\lib\pe$(MRR_VERSION).lib \ -# $(MRR_SDK)\lib\sde$(MRR_VERSION).lib $(MRR_SDK)\lib\sg$(MRR_VERSION).lib - #FGDB_ENABLED = YES #FGDB_PLUGIN = YES @@ -1024,6 +1031,14 @@ ECW_LIB_LINK= !ENDIF !ENDIF +!IFDEF MRR_SDK +!IF "$(MRR_PLUGIN)" != "YES" +MRR_LIB_LINK= $(MRR_LIB) +!ELSE +MRR_LIB_LINK= +!ENDIF +!ENDIF + !IFDEF LURATECH_CFLAGS !IF "$(JP2LURA_PLUGIN)" != "YES" LURATECH_LIB_LINK= $(LURATECH_LIB) @@ -1149,7 +1164,7 @@ SYM_PREFIX=_ !ENDIF EXTERNAL_LIBS = $(OGDILIB) $(XERCES_LIB) $(EXPAT_LIB) $(OCI_LIB) $(PG_LIB) \ - $(KAK_LIB_LINK) $(ECW_LIB_LINK) $(LURATECH_LIB_LINK) $(HDF4_LIB_LINK) $(FME_LIB) $(MRSID_LIB_LINK) \ + $(KAK_LIB_LINK) $(ECW_LIB_LINK) $(MRR_LIB_LINK) $(LURATECH_LIB_LINK) $(HDF4_LIB_LINK) $(FME_LIB) $(MRSID_LIB_LINK) \ $(FITS_LIB_LINK) $(JPEG_LIB) $(NETCDF_LIB_LINK) $(PROJ4_LIB) \ $(GEOTIFF_LIB) $(TIFF_LIB) $(PROJ_LIBRARY) $(SQLITE_LIB) \ $(MYSQL_LIB) $(GEOS_LIB) $(HDF5_LIB_LINK) $(KEA_LIB_LINK) $(ARCOBJECTS_LIB) $(DWG_LIB_LINK) \