MapInfo Pro

Expand all | Collapse all

Working with MapInfo Virtual Rasters

  • 1.  Working with MapInfo Virtual Rasters

    Pitney Bowes
    Posted 04-01-2019 04:02
    Edited by Shweta Shukla 04-02-2019 00:54

    Working with MapInfo Virtual Rasters

    The "MapInfo Virtual Raster" is one of the new features available in MapInfo Pro Advanced 17.0.2. In this article we will examine this feature in greater depth and work through an example.

    MapInfo Virtual Raster (MVR) is a raster that acquires the data for all of its field and bands from other raster sources at run time.

    It is a simple XML file that describes a raster. The XML describes the structure of the raster and also records the source raster data. An MVR behaves like an actual raster file without any physical copy of defined raster. It gives you the same experience as any physical raster file.

    MVR overcomes the limitation of joining the different resolution bands together. It allows users to define raster  files from separate sources in simple xml format file and render in MapInfo Pro.  There is no need to combine them into a single multi-banded raster file.

    There is no restriction on what source raster data can be used in an MVR. The cell size, coordinate system and geometry of the source rasters can be different. The MVR will acquire the best possible data and render smoothly.

    The XML structure of MapInfo Virtual Raster:

     This tool creates MapInfo virtual raster with the extension of '.mvr'. This XML file records all information about the raster structure and can be directly opened into a map window. It will render seamlessly like a physical file.

     Sample virtual raster:


    MVR supports both absolute and relative path of source raster w.r.t. MVR file.

    The MVR xml file has two distinct parts.

             The first part records the list of the source rasters for the MVR.

                      Each source raster has a unique Alias (Name attribute) and file path (File attribute) as shown below.

                       <Raster File="D:\Data\All\grc\SeattleLULC.grc" Name="RasterSource0"/>

                       <Raster File="D:\Data\All\Classified\Classified.grc" Name="RasterSource1"/>

                       <Raster File="D:\Data\All\grd\SeattleElevation.grd" Name="RasterSource2"/> 

            The second part of the xml contains the structure of MapInfo virtual raster.

    The RasterInfo tag defines the mapping structure of the raster and links the field and bands to the source rasters. Using the Virtual Raster tool, you can create a single field multi-banded MVR only.

    It will have a FieldInfo tag. The User can define the name of the field by providing value in the 'Name' attribute. Similarly user can define the Band names for each BandInfo tag.

     

    <RasterInfo>

            <FieldInfo Name="Field">

                           <BandInfo Name="Index">

                                          <Raster Name="RasterSource0" Field="0" Band="0" PrimaryRaster="true"/>

                           </BandInfo>

                           <BandInfo Name="Band 1">

                                          <Raster Name="RasterSource1" Field="0" Band="0"/>

                           </BandInfo>

            </FieldInfo>

    </RasterInfo>

     

    Each band is linked to a named source raster along with field and band Index. One of the bands can be marked as primary raster (PrimaryRaster attribute). The properties of the primary raster determine MVR properties such as the coordinate system, geometry and the cell size etc.

    If the primary raster is not specified, first band's source raster will be treated as primary raster.

    Use Cases:

    GIS professional often need to analyze different resolution band data collected from LandSat or hyper spectral sensors by combining them with different rendering schemes.  

    For example, to create a Color Infrared (CIR) vegetation image composite using Landsat 8 data, GIS professionals need to use bands 5, 4, and 3. Similarly, to create a natural color image using Landsat 8 data, they use bands 4, 3, and 2.

    Below is an example of multispectral LandSat data with different resolution


    As seen above, the bands are acquired at different resolution so they need to be resampled to a common resolution before performing any visualization and analysis operation. MVR gives the ability to analyze spectral bands with different resolutions without pre-processing raster files.

    How to use Landsat 8 data in MapInfo Virtual Raster.

     

    Color Infrared (CIR) vegetation image

    Below is the view showing the Histogram for the Red, Green and Blue fields.




    With the introduction of the virtual raster, having the ability to give the path of different raster files and render it on-the-fly to simulate the different band combination without saving the files on the disk is truly time saving and very useful.


    I would like to tag @AHMAR SHERAZ.
    ------------------------------
    Shweta Shukla
    Pitney Bowes Software India
    Noida
    ------------------------------


  • 2.  RE: Working with MapInfo Virtual Rasters

    Posted 07-12-2019 02:26

    Hi Shweta,

    is it possible to conduct 'point in polygon' process using MVR?

    Thanks,
    Jeremy



    ------------------------------
    Jeremy Gallagher
    Knowledge Community Shared Account
    ------------------------------



  • 3.  RE: Working with MapInfo Virtual Rasters

    Pitney Bowes
    Posted 07-12-2019 03:37
    Hi Jeremy,

    No, currently it is not possible. The Virtual Raster is created with  various Rasters with different resolutions at once reading the data from the different Rasters at runtime.

    Could you please elaborate as to why you are looking for it? Probably there could be a different function that can do it for you.

    Regards,
    Shweta

    ------------------------------
    Shweta Shukla
    Pitney Bowes Software India
    Noida
    ------------------------------



  • 4.  RE: Working with MapInfo Virtual Rasters

    Posted 07-16-2019 02:51
    Hi Shweta,

    My use case is to be able to query customer addresses against a hybrid layer of polygons (eg. postcode, electoral boundary etc.)

    At the moment i run a series of point-in-poly queries and merge the results using SQL append column function.

    Wasn't sure if MVR would create a more efficient workflow.

    Thanks,
    Jeremy

    ------------------------------
    Jeremy Gallagher
    Knowledge Community Shared Account
    ------------------------------



  • 5.  RE: Working with MapInfo Virtual Rasters

    Pitney Bowes
    Posted 07-16-2019 03:31
    Hi Jeremy,

    It looks like you have large number of customer addresses resolving to point dataset, which you then run through point-in-poly processing against some polygon.  In this case both (Customer address points and Polygons) are vector objects, and MVR is a raster. So you could not use MVR as it is.

    BTW, you may also try first rasterizing your polygon layers using Rasterize tool from Raster menu at some appropriate resolution, and then run Point Inspection tool on it. If it helps to speed up the processing.

    Regards,
    mitesh

    ------------------------------
    Mitesh Patel
    Knowledge Community Shared Account
    Shelton CT
    ------------------------------