Linux Commands Examples

A great documentation place for Linux commands

ppmtobmp

convert a portable pixmap into a BMP file


see also : bmptoppm - ppmtowinicon - ppmquant - ppmdither

Synopsis

ppmtobmp [-windows] [-os2] [-bpp=bits_per_pixel] [ppmfile]


add an example, a script, a trick and tips

: email address (won't be displayed)
: name

Step 2

Thanks for this example ! - It will be moderated and published shortly.

Feel free to post other examples
Oops ! There is a tiny cockup. A damn 404 cockup. Please contact the loosy team who maintains and develops this wonderful site by clicking in the mighty feedback button on the side of the page. Say what happened. Thanks!

examples

0
source
            
jpegtopnm < $jpgfile | ppmtobmp > $bmpfile
bmconv $mbmfile /c24$bmpfile
rm $bmpfile

description

Reads a portable pixmap as input. Produces a Microsoft Windows or OS/2 BMP file as output.

options

All options can be abbreviated to their shortest unique prefix and you can use a double dash in place of the single dash, GNU-style.
-windows

Tells the program to produce a Microsoft Windows BMP file. (This is the default.)

-os2

Tells the program to produce an OS/2 BMP file. (Before August 2000, this was the default).

-bpp

This determines how many bits per pixel you want the BMP file to contain. Only 1, 4, 8, and 24 are possible. By default, ppmtobmp chooses the smallest number with which it can represent all the colors in the input image. If you specify a number too small to represent all the colors in the input image, ppmtobmp tells you and terminates. You can use ppmquant or ppmdither to reduce the number of colors in the image.

notes

To get a faithful reproduction of the input image, the maxval of the input image must be 255. If it is something else, ppmtobmp the colors in the BMP file may be slightly different from the colors in the input.

Windows icons are not BMP files. Use ppmtowinicon to create those.


see also

bmptoppm , ppmtowinicon , ppmquant , ppmdither , ppm


author

Copyright (C) 1992 by David W. Sanderson.

How can this site be more helpful to YOU ?


give  feedback