Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

pngdriver(1grass) [debian man page]

pngdriver(1grass)						Grass User's Manual						 pngdriver(1grass)

NAME
PNG driver - driver to create PNG and PPM images. (drivers) DESCRIPTION
The PNG driver generates PNG and PPM images from GRASS display commands. Per default PNG files are written with this driver. It is started as 'pseudo' monitor (image file instead) and when stopped, all output from previously used display commands are written to the PNG image file. USAGE
Environment variables Several environment variables effect the operation of the PNG driver. GRASS_WIDTH=xxx the width of the image map (default is 640). GRASS_HEIGHT=yyy the height of the image map (default is 480). GRASS_PNGFILE=filename the filename to put the resulting image in, default is map.png. If you set GRASS_PNGFILE to a filename which ends in ".ppm", a PPM file will be created (with alpha channel stored in a PGM image, if applicable). If you set GRASS_PNGFILE to a filename which ends in ".bmp", a 32-bpp BMP file will be created (these are not readable by some older viewers). GRASS_BACKGROUNDCOLOR=RRGGBB specifies the background color to use in RGB notation (hex values). Default is 000000 (black). GRASS_TRANSPARENT=[TRUE|FALSE] sets transparent background on (TRUE) or off (FALSE, default). GRASS_TRUECOLOR=[TRUE|FALSE] sets true-color support GRASS_PNG_COMPRESSION=[0|1|9] compression level of PNG files (0 = none, 1 = fastest, 9 = best, default is 6) GRASS_PNG_AUTO_WRITE=[TRUE|FALSE] if set to TRUE, the image file will be written after each operation (i.e. whenever a client disconnects), rather than only being written out when the driver terminates. GRASS_PNG_READ if TRUE, the PNG driver will initialize the image from the contents of GRASS_PNGFILE. GRASS_PNG_MAPPED if TRUE, the PNG driver will map GRASS_PNGFILE as its framebuffer, rather than using memory. This only works with BMP files. GRASS_RENDER_IMMEDIATE=[TRUE|FALSE] tells the raster library to use its built-in PNG driver rather than connecting to an external monitor process using sockets. If TRUE, there is no need to run d.mon start=PNG. Example Define driver settings (here: bash shell syntax) export GRASS_RENDER_IMMEDIATE=TRUE export GRASS_TRUECOLOR=TRUE Start up the driver d.mon start=PNG Display raster map and vector polygons d.rast somerastermap d.vect somevectormap color=red Stop the driver subsequently. This will write a file named map.png to be created in your current directory: d.mon stop=PNG NOTES
The PNG driver uses the libpng (see the libpng home page) and zlib (see the zlib home page), all which needs to be installed for the PNG driver to work (it's worth it). The resolution of the PNG raster map is defined by the map extents. Use g.region -p to get the number of rows and cols and use the environ- ment variables to set the PNG size. If you would like a larger image, multiply both rows and cols by the same whole number to preserve the aspect ratio. Further PNG file processing (e.g. quantization to 1 bit for monochrome images) can be done with 'pnmquant' of the netpbm tools. SEE ALSO
Display drivers HTMLMAP driver, PostScript driver, XDRIVER d.frame, d.mon, d.rast, d.vect AUTHOR
Original version: Per Henrik Johansen NORGIT AS Rewritten by: Glynn Clements, 2003 Last changed: $Date: 2010-02-18 01:23:37 +0100 (Thu, 18 Feb 2010) $ Full index (C) 2003-2011 GRASS Development Team GRASS 6.4.2 pngdriver(1grass)

Check Out this Related Man Page

PNG(5)								File Formats Manual							    PNG(5)

NAME
png - Portable Network Graphics (PNG) format DESCRIPTION
PNG (Portable Network Graphics) is an extensible file format for the lossless, portable, well-compressed storage of raster images. PNG pro- vides a patent-free replacement for GIF and can also replace many common uses of TIFF. Indexed-color, grayscale, and truecolor images are supported, plus an optional alpha channel. Sample depths range from 1 to 16 bits. PNG is designed to work well in online viewing applications, such as the World Wide Web, so it is fully streamable with a progressive dis- play option. PNG is robust, providing both full file integrity checking and fast, simple detection of common transmission errors. Also, PNG can store gamma and chromaticity data for improved color matching on heterogeneous platforms. SEE ALSO
libpng(3),zlib(3),deflate(5),andzlib(5) PNG specification (second edition), November 2003: <http://www.w3.org/TR/2003/REC-PNG-20031110/ PNG 1.2 specification, July 1999: http://www.libpng.org/pub/png PNG 1.0 specification, October 1996: RFC 2083 ftp://ds.internic.net/rfc/rfc2083.txt or (as a W3C Recommendation) at http://www.w3.org/TR/REC-png.html AUTHORS
This man page: Glenn Randers-Pehrson Portable Network Graphics (PNG) Specification (Second Edition) Information technology - Computer graphics and image processing - Portable Network Graphics (PNG): Functional specification. ISO/IEC 15948:2003 (E) (November 10, 2003): David Duce and others. Portable Network Graphics (PNG) Specification Version 1.2 (July 8, 1999): Glenn Randers-Pehrson and others (png-list). Portable Network Graphics (PNG) Specification Version 1.0 (October 1, 1996): Thomas Boutell and others (png-list). COPYRIGHT NOTICE
This man page is Copyright (c) 1998-2006 Glenn Randers-Pehrson. See png.h for conditions of use and distribution. The PNG Specification (Second Edition) is Copyright (c) 2003 W3C. (MIT, ERCIM, Keio), All Rights Reserved. The PNG-1.2 specification is copyright (c) 1999 Glenn Randers-Pehrson. See the specification for conditions of use and distribution. The PNG-1.0 specification is copyright (c) 1996 Massachusetts Institute of Technology. See the specification for conditions of use and distribution. June 26, 2010 PNG(5)
Man Page