Image codecs

Vicente González Ruiz

June 24, 2014

Contents

1 PNM (Portable aNy Map) [7]
2 JPEG (Joint Photographic Experts Group) [4]
3 PNG (Portable Network Graphics) [6]
4 JPEG 2000 [3]
5 WebP [2]

1 PNM (Portable aNy Map) [7]

struct 8bpp_PPM {     struct 16bpp_PPM {  
  uint8 Red;            uint16 Red;  
  uint8 Green;          uint16 Green;  
  uint8 Blue;           uint16 Blue;  
};                    };  
 
struct PPM_format {  
  uint8[3] Magic_Number = "P6\n"; /* PPM = Portable Pix Map */  
  uint8* Width;                   /* Pixels in X (in ASCII) */  
  uint8 Space = " ";  
  uint8* Height;                  /* Pixels in Y (in ASCII) */  
  uint8 New_Line_1 = "\n";  
  uint8* Maximum_Component_Value; /* 255 or 65535 */  
  uint8 New_line_2 = "\n";  
  if (Maximum_Component_Value == 255) {  
    struct 8bpp_PPM[Width][Height] matrix;  
  } else {  
    struct 16bpp_PPM[Width][Height] matrix;  
  }  
};

2 JPEG (Joint Photographic Experts Group) [4]

3 PNG (Portable Network Graphics) [6]

4 JPEG 2000 [3]

5 WebP [2]

References

[1]   K. Huang and B. Smith. Lossless JPEG Codec version 1.0. Cornell University, June 1994.

[2]   Google Inc. Webm: an open web media project. http://www.webmproject.org.

[3]   International Organization for Standardization. Information Technology - JPEG 2000 Image Coding System - Core Coding System. ISO/IEC 15444-1:2004, September 2004.

[4]   The Joint Photographic Experts Group (JPEG). Recommendation T.81: Digital Compression and Coding of Continuous-tone Still Images. International Telecommunication Union (ITU), September 1992.

[5]   The Joint Photographic Experts Group (JPEG). FCD 14495, Lossless and Near-Lossless Coding of Continuous Tone Still Images (JPEG-LS). The International Standards Organization (ISO)/The International Telegraph and Telephone Consultative Committee (CCITT), July 1997.

[6]   J. Miano. Compressed Image File Formats: JPEG, PNG, GIF, XBM, BPM. Addison Wesley, 1999.

[7]   Jef Poskanzer and Bryan Henderson. Portable aNy Map. http://netpbm.sourceforge.net.