pcdtojpeg is a command line utility which is used as follows:
 
  1. pcdtojpeg [options] file1 [file2]
 
Where file1 is a PCD file, and file2 is a jpeg file. If file2 is not specified, then pcdtojpeg will create a filename by changing the extension of file1 to jpg.
 
Valid options:
-h            Print this message
-v            Verbose file information
-m           Process the file as monochrome
-D50        Process for a white balance of D50
-D65        Process for a white balance of D65
-q nnn      JPEG file quality (nnn range 1 to 100)
-b n.n       Brightness adjustment (n.n range -2.0 to 2.0)        
-r n          Highest resolution to extract (n range 0 to 5):
                 0 - Base/16 (128 x 192)
                 1 - Base/4 (256 x 384)
                 2 - Base (512 x 768)
                 3 - 4Base (1024 x 1536)
                 4 - 16Base (2048 x 3072)
                 5 - 64Base (4096 x 6144)
 
Defaults are -D65 -q 100 -b 0.0 -r 4 : D65 color balance, 100% JPEG quality, no adjustment to image brightness, 2048 x 3072 resolution.
 
Note the following important information:
 
  1. 1.pcdtojpeg does not allow options to be concatenated on the command line - so you must enter options in full e.g., “-v -m” rather than “-vm”.
  2. 2.If pcdtojpeg can’t extract an image at the exact resolution specified, it will fall back to the best available resolution that is lower that specified.
  3. 3.The brightness adjustment is non-clipping; there is no loss of highlight information involved in using it. Aka it is a “true” brightness adjustment as distinct from a exposure adjustment.
  4. 4.64Base images (“-r 5”) consist of a 16Base PCD file and a number of image extension files. pcdtojpeg will only be able to find the extension files if the file structure (the relative locations) of the PCD file and the image extension files are the same as for the original Photo CD. See the separate page on 64Base images for more information.
 
The easiest was to use pcdtojpeg is to open a terminal in the location that you copied the binary files to. e.g., if you copied the files to a PCD folder on the desktop, and have a file called test.pcd in that directory as well, you would open a terminal, then:
 
  1. In Windows: pcdtojpeg test.pcd

    In OS X: ./pcdtojpeg test.pcd
  2. In Linux: ./pcdtojpeg test.pcd
  3.  
This example will convert test.pcd into test.jpg. For OS X or Linux, the leading “./” is required - in the examples below, its use is assumed if you are using OS X or Linux.
 
Example: Convert to a named output file
To convert a PCD image to a JPEG file with a different name, do the following:
 
  1. pcdtojpeg test.pcd output.jpg
 
Example: Convert at maximum quality
To convert at maximum quality, do the following:
 
  1. pcdtojpeg -q 100 test.pcd
 
Example: Increase brightness
Many PCD images appear dark when converted. To increase brightness, do the following:
 
  1. pcdtojpeg -b 1.0 test.pcd
 
Usually, a brightness value of between 0.0 and 1.0 will be required. The default - no adjustement to brightness - is 0.0.
 
Example: Convert a 64Base (4096 x 6144) image
To convert a Base64 image, do the following (note that the directory structure of the base image and its extension file must be correct):
 
  1. pcdtojpeg -r 5 test.pcd
 
Example: Get image metadata
You can get a variety of image metadata such as the date the image was scanned, the scanner used, the film used, etc as follows:
 
  1. pcdtojpeg -v test.pcd
  2.  
 
Using pcdtojpeg with PCD Files