Home| base |src.bin|graphic| pngtoppm Index

pngtoppm

Syntax
pngtoppm --help
pngtoppm [-bgcol rrggbb] [-alpha alphaname] [name]
Synopsis

Convert a Portable Network Graphics (PNG) image to Portable PixMap (PPM).

Options
--helpprint the help message and exit.
-bgcol rrggbbset the background color of the output image to rrggbb, specified as the hexadecimal value for the 24-bit red,green and blue component color.
-alpha alphanamesave the alpha channel of the file as the file alphaname.
nameinput image filename. If this is omitted the image will be read from standard input.
Description

Convert a Portable Network Graphics (PNG) image to Portable PixMap (PPM).

The PPM image file is written to standard output.

Examples
pngtoppm inp.png > out.ppm

Convert PNG file inp.png to the PPM file out.ppm.

pngtoppm -bgcol ff0000 inp.png > out.ppm

Convert PNG file inp.png to the PPM file out.ppm. Set the background color to ff0000 (Red).