Your #1 source for computer graphics plugins & scrips on the web!

Portable PixMap Importer Exporter

Version: 2.5
License: Freeware
Price: FREE
OS: Windows
Product URL: Link

Portable PixMap Importer Exporter is a small but versatile plugin for Adobe Photoshop that allows the import and export of the PixMap file format. The PPM / PGM / PBM file format is a convenient image file format which allows one to save an image in ASCII or BINARY mode. Because ASCII is simple text, it allows anyone to easily import these images into one’s own applications. It also allows one to open the ASCII file in any text editor and make changes if desired. ASCII images are text based and therefore large and slow loading. BINARY images are smaller and faster loading but are not text based.


Portable PixMap Importer Exporter has a lot of users in the development sector. This is because this tool is convenient for outputting imagery in a format that can be easily imported into custom coded material. The research for this plugin was taken in part from the very talented Paul Bourke.


It is important to understand the Portable PixMap file structure as it is often possible to make a previously-incompatible image compatible by manually adjusting an incorrect variable. A Portable PixMap Image file contains the following file structure:

P3 – The magic number. “P3″ = ASCII color, “P6″ = BINARY color, “P2″ = ASCII greyscale, “P5″ = BINARY greyscale, “P1″ = ASCII bitmap (black and white).

# A Comment – Comments preceded by the character “#”. Any number of lines at this point can be commented.

640 480 – Horizontal and vertical image resolution. Separated by a space.

255 – Maximum value of the color component. Usually “255″ for 8 bit images, “65535″ for 16 bit images.

0 0 0 255 128 0 – RGB, greyscale, or black and white information. Read in order of Red, Green then Blue. If RGB, there will be a red, green and blue integer. If greyscale, there will be a greyscale integer. If bitmap, there will be either “0″ (white) or “1″ (black).

Note that the lines should not be longer than 70 characters.

As an example, a typical color ASCII PPM would have the following file structure:

# Example
4 4
0 0 0 0 0 0 0 0 0 50 0 50
0 0 0 0 50 7 0 0 0 0 0 0
0 0 0 0 0 0 0 50 7 0 0 0
50 0 50 0 0 0 0 0 0 0 0 0

Richard Rosenman is a digital creative director working in the 3D computer graphics and animation industry. He also develops a collection of professional software tools used throughout the digital art industry.

Leave a Comment