Netpbm formats
(→Identification) |
Dexvertbot (Talk | contribs) (→Sample files) |
||
(27 intermediate revisions by 6 users not shown) | |||
Line 2: | Line 2: | ||
|formattype=electronic | |formattype=electronic | ||
|subcat=Graphics | |subcat=Graphics | ||
− | |extensions={{ext|pbm}} {{ext|pgm}} | + | |extensions={{ext|pbm}}, {{ext|pgm}}, {{ext|ppm}}, {{ext|pnm}} |
+ | |mimetypes={{mimetype|image/x-portable-anymap}}, others | ||
+ | |pronom={{PRONOM|fmt/408}}, others | ||
+ | |released=1988 | ||
}} | }} | ||
− | + | :''"PBM" redirects here. For another PBM format, see [[ILBM#PBM]].'' | |
− | + | :''"PNM" redirects here. For another PNM format, see [[The Print Shop]].'' | |
− | ''' | + | The '''Netpbm formats''' are a family of simple uncompressed raster image file formats, associated with the [[Netpbm]] library and suite of image processing utilities. They are designed so that it is straightforward for programmers to import and export them. |
− | '' | + | Due to their simplicity, the Netpbm formats are often used as "neutral" or "universal" image formats. It's not unusual for an image format's reference software to include a utility to convert to and from one of the Netpbm formats (and perhaps no other formats). Many of these conversion utilities have ultimately been incorporated into the Netpbm software. |
− | '''PPM''' (portable pixmap) is a color image format. | + | == Formats == |
+ | * '''PBM''' (portable bitmap) is a bi-level image format. | ||
+ | * '''PGM''' (portable graymap) is a grayscale image format. | ||
+ | * '''PPM''' (portable pixmap) is a color image format. | ||
+ | * '''PNM''' (portable anymap) is a collective name for PBM, PGM, and PPM. A .pnm file may use any of those formats. | ||
+ | * '''PAM''': Refer to [[Portable Arbitrary Map]]. Although PAM is one of the Netpbm formats, it's different enough that it's best documented in a separate article. | ||
− | + | == Identifiers and Identification == | |
+ | Each file begins with two ASCII characters, which serve as a signature. | ||
− | + | The PBM, PGM, and PPM formats come in two varieties: a text (or "plain" or "ASCII") format, and a binary (or "raw") format. | |
− | + | {| class="wikitable" | |
+ | !colspan="2"| Format | ||
+ | ! Signature | ||
+ | ! PRONOM | ||
+ | !colspan="2"| MIME types | ||
+ | |- | ||
+ | |rowspan="2"|PBM || text || <code>P1</code> || {{PRONOM|x-fmt/164}} ||rowspan="2"| {{mimetype|image/x-portable-bitmap}} ||rowspan="6"| {{mimetype|image/x-portable-anymap}} | ||
+ | |- | ||
+ | |binary || <code>P4</code> || {{PRONOM|fmt/409}} | ||
+ | |- | ||
+ | |rowspan="2"|PGM || text || <code>P2</code> || {{PRONOM|fmt/407}} ||rowspan="2"| {{mimetype|image/x-portable-graymap}} | ||
+ | |- | ||
+ | |binary || <code>P5</code> || {{PRONOM|fmt/406}} | ||
+ | |- | ||
+ | |rowspan="2"|PPM || text || <code>P3</code> || {{PRONOM|x-fmt/178}} ||rowspan="2"| {{mimetype|image/x-portable-pixmap}} | ||
+ | |- | ||
+ | |binary || <code>P6</code> || {{PRONOM|fmt/408}} | ||
+ | |} | ||
− | == | + | == Multi-image files == |
− | + | Although the Netpbm formats are usually thought of as single-image formats, the binary formats technically do support multiple images per file. This is accomplished simply by concatenating single-image files together. Such multi-image files are probably not well-supported. | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
== See also == | == See also == | ||
− | * [[PFM]] | + | * [[ImgStar]] |
+ | * [[MTV ray tracer bitmap]] | ||
+ | * [[Netpbm]] | ||
+ | * [[PABX background]] | ||
+ | * [[packPNM]] | ||
+ | * [[PFM (Portable Float Map)]] | ||
+ | * [[PFS (Portable Floatmap Stream)]] | ||
+ | * [[PHM]] | ||
+ | * [[Portable Arbitrary Map]] (PAM) | ||
+ | * [[XV thumbnail]] | ||
== Specifications == | == Specifications == | ||
− | * [http://netpbm.sourceforge.net/doc/pbm.html PBM] | + | * [http://netpbm.sourceforge.net/doc/pbm.html PBM Format Specification] |
− | * [http://netpbm.sourceforge.net/doc/pgm.html PGM] | + | * [http://netpbm.sourceforge.net/doc/pgm.html PGM Format Specification] |
− | * [http://netpbm.sourceforge.net/doc/ppm.html PPM | + | * [http://netpbm.sourceforge.net/doc/ppm.html PPM Format Specification] |
− | + | ||
== Software == | == Software == | ||
− | * [http:// | + | The PBM/PGM/PPM/PNM formats are widely supported. Software listed here has been arbitrarily selected. |
+ | * [[Netpbm]] | ||
+ | * [[ImageMagick]] | ||
+ | * {{Reggae}} | ||
+ | |||
+ | == Sample files == | ||
+ | * http://www.fileformat.info/format/pbm/sample/index.htm | ||
+ | * http://samples.libav.org/image-samples/ → *.ppm, *.pgm | ||
+ | * http://www.csbruce.com/cbm/ftp/images/pbm/ | ||
+ | * {{DexvertSamples|image/pbm}} | ||
+ | * {{DexvertSamples|image/pgm}} | ||
+ | * {{DexvertSamples|image/ppm}} | ||
− | == | + | == Links == |
− | * [[Wikipedia:Netpbm format]] | + | * [[Wikipedia:Netpbm format|Wikipedia: Netpbm format]] |
− | * [[ | + | * {{EGFF|pbm|PBM, PGM, PNM, and PPM File Format Summary}}, from the [[Encyclopedia of Graphics File Formats]] |
+ | * [https://github.com/corkami/pics/blob/master/binary/PGM.png Graphic describing PGM format] | ||
+ | * [https://github.com/corkami/pics/blob/master/binary/PPM.png Graphic describing PPM format] |
Latest revision as of 04:38, 28 December 2023
- "PBM" redirects here. For another PBM format, see ILBM#PBM.
- "PNM" redirects here. For another PNM format, see The Print Shop.
The Netpbm formats are a family of simple uncompressed raster image file formats, associated with the Netpbm library and suite of image processing utilities. They are designed so that it is straightforward for programmers to import and export them.
Due to their simplicity, the Netpbm formats are often used as "neutral" or "universal" image formats. It's not unusual for an image format's reference software to include a utility to convert to and from one of the Netpbm formats (and perhaps no other formats). Many of these conversion utilities have ultimately been incorporated into the Netpbm software.
Contents |
[edit] Formats
- PBM (portable bitmap) is a bi-level image format.
- PGM (portable graymap) is a grayscale image format.
- PPM (portable pixmap) is a color image format.
- PNM (portable anymap) is a collective name for PBM, PGM, and PPM. A .pnm file may use any of those formats.
- PAM: Refer to Portable Arbitrary Map. Although PAM is one of the Netpbm formats, it's different enough that it's best documented in a separate article.
[edit] Identifiers and Identification
Each file begins with two ASCII characters, which serve as a signature.
The PBM, PGM, and PPM formats come in two varieties: a text (or "plain" or "ASCII") format, and a binary (or "raw") format.
Format | Signature | PRONOM | MIME types | ||
---|---|---|---|---|---|
PBM | text | P1 |
x-fmt/164 | image/x-portable-bitmap | image/x-portable-anymap |
binary | P4 |
fmt/409 | |||
PGM | text | P2 |
fmt/407 | image/x-portable-graymap | |
binary | P5 |
fmt/406 | |||
PPM | text | P3 |
x-fmt/178 | image/x-portable-pixmap | |
binary | P6 |
fmt/408 |
[edit] Multi-image files
Although the Netpbm formats are usually thought of as single-image formats, the binary formats technically do support multiple images per file. This is accomplished simply by concatenating single-image files together. Such multi-image files are probably not well-supported.
[edit] See also
- ImgStar
- MTV ray tracer bitmap
- Netpbm
- PABX background
- packPNM
- PFM (Portable Float Map)
- PFS (Portable Floatmap Stream)
- PHM
- Portable Arbitrary Map (PAM)
- XV thumbnail
[edit] Specifications
[edit] Software
The PBM/PGM/PPM/PNM formats are widely supported. Software listed here has been arbitrarily selected.
[edit] Sample files
- http://www.fileformat.info/format/pbm/sample/index.htm
- http://samples.libav.org/image-samples/ → *.ppm, *.pgm
- http://www.csbruce.com/cbm/ftp/images/pbm/
- dexvert samples — image/pbm
- dexvert samples — image/pgm
- dexvert samples — image/ppm