<<prev file | next file >>    view single page | view frames    summary: fields | routine    details: routine

Picture/

saveimage.pro

Save the current graphics window to an output file (GIF by default). The output formats supported are: GIF 8-bit with color table, BMP 8-bit with color table, PNG 8-bit with color table, PICT 8-bit with color table, JPEG 24-bit true color, TIFF 24-bit true-color. Any conversions necessary to convert 8-bit or 24-bit images onscreen to 8-bit or 24-bit output files are done automatically.

topsaveimage Input/Output.

saveimage, FILE, BMP=BMP, PNG=PNG, PICT=PICT, JPEG=JPEG, TIFF=TIFF, QUALITY=QUALITY, DITHER=DITHER, CUBE=CUBE, QUIET=QUIET, MULTIPLE=MULTIPLE

Parameters

FILE        in required default: format GIF

Name of the output file

Keywords

BMP       

Set this keyword to create BMP format (8-bit with color table).

PNG       

Set this keyword to create PNG format (8-bit with color table).

PICT       

Set this keyword to create PICT format (8-bit with color table).

JPEG       

Set this keyword to create JPEG format (24-bit true color).

TIFF       

Set this keyword to create TIFF format (24-bit true color).

QUALITY        default: 75

If set to a named variable, specifies the quality for JPEG output. Ranges from 0 ("terrible") to 100 ("excellent"). Smaller quality values yield higher compression ratios and smaller output files.

DITHER        default: no dithering

If set, dither the output image when creating 8-bit output which is read from a 24-bit display.

CUBE       

{default=to use statistical method) If set, use the color cube method to quantize colors when creating 8-bit output which is read from a 24-bit display. This may improve the accuracy of colors in the output image, especially white.

QUIET        default: to print an information message

Set this keyword to suppress the information message.

MULTIPLE       

Examples

IDL> openr, lun, filepath('hurric.dat', subdir='examples/data'), /get_lun IDL> image = bytarr(440, 330) IDL> readu, lun, image IDL> free_lun, lun IDL> loadct, 13 IDL> tvscl, image IDL> saveimage, 'hurric.gif'

Version history

Version

$Id: saveimage.pro 136 2006-07-10 15:20:19Z pinsard $

History

Liam.Gumley@ssec.wisc.edu http://cimss.ssec.wisc.edu/~gumley This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.

Known issues

Restrictions

The output file is overwritten if it exists. requires IDL 5.0 or higher (square bracket array syntax).

Statistics

McCabe cyclic 37
McCabe essential 1
McCabe modular design 1
Produced by IDLdoc 2.0.