{
    "content": [
        {
            "type": "text",
            "text": "# ppmtobmp (man)\n\n## NAME\n\nppmtobmp - convert a portable pixmap into a BMP file\n\n## SYNOPSIS\n\nppmtobmp [-windows] [-os2] [-bpp=bitsperpixel] [ppmfile]\n\n## DESCRIPTION\n\nReads a portable pixmap as input.  Produces a Microsoft Windows or OS/2 BMP file as output.\n\n## TLDR\n\n> Convert a PPM image to a BMP file.\n\n- Convert a PPM image to a BMP file:\n  `ppmtobmp {{path/to/file.ppm}} > {{path/to/file.bmp}}`\n- Explicitly specify whether or not a Windows BMP file or an OS/2 BMP file should be created:\n  `ppmtobmp -{{windows|os2}} {{path/to/file.ppm}} > {{path/to/file.bmp}}`\n- Use a specific number of bits for each pixel:\n  `ppmtobmp {{-b|-bbp}} {{1|4|8|24}} {{path/to/file.ppm}} > {{path/to/file.bmp}}`\n\n*Source: tldr-pages*\n\n## Sections\n\n- **NAME**\n- **SYNOPSIS**\n- **DESCRIPTION**\n- **OPTIONS** (3 subsections)\n- **NOTES**\n- **SEE ALSO**\n- **AUTHOR**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "ppmtobmp",
        "section": "",
        "mode": "man",
        "summary": "ppmtobmp - convert a portable pixmap into a BMP file",
        "synopsis": "ppmtobmp [-windows] [-os2] [-bpp=bitsperpixel] [ppmfile]",
        "tldr_summary": "Convert a PPM image to a BMP file.",
        "tldr_examples": [
            {
                "description": "Convert a PPM image to a BMP file",
                "command": "ppmtobmp {{path/to/file.ppm}} > {{path/to/file.bmp}}"
            },
            {
                "description": "Explicitly specify whether or not a Windows BMP file or an OS/2 BMP file should be created",
                "command": "ppmtobmp -{{windows|os2}} {{path/to/file.ppm}} > {{path/to/file.bmp}}"
            },
            {
                "description": "Use a specific number of bits for each pixel",
                "command": "ppmtobmp {{-b|-bbp}} {{1|4|8|24}} {{path/to/file.ppm}} > {{path/to/file.bmp}}"
            }
        ],
        "tldr_source": "official",
        "flags": [
            {
                "flag": "",
                "long": null,
                "arg": null,
                "description": "Tells the program to produce a Microsoft Windows BMP file. (This is the default.)"
            },
            {
                "flag": "",
                "long": null,
                "arg": null,
                "description": "fault)."
            },
            {
                "flag": "",
                "long": null,
                "arg": null,
                "description": "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."
            }
        ],
        "examples": [],
        "see_also": [
            {
                "name": "bmptoppm",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/bmptoppm/1/json"
            },
            {
                "name": "ppmtowinicon",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ppmtowinicon/1/json"
            },
            {
                "name": "ppmquant",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ppmquant/1/json"
            },
            {
                "name": "ppmdither",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ppmdither/1/json"
            },
            {
                "name": "ppm",
                "section": "5",
                "url": "https://www.chedong.com/phpMan.php/man/ppm/5/json"
            }
        ],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "OPTIONS",
                "lines": 3,
                "subsections": [
                    {
                        "name": "-windows",
                        "lines": 2
                    },
                    {
                        "name": "-os2",
                        "lines": 2
                    },
                    {
                        "name": "-bpp",
                        "lines": 6
                    }
                ]
            },
            {
                "name": "NOTES",
                "lines": 7,
                "subsections": []
            },
            {
                "name": "SEE ALSO",
                "lines": 3,
                "subsections": []
            },
            {
                "name": "AUTHOR",
                "lines": 5,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "ppmtobmp - convert a portable pixmap into a BMP file\n",
                "subsections": []
            },
            "SYNOPSIS": {
                "content": "ppmtobmp [-windows] [-os2] [-bpp=bitsperpixel] [ppmfile]\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "Reads a portable pixmap as input.  Produces a Microsoft Windows or OS/2 BMP file as output.\n",
                "subsections": []
            },
            "OPTIONS": {
                "content": "All  options can be abbreviated to their shortest unique prefix and you can use a double dash\nin place of the single dash, GNU-style.\n",
                "subsections": [
                    {
                        "name": "-windows",
                        "content": "Tells the program to produce a Microsoft Windows BMP file.  (This is the default.)\n"
                    },
                    {
                        "name": "-os2",
                        "content": "fault).\n"
                    },
                    {
                        "name": "-bpp",
                        "content": "8, and 24 are possible.  By default, ppmtobmp chooses the smallest number  with  which\nit can represent all the colors in the input image.  If you specify a number too small\nto represent all the colors in the input image, ppmtobmp  tells  you  and  terminates.\nYou can use ppmquant or ppmdither to reduce the number of colors in the image.\n\n"
                    }
                ]
            },
            "NOTES": {
                "content": "To get a faithful reproduction of the input image, the maxval of the input image must be 255.\nIf it is something else, ppmtobmp the colors in the BMP file may be slightly  different  from\nthe colors in the input.\n\nWindows icons are not BMP files.  Use ppmtowinicon to create those.\n\n",
                "subsections": []
            },
            "SEE ALSO": {
                "content": "bmptoppm(1), ppmtowinicon(1), ppmquant(1), ppmdither(1), ppm(5)\n\n",
                "subsections": []
            },
            "AUTHOR": {
                "content": "Copyright (C) 1992 by David W. Sanderson.\n\n\n\n13 June 2000                                 ppmtobmp(1)",
                "subsections": []
            }
        }
    }
}