This plugin write data to the Portable Network Graphics format (see https://secure.wikimedia.org/wikipedia/en/wiki/Portable_Network_Graphics). No data read has been implemented, because reading an existing file would require the exact knowlege of the color gradient that has been used to create it. When writing grids, various color gradients will be used depending on the parameter that the data represents. Nodata values are represented by transparent pixels (transparency is acheived through a transparent color instead of a true alpha channel for size and performance). If a grid containing no data (ie: size 0x0) is sent to the plugin, then no file will be written. Finally, the naming scheme for meteo grids should be: YYYY-MM-DDTHH.mm_{MeteoGrids::Parameters}.png
All units are MKSA except temperatures that are expressed in celcius.
This plugin uses the following keywords:
Advanced parameters (ie: don't mess up with them if you don't know what you're doing):
The size are specified as width followed by height, with the separator being either a space, 'x' or '*'. If a minimum and a maximum size are given, the average of the smallest and largest permissible sizes will be used. The world file is used for geolocalization and goes alongside the graphics output. By convention, the file has the same name as the image file, with the third letter of the extension jammed with a w: tif->tfw, jpg->jqw. The format is the following:
In order to compile this plugin, you need libpng and zlib. For Linux, please select both the libraries and their development files in your package manager.
For Mac, starting with Sierra, you can use the system png library: from a terminal window, run /Library/Frameworks/UnixImageIO.framework/Programs/libpng-config –libdir and provide this path with libpng.dylib appended to cmake as PNG_LIBRARY_RELEASE (you might have to press t in cmake in order to show the advanced options.). Otherwise (ie if you are not using Sierra or do not want to use the system version), you can either install using Fink or directly from source. In this case, please install first zlib at the prefix of your choice (with the prefix option of its configure script, for example "./configure --prefix=/usr/local", then build with "make" and install with "sudo make install"). Then run the libpng configure script with the –enable-shared and prefix options, for example "./configure --enable-shared --prefix=/usr/local" (and then build with "make" followed by "sudo make install").
For Windows, you can find zlib at http://switch.dl.sourceforge.net/project/gnuwin32/zlib/1.2.3/zlib-1.2.3.exe and libpng at http://switch.dl.sourceforge.net/project/gnuwin32/libpng/1.2.37/libpng-1.2.37-setup.exe . Once this has been installed, if you plan on using Visual c++, you also need to edit the file zconf.h in the libpng installation directory and transform the line 287:
should become