Chinese name: image compression coding nature: compression coding mode: MP image file format, etc. Source: Definition, classification, basic approach of electronic field, comparison of several codes, definition of transforming, coding and compressing image data to meet certain fidelity requirements, removing redundant data and reducing the amount of data needed to represent digital images, so as to facilitate image storage and transmission. That is, the technique of representing the original pixel matrix with less data is also called image coding. Classified image compression coding can be divided into two categories: one is reversible, that is, the original image can be completely recovered from compressed data without losing information, which is called lossless compression coding; The other compression is irreversible, that is, the compressed data can not completely restore the original image, and the information is lost to a certain extent. This compression is called lossy compression coding. The data of the basic path image is huge, and it must be greatly compressed before it can be stored on an optical disk with a diameter of 12cm. In practical technology, the total amount of image data can be compressed in the following ways. 1. luminance (y) and chrominance (c) sampling methods are adopted. 2. Divide the whole image into small areas for segmentation. 3. Adopt inter-frame and intra-frame data compression technology. Comparison of several encoded BMP image file formats BMP is an image file format that has nothing to do with hardware devices and is widely used. It uses bitmap storage format and does not use any other compression except image depth, so BMP files take up a lot of space. The image depth of BMP file can be selected from lbit, 4bit, 8bit and 24bit. When data is stored in a BMP file, images are scanned from left to right and from bottom to top. Because BMP file format is the standard for exchanging data related to drawings in Windows environment, all graphics and image software running in Windows environment supports BMP image format. A typical BMP image file consists of three parts: the data structure of bitmap file header, which contains information such as the type and display content of BMP image file; Bitmap information data structure, including BMP image width, height, compression mode, defined color and other information. The formation of PCX image file format PCX has a development process. The first prototype of PCX appeared in the commercial painting software package named PC PAINBRUSH launched by ZSOFT Company. Later, Microsoft transplanted it into the Windows environment and became a sub-function of the Windows system. It was first widely used in Microsoft Windows 3. 1. With the popularization and upgrade of Windows and its powerful image processing capability, PCX, together with GIF, TIFF and BMP image file formats, are supported by more and more graphics and image software tools, and people pay more and more attention to them. PCX is the earliest file format that supports color images, and now it can support 256 colors at most, as shown in Figure 4-25, which displays 256-color images. PCX designers introduced the color image file format with foresight, making it a very popular image file format. PCX image file consists of file header and actual image data. The file header consists of 128 bytes, which describes version information, horizontal and vertical resolution of image display equipment, color palette and other information: in actual image data, it indicates image data type and color type. The data in PCX image files are all image data compressed by PCXREL technology. PCX is a computer brush with image file format. The image depth of PCX can be selected as 1, 4 and 8 bits. Because this file format appeared earlier, it does not support true color. PCX file adopts RLE run coding, and the compressed image data is stored in the file body. Therefore, when the collected image data is written into PCX file format, RLE coding should be carried out; When reading the PCX file, it should be RLE decoded before further display and processing. TIFF image file format TIFF(TaglmageFileFormat) image file is a common image file format developed by Aldus and Microsoft for desktop publishing system. TIFF format is flexible and changeable. It defines four different formats: TIFF-B is suitable for binary images, TIFF-G is suitable for black and white gray images; TIFF-P is suitable for color images with palette; TIFF-R is suitable for RGB true color images. TIFF supports a variety of coding methods, including RGB compression, RLE compression and JPEG compression. TIFF is one of the most complex image file formats, which is extensible, convenient and modifiable, and can be provided for running and image editing programs in IBMPC and other environments. TIFF image file consists of three data structures, namely, the file header, one or more directories called IFD containing marker pointers, and the data itself. The first data structure in a TIFF image file is called an image file header or IFH. This structure is the only part with a fixed position in the TIFF file; The directory of IFD image file is an information block with variable byte length, and the Tag tag is the core part of TIFF file. All the image parameters to be used are defined in the directory of the image file, and each directory entry in the directory contains one image parameter. GIF file format GIF (Graphic Interchange Format) originally meant "Image Interchange Format" and was developed by CompuServe Company on 1987. The data of GIF file is a continuous tone lossless compression format based on LZW algorithm. Its compression ratio is generally around 50%, which does not belong to any application. At present, almost all related software supports it, and a large number of software in the public domain are using GIF image files. The data of GIF image file is compressed by variable length compression algorithm. Therefore, the image depth of GIF varies from lbit to 8bit, which means that GIF can support 256-color images at most. Another feature of GIF format is that images with multiple colors can be stored in a GIF file. If the data of multiple images stored in a file are read out one by one and displayed on the screen, the simplest animation can be formed. GIF decoding is faster, because interlaced GIF images can be divided into four scans when decoding and displaying. Although the first scan only showed one-eighth of the whole image, and the second scan only showed 1/4, it has already shown an overview of the whole image. When displaying GIF pictures, staggered pictures will make you feel that its display speed seems to be faster than other pictures, which is the advantage of staggered storage. JPEG file format JPEG is the abbreviation of Joint Photographic Experts Group. The file name is ".. jpg" or ". Jpeg ",which is the most commonly used image file format. It is a lossy compression format organized by the Software Development Association. It can compress the image in a small storage space, and the repeated or unimportant data in the image will be lost, so it is easy to damage the image data. Especially, if the compression ratio is too high, the quality of the restored image after final decompression will obviously decrease. If you pursue high-quality images, you should not use too high compression ratio. But JPEG compression technology is very advanced. It uses lossy compression to remove redundant image data, and can display very rich and vivid images at the same time, in other words, it can obtain better image quality with the least disk space. Moreover, JPEG is a very flexible format with the function of adjusting image quality. It allows files to be compressed at different compression ratios and supports multiple compression levels. The compression ratio is usually between 10: 1 and 40: 1. The higher the compression ratio, the lower the mass. On the contrary, the smaller the compression ratio, the better the quality. For example, you can compress the BMP bitmap file of 1.37Mb to 20.3KB Of course, we can also find a balance between image quality and file size. JPEG format mainly compresses high-frequency information and preserves color information well. It is suitable for the Internet, can reduce the image transmission time, supports 24-bit true color, and is also widely used for images that need continuous tone. JPEG format is the most popular image format on the Internet at present, which can compress files to a minimum. When stored in JPEG format in Photoshop software, the compression level of 1 1 is provided, which is expressed as 0- 10. Level 0 has the highest compression ratio and the worst image quality. The compression ratio can reach 5: 1 even if the quality maintenance with almost no loss of details is adopted. When saved in BMP format, 4.28MB image file is obtained. When saved in JPG format, the file size is only 178KB, and the compression ratio reaches 24: 1. After many comparisons, eight-level compression is the best ratio of storage space and image quality. JPEG format is widely used, especially on the Internet and CD-ROM. At present, all kinds of browsers support JPEG as the image format, because the file size of JPEG format is small and the download speed is fast. As an upgraded version of JPEG, JPEG2000 has a compression ratio about 30% higher than that of JPEG, and supports both lossy and lossless compression. An extremely important feature of JPEG2000 format is that it can realize progressive transmission, that is, the outline of the image is transmitted first, and then the data is transmitted step by step, so as to continuously improve the image quality and make the image display from hazy to clear. In addition, JPEG2000 also supports the so-called "region of interest" function, which can arbitrarily specify the compression quality of the region of interest on the image, or select the specified part to decompress first. Compared with JPEG, JPEG2000 has obvious advantages and backward compatibility, so it can replace the traditional JPEG format. JPEG2000 can be used not only in the traditional JPEG market, such as scanners and digital cameras, but also in emerging fields, such as network transmission and wireless communication. TGA format TGA format (Tagged Graphics) is an image file format developed by American Truevision Company for its graphics card. The file suffix is ". TGA "has been accepted by the international graphic and image industry. TGA has a simple structure, belongs to the general format of graphics and image data, has great influence in the field of multimedia, and is the preferred format for converting computer-generated images into TV. The biggest feature of TGA image format is that it can make irregular shapes of graphics and image files. Generally, graphics and image files are square. If you need circular, diamond or even empty image files, TGA can come in handy! TGA format supports compression and uses lossless compression algorithm. EXIF format EXIF format is a digital camera image file format advocated by Fuji Company in 1994, which is actually the same as JPEG format. The difference is that it can also store exposure data such as shooting date, aperture, shutter and flash data, incidental information and small-size images. Fpx Image File Format FPX Image File Format (Extended FPX) was jointly developed by Kodak, Microsoft, Hewlett-Packard and Live PictureInc, and officially released on June 1996. FPX is an image format with multiple resolutions, that is, images are stored in a series of different resolutions. The advantage of this format is that the image quality can still be maintained when the image is enlarged. In addition, when the FPX image is modified, only the modified part will be processed, and the whole image will not be processed at the same time, thus reducing the burden on the processor and memory and reducing the image processing time. SVG format SVG is a scalable vector graphics format. It is an open and standard vector graphics language, which can enlarge the graphics display at will and has extremely clear edges. Characters remain editable and searchable in SVG images, and there are no font restrictions. The generated file is small and fast to download, which is very suitable for designing high-resolution web pages. PSD file format This is a special file format of Photoshop image processing software. The file extension is. PSD can support various image features of layers, channels, masks and different color modes. It is an uncompressed original file storage format. Scanners cannot directly generate files in this format. PSD file sometimes has a large capacity, but because it can retain all the original information, it is the best choice to save the unfinished image in PSD format in image processing. XI。 CDR file format CDR format is a special graphic file format of the famous drawing software CorelDRAW. CorelDRAW is a vector graphics drawing software, so CDR can record the attributes, location and paging of files. However, it has poor compatibility and can be used in all CorelDraw applications, but other image editing software cannot open such files. Twelve, PCD file format PCD is the abbreviation of Kodak photo CD, and the file extension is. . Pod, which is a PhotoCD file format developed by Kodak, can only be read by other software systems. This format uses YCC color mode to define colors in images. YCC and CIE color spaces contain much more colors than RGB and CMYK colors of displays and printing devices. Most of the PhotoCD images are of very high quality. Thirteen. DXF file format DXF is the abbreviation of graphic exchange format, and the extension is. DXF。 It is a graphic file format in AutoCAD. It stores graphics in ASCII, which is very accurate in representing the size of graphics, and can be called and edited by large-scale software such as CorelDraw and 3DS. 14.UFO file format It is a special image format of the famous image editing software Ulead Photolmapct, which can completely record all the image attributes processed by PhotoMapCT. It is worth mentioning that UFO files use objects instead of layers to record image information. 15.EPS file format EPS is the abbreviation of Encapsulated PostScript, which is a cross-platform standard format. The extension is. EPS and PC platform. . Epsf on Macintosh platform is mainly used to store vector images and raster images. EPS format is described in PostScript language, which can save other types of information, such as multi-tone curve, Alpha channel, color separation, clipping path, screen hanging information and tone curve. Therefore, EPS format is usually used for printing or printout. Many EPS format options in Photoshop can achieve full control of printing, and even better than TIFF format in some cases. 16.PNG image file format PNG (portable Neorf Graphics), formerly known as "portable network image", is the latest accepted image file format on the Internet. PNG can provide lossless compressed image files that are 30% shorter than GIF. It also provides 24-bit and 48-bit true color image support and many other technical support. Because PNG is very new, not all programs can use it to store image files at present, but Photoshop can handle PNG image files and can also store them in PNG image file format.