Analysis of image formats

Source: Internet
Author: User
Tags bmp image

The image format is used to store images on a computer. Common storage formats include BMP, JPG, Tiff, GIF, PCX, TGA, EXIF, fpx, SVG, PSD, CDR, PCD, DXF, UFO, EPS, AI, raw, etc.

BMP Image File Format

BMP is an image file format unrelated to hardware devices. It uses a bit ing storage format. Apart from image depth options, it does not use any compression. Therefore, BMP files occupy a large amount of space. The image depth of BMP files can be lbit, 4bit, 8bit, and 24bit. When a BMP file stores data, the image is scanned in the order of left to right and bottom to top.

Because the BMP file format is a standard for exchanging graph-related data in windows, the graphic image software running in Windows supports the BMP image format.

A typical BMP image file consists of three parts: the data structure of the bitmap file header, which contains information such as the type and display content of the BMP image file; the bitmap information data structure, it contains BMP image width, height, compression method, and definition color information.

BMP is a Windows bitmap. Windows bitmap can use any color depth (from black and white to 24-bit color) to store a single grating image. The Windows bitmap file format is compatible with other Microsoft Windows programs. It does not support File compression and does not apply to web pages. In general, the disadvantage of the Windows bitmap file format exceeds its advantages. To ensure the quality of the image, use PNG, JPEG, and TIFF files. The BMP file is applicable to wallpapers in windows.

Advantage: BMP supports color depth from 1 to 24 bits.

The BMP format is widely compatible with existing Windows programs (especially older programs.

Disadvantage: BMP does not support compression, which causes a large file size.

PCX Image File Format

The formation of image files such as PCX has a development process. The first format of pcpcx image file x appeared in zsoft's commercial software package called PC painbrush for painting. In the future, Microsoft will transplant it to the Windows environment and become a sub-function in the Windows system. It is widely used in Microsoft's windows3.1. With the popularity and upgrade of windows and its powerful image processing capabilities, PCX is used together with GIF, Tiff, and BMP image file formats, being supported by more and more graphic and image software tools, people are getting more and more attention.

PCX is one of the earliest file formats that support color images. Currently, it supports up to 256 colors. The designers of PCX have a vision to introduce the color image file format, making it a very popular image file format.

A pcx image file consists of a file header and actual image data. The file header consists of 128 bytes to describe the version information, horizontal and vertical resolution of the image display device, and the color palette. In actual image data, it indicates the image data type and color type. The data in PCX image files is the image data compressed by pcxrel technology.

PCX is the image file format of the PC paint brush. The PCX image depth can be L, 4, or 8 bits. Because this file format appears earlier, it does not support true color. The PCX file uses RLE travel encoding, and the file body stores the compressed image data. Therefore, when writing the collected image data into the PCX file format, you need to encode it by Rle. When reading a PCX file, you must first perform RLE decoding on it, can be further displayed and processed.


PCX is in standard format between many Windows-based programs and MS-DOS-based programs.

PCX supports internal compression.


PCX is not supported by Web browsers

TIFF Image File Format

Tiff (taglmagefileformat) is a common image file format developed by Aldus and Microsoft for the TIFF image file format edition system. The TIFF format is flexible and variable, and it defines four different formats: TIFF-B is suitable for Binary Images (that is, each pixel is not black or white, its gray value does not have intermediate transition of the image. Binary Images are generally used to describe text or images. The advantage is that they occupy less space and the disadvantage is that when they represent a person or a landscape image, a binary image can only describe its contour, details cannot be described. At this time, a higher gray level is required .) : TIFF-G for black and white gray images; TIFF-P for color images with color palette: TIFF-R for RGB true color images.

Tiff supports multiple encodings (using predefined methods to compress text, numbers, or other objects into digital data, or convert information and data into prescribed electric pulse signals. Encoding is the process of converting information from one form or format to another. Coding is widely used in electronic computers, televisions, remote control and communication .) Including RGB, RLE, and JPEG.

Tiff is one of the most complex formats of existing image files. It is scalable, convenient, and changeable and can be provided to running and image editing programs in ibnmpc and other environments.

A tiff image file consists of three data structures: the file header, one or more directories containing labeled pointers and the data itself, known as IFD (interface device.

The first data structure in a TIFF image file is called the image file header or IFH. This structure is a unique and fixed part of a tiff file. The IFD image file directory is a variable-byte information block, and tag is the core part of the TIFF file, all image parameters are defined in the image file directory. Each directory entry contains a parameter of the image.

Experience: Save the image as a TIFF format during graphic spray. After the format is stored, you can enable it in PS for editing and image processing.

GIF format

The original meaning of Graphics Interchange Format is "image Interchange Format", which is an image file format developed by CompuServe in 1987. The data of GIF files is based on LZW (the correspondence between strings and codes is dynamically generated during the compression process, and is hidden in the compressed data, perform Restoration Based on the table during decompression, which is considered a lossless compression .) the lossless compression format of the continuous tone of the algorithm. Generally, the compression rate is about 50%. It does not belong to any application. Currently, almost all related software is supported. A large number of software in the public domain are using GIF image files.

The data in GIF image files is compressed and adopts a variable length compression algorithm. Therefore, the GIF image depth ranges from lbit to 8bit, that is, GIF supports up to 256 colors. Another feature of the GIF format is that it can store multiple color images in a GIF file. If you read multiple image data in a file one by one and display it on the screen, to form the simplest animation.

GIF Decoding is faster, because the GIF images stored in the same line can be divided into four scans during side decoding and display. Although the first scan only shows 1/8 of the entire image, the second scan only shows 1/4, But this shows the overall image. When a GIF image is displayed, the image stored in the interline will show you the speed that it seems to be faster than other images, which is an advantage of the interline storage.

Experience: Space spoof pictures

Classroom experience: provides cross-platform capabilities and is supported by all image browsers. You do not have to worry about compatibility issues, but can reduce the number of color displays and compress files, you can store multiple images and dynamically display these images.

JPEG format

JPEG is the abbreviation of the JPEG format of joint photographic Experts Group (joint image Expert Group ". jpg "or ". JPEG is the most common image file format, developed by a software development federation, and is a lossy compression format that compresses images in a small storage space, duplicate or unimportant data in the image will be lost, which may cause damage to the image data. In particular, the use of a high compression ratio will significantly reduce the quality of the restored image after the final decompression. If the pursuit of high-quality images, it is not appropriate to use a high compression ratio. However, the JPEG compression technology is very advanced. It uses lossy compression to remove redundant image data and can present rich and vivid images while obtaining an extremely high compression ratio. In other words, that is, you can use the least disk space to get better image quality. Moreover, JPEG is a flexible format with the function of adjusting image quality. It allows different compression ratios to compress files and supports multiple compression levels, the compression ratio is usually between to 40: 1. The larger the compression ratio, the lower the quality. On the contrary, the smaller the compression ratio, the better the quality. For example, you can compress a 1.37mb BMP bitmap file to 3kb. Of course, we can also find a balance between image quality and file size. The JPEG format is mainly used to compress high-frequency information, which is well preserved for color information. It is suitable for the Internet and can reduce the image transmission time and support 24-bit true color, it is also widely used in images that require consecutive tones.

The JPEG format is currently the most popular image format on the network. It can compress files to the smallest format. When stored in JPEG format in Photoshop software, it provides a compression level of 13, the value is 0-12. Among them, the 0-level compression ratio is the highest, and the image quality is the worst. The compression ratio is up to even when the details are saved with almost lossless 10-level quality. A mb image file is generated when it is saved in BMP format. When it is saved in JPG format, the file size is only 178kb and the compression ratio reaches. After many comparisons, 8th-level compression is used as the best combination of storage space and image quality.

The JPEG format is widely used, especially in network and optical disc reading. Currently, all types of browsers support JPEG image formats, because the size of JPEG files is small and the download speed is fast.

As an upgraded version of JPEG, the compression rate is about 30% higher than that of JPEG, and lossy and lossless compression is supported. One of the most important features of the MPEG-4 format is that it can achieve progressive transmission, that is, first transmission of the image contour, and then gradually transmission of data to continuously improve the image quality, so that the image can be clearly displayed from the haze. In addition, it supports the so-called "regions of interest" feature. You can specify the compression quality of the regions of interest on the image, and extract the specified part first.

Compared with JPEG, the latter has obvious advantages and is backward compatible. Therefore, the latter can replace the traditional JPEG format. It can be applied to traditional JPEG markets, such as scanners and digital cameras. It can also be applied to emerging fields, such as network transmission and wireless communication.


Photographic or realistic works support advanced compression.

The variable compression ratio can be used to control the file size.

Supports interleaved (for gradient JPEG files ).

JPEG supports Internet standards widely.


Lossy compression can reduce the quality of raw image data.

When you edit and re-save a jpeg file, the quality of the original image data is decreased. This decline is cumulative.

JPEG is not applicable to simple images with very few colors, areas with similar color blocks, or with very obvious brightness differences.

Experience: Do not save layers for images in this format (when the original processing file is in PSD format ).

Classroom experience: supports 16.7 million colors to reproduce photographic images, especially the colorful nature. It is lossy compression, but it cannot be seen by viewers. The transparent background and staggered display functions in GIF format are not supported.

TGA format

The TGA format (tagged graphics) is an image file format developed by truevision for its TGA format display card. The file suffix is ". TGA has been accepted by the image and image industry internationally. The structure of the TGA is relatively simple. It is a common format of graphics and image data, which has a great impact in the multimedia field. It is a preferred format for computer-generated image conversion to television.

The biggest feature of the TGA image format is the ability to make irregular shapes of graphics, image files, General graphics, image files are square, if you need to have a circular, diamond or even a blank image file, the TGA is useful! The TGA format supports compression and uses a true compression algorithm. Is a good image format.

EXIF format

The EXIF format is a digital camera image file format promoted by Fuji in 1994. In fact, it is the same as the JPEG format, except for storing image data, it also stores exposure materials and ancillary information such as photo dates, use aperture, shutter, and flashlight data, as well as small size images.

Fpx format

The fpx Image File Format (fpx extension) was developed by Kodak, Microsoft, HP, and live pictureinc and was officially published in June 1996. fpx is an image format with multiple resolutions, that is, the image is stored as a series of different resolutions. The advantage of this format is that the image quality can be maintained when the image is enlarged. In addition, when you modify the fpx image, only the modified part is processed, and the entire image is not processed together. This reduces the burden on the processor and memory and reduces the image processing time. Its multi-resolution storage method is favored by many people.

SVG format

SVG is a scalable vector image (a vector image is drawn based on geometric characteristics. It features no distortion in the enlarged image and is irrelevant to the resolution. The file occupies less space, suitable for graphic design, text design, Logo Design, layout design, etc .) Format. It is an open standard vector graphics language that allows you to zoom in on any image display. The edges are exceptionally clear and the text remains editable and searchable in the SVG image without any font restrictions, the generated file is small and can be downloaded quickly. It is suitable for designing high-resolution web graphics pages.

PSD format

This is the specialized file format of Photoshop image processing software. The file extension is. PSD, which supports various image features of layers, channels, masks, and different color modes. It is a non-compressed original file storage format. The scanner cannot directly generate files in this format. PSD files sometimes have a large capacity, but because all the original information can be retained, it is the best choice to save the unfinished image in image processing.

Experience: Design and Process with PS

CDR format

The CDR format is the specialized Graphic File Format of CorelDraw, a famous drawing software. Since CorelDraw is a vector graphics rendering software, CDRS can record the attributes, locations, and pages of a file. However, it is less compatible and can be used in all CorelDraw applications, but other image editing software cannot open such files.


PCD File Format


PCD is short for Kodak photocd. The file extension is. POD. It is a photo CD file format developed by Kodak. Other software systems can only read it. This format uses the ycc color mode to define the color in the image. The ycc and CIE color spaces contain more colors than the RGB and CMYK colors of the display and print devices. Most photocd images have very high quality.

DXF File Format

DXF is the abbreviation of Drawing Exchange Format. Its extension is. autoCAD (Auto computer aided design) is the first automatic computer aided design software developed by Autodesk in 1982, it is used for 2D drawing, detailed drawing, design documents, and basic 3D design .) It stores images in ASCII format and is very precise in the aspect of displaying the image size. It can be called and edited by large software such as CorelDraw and 3DS.

UFO File Format

It is a specialized image format of Ulead photolmapct, a well-known image editing software. It can fully record all image properties processed by photolmapct. It is worth mentioning that the UFO file uses an object instead of a layer to record image information.


EPS file format

EPS is the abbreviation of encapsulated postscript. It is a standard cross-platform format. Its extension is. EPS on the PC platform and. EPSF on the Macintosh platform. It is mainly used for the storage of vector and grating images. The EPS format is described in PostScript Language, and other types of information can be saved, such as multi-tone curves and Alpha channels (alpha channel is an 8-bit grayscale channel, this channel uses a gray scale of 256 to record the transparency information in the image. It defines transparent, opaque, and translucent areas, where black indicates full transparency, White indicates opacity, and gray indicates translucent .) {PS channels}, color separation, editing path, network-mounted information, and tone curves. Therefore, the EPS format is often used for printing or printing output. The multiple EPS format options in Photoshop can achieve comprehensive control of printing, in some cases, or even better than the TIFF format.

PNG Image File Format

Portable Network Graphics (PNG), formerly known as "portable PNG Image File Format implant network images", is the latest image file format accepted online. PNG can provide lossless compression of image files 30% less than GIF. It also provides 24-bit and 48-bit true-color image support and many other technical support. Since PNG is very new, not all programs can use it to store image files, but Photoshop can process PNG image files or store them in PNG image file format.


PNG supports advanced lossless compression.

PNG supports alpha channel transparency.

PNG supports Gamma Correction.

The PNG file can be staggered.

PNG is supported by the latest web browser.


Older browsers and programs may not support PNG files.

As an Internet File Format, PNG provides less compression than JPEG compression with loss.

As an Internet File Format, PNG does not support multiple image files or animated files. GIF format supports multiple image files

And animation files.
Classroom experience: the advantage of dedicated network images is lossless compression, which is better than GIF. Supports up to 16.7 million colors and supports Alpha transparency.

Hdri Image File Format

Hdri files are in HDR or Tif format. They are capable of storing illumination information, but not necessarily panorama. Dynamic Range (Dynamic Range) refers to the relative ratio between the brightest part and the dark part of a scenario. An HDR Image records the brightness values of an actual scenario that is far beyond 256 levels. The excess is invisible on the screen.

Hdri has a greater brightness range than ordinary RGB Images (only 8 bit brightness range. The maximum brightness of a standard RGB image is 255/255/255. If such an image is used in combination with light energy to deliver illumination for a scenario, even the brightest white is not enough to provide enough light to simulate the real world, rendering results look dull and lack of contrast, the reason is that this image file only uses an 8bit RGB image to describe a wide range of illumination information in reality.

AI Image File Format

The AI format is a vector graphics file, suitable for Adobe's illustrator output format. Like PSD files, AI is also a hierarchical file. Each object is independent and has its own attributes, such as size, shape, outline, color, and position. Files saved in this format are easy to modify. files in this format can be output at the maximum resolution at any size. It is highly compatible and can be opened in CorelDraw or exported to AI format.

RAW image format

Raw is interpreted as raw material or unprocessed ". The raw file contains all the photo information before the original image file is generated by the sensor and enters the camera image processor. You can use some specific software on the PC to process raw images.

Storage and advantages

By understanding the topics of Color Filtering and arrangement, we should know that in traditional sensors, each pixel is only responsible for obtaining one color. The data carried by each pixel is usually 10 or 12 bits (12 bits are most commonly used), and the data can be stored in raw files. The camera's built-in image processor uses the raw data for interpolation, computes the values of three color channels, and outputs a 24-bit JPEG or TIFF image. Although the TIFF File retains 8-bit information per color channel, its file size is larger than raw (TIFF: 3x8-bit color channel; raw: 12-bit raw channel ). JPEG compresses the original photo file to reduce the file size, but the compression is at the cost of image quality. Therefore, raw is the balance between the two: ensuring the image quality and color, while saving storage space (relative to TIFF ). Some high-end digital cameras can output almost lossless compressed raw files.


Many image processing software can process raw files output by cameras. These software allows you to adjust the sharpness, white balance, color order, and color of raw photos. In addition, because raw has 12-bit data, you can extract photo details from the highlights or dimples of raw images through software, these details cannot be found in 8-bit JPEG or tiff images per channel.


Raw has an obvious drawback: different camera brands and models make them different from raw image formats. When processing raw images, users must use the specialized software provided by the manufacturer. This makes image processing inconvenient. In addition, it takes more time to open and process raw files than JPEG and Tiff images. To solve this problem, some digital cameras allow users to store photos in raw and JPEG formats when taking photos. As the camera processes images faster and faster, and the memory card capacity is getting bigger and cheaper, the above practices will no longer bother. Recording JPEG and raw photos at the same time allows users to organize and edit photos (JPEG) using conventional image processing software ); you can use raw to solve the problem when you need to obtain a fine-grained photo or improve the photo defects (such as incorrect white balance and missing highlights/dark details. In addition, more and more third-party software manufacturers are making some compatible image processing software, so that multiple brands and models of cameras can use the same software to process their output raw photos, solve RAW compatibility issues. Adobe Photoshop CS is one example. However, Adobe Photoshop CS does not provide comprehensive raw processing settings like the manufacturer's specialized software. Poor compatibility is still the biggest obstacle to the development of raw formats.

Summary:If the image color is less than 256 colors, we recommend that you use the GIF format, such as the logo. When the color is rich, use the JPEG format, such as displaying the natural image on the webpage, if you want to retain more color details and the translucent Feather Effect, we recommend that you use the PNG format.


Analysis of image formats

Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

Apsara Conference 2019

The Rise of Data Intelligence, September 25th - 27th, Hangzhou, China

Learn more >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.