This driver implemets reading support for Meteosat Second Generation files. These are files with names like H-000-MSG1__-MSG1________-HRV______-000007___-200405311115-C_, commonly distributed into a folder structure with dates (e.g. 2004\05\31 for the file mentioned).
The MSG files are wavelet-compressed. A decompression library licensed from EUMETSAT is needed (Public Wavelet Transform Decompression Library Software, shorter Wavelet Transform Software). The software is compilable on Microsoft Windows, Linux and Solaris Operating Systems, and it works on 32 bits and 64 bits as well as mixed architectures. It is a licensed software and available free to download upon acceptance of the WaveLet Transform Software Licence during electronic registration process.
Part of the source of the file xrithdr_extr.c from XRIT2PIC is used to parse MSG headers. This source is licensed under the terms of the GNU General Public License as published by the Free Software Foundation.
This driver is not "enabled" by default. See Build Instructions on how to include this driver in your GDAL library.
Download the Eumetsat library for wavelet decompression. This is a file named PublicDecompWT.zip. Extract the content in a subdirectory with the same name (under frmts/msg).
If you are building with Visual Studio 6.0, extract the .vc makefiles for the PublicDecompWT from the file PublicDecompWTMakefiles.zip.
If you build using the GNUMakefile, use --with-msg option to enable MSG driver:
If find that some adjustments are needed in the makefile and/or the msg source files, please "commit" them. The Eumetsat library promises to be "platform indepentent", but as we are working with Microsoft Windows and Visual Studio 6.0, we did not have the facilities to check if the rest of the msg driver is. Furthermore, apply steps 4 to 7 from the GDAL Driver Implementation Tutorial, section "Adding Driver to GDAL Tree".
MSG Wiki page is available at http://trac.osgeo.org/gdal/wiki/MSG. It's dedicated to document building and usage hints
It is possible to select individual files for opening. In this case, the driver will gather the files that correspond to the other strips of the same image, and correctly compose the image.
Example with gdal_translate.exe:
gdal_translate C:\hrit_a\2004\05\31\H-000-MSG1__-MSG1________-HRV______-000008___-200405311115-C_ C:\output\myimage.tif
It is also possible to use the following syntax for opening the MSG files:
Examples with gdal_translate utility:
Example call to fetch an MSG image of 200501181200 with bands 1, 2 and 3 in IMG format:
gdal_translate -of HFA MSG(\\pc2133-24002\RawData\,200501181200,(1,2,3),N,N,1,1) d:\output\outfile.img
In JPG format, and converting the 10 bits image to 8 bits by dividing all values by 4:
gdal_translate -of JPEG MSG(\\pc2133-24002\RawData\,200501181200,(1,2,3),N,B,1,1) d:\output\outfile.jpg
The same, but reordering the bands in the JPEG image to resemble RGB:
gdal_translate -of JPEG MSG(\\pc2133-24002\RawData\,200501181200,(3,2,1),N,B,1,1) d:\output\outfile.jpg
Geotiff output, only band 2, original 10 bits values:
gdal_translate -of GTiff MSG(\\pc2133-24002\RawData\,200501181200,2,N,N,1,1) d:\output\outfile.tif
gdal_translate -of GTiff MSG(\\pc2133-24002\RawData\,200501181200,12,N,N,1,1) d:\output\outfile.tif
The same band 12 with radiometric calibration in mW/m2/sr/(cm-1)-1:
gdal_translate -of GTiff MSG(\\pc2133-24002\RawData\,200501181200,12,N,R,1,1) d:\output\outfile.tif
Retrieve data from c:\hrit-data\2005\01\18 instead of \\pc2133-24002\RawData\... :
gdal_translate -of GTiff MSG(c:\hrit-data\2005\01\18,200501181200,12,Y,R,1,1) d:\output\outfile.tif
Another option to do the same (note the difference in the Y and the N for the “use_root_folder” parameter:
gdal_translate -of GTiff MSG(c:\hrit-data\,200501181200,12,N,R,1,1) d:\output\outfile.tif
Without radiometric calibration, but for 10 consecutive cycles (thus from 1200 to 1415):
gdal_translate -of GTiff MSG(c:\hrit-data\,200501181200,12,N,N,10,1) d:\output\outfile.tif
10 cycles, but every hour (thus from 1200 to 2100):
gdal_translate -of GTiff MSG(c:\hrit-data\,200501181200,12,N,N,10,4) d:\output\outfile.tif
10 cycles, every hour, and bands 3, 2 and 1:
gdal_translate -of GTiff MSG(c:\hrit-data\,200501181200,(3,2,1),N,N,10,4) d:\output\outfile.tif
The images are using the Geostationary Satellite View projection. Most GIS packages don't recognize this projection (we only know of ILWIS that does have this projection), but gdalwarp.exe can be used to re-project the images.