# phpman > man > ppmtorgb3(1)

> **TLDR:** Separate the color components of a PPM file into three separate PGM files.
>
- Separate the color components of a PPM file, saving the outputs to `file.red`, `file.grn` and `file.blu`:
  `ppmtorgb3 {{path/to/file.ppm}}`

*Source: tldr-pages*

---

[ppmtorgb3(1)](https://www.chedong.com/phpMan.php/man/ppmtorgb3/1/markdown)                           General Commands Manual                          [ppmtorgb3(1)](https://www.chedong.com/phpMan.php/man/ppmtorgb3/1/markdown)



## NAME
       ppmtorgb3 - separate a portable pixmap into three portable graymaps

## SYNOPSIS
       **ppmtorgb3** [_ppmfile_]

## DESCRIPTION
       Reads  a  portable  pixmap  as input.  Writes three portable graymaps as output, one each for
       red, green, and blue.

       The output filenames are constructed by taking the input filename, stripping off  any  exten‐
       sion,  and appending ".red", ".grn", and ".blu".  For example, separating lenna.ppm would re‐
       sult in lenna.red, lenna.grn, and lenna.blu.  If the input comes from stdin,  the  names  are
       noname.red, noname.grn, and noname.blu.

## SEE ALSO
       [rgb3toppm(1)](https://www.chedong.com/phpMan.php/man/rgb3toppm/1/markdown), [ppmtopgm(1)](https://www.chedong.com/phpMan.php/man/ppmtopgm/1/markdown), [pgmtoppm(1)](https://www.chedong.com/phpMan.php/man/pgmtoppm/1/markdown), [ppm(5)](https://www.chedong.com/phpMan.php/man/ppm/5/markdown), [pgm(5)](https://www.chedong.com/phpMan.php/man/pgm/5/markdown)

## AUTHOR
       Copyright (C) 1991 by Jef Poskanzer.



                                           10 January 1991                              [ppmtorgb3(1)](https://www.chedong.com/phpMan.php/man/ppmtorgb3/1/markdown)
