Home > Common Problem > What format is png?

What format is png?

王林
Release: 2021-05-06 15:43:59
Original
9062 people have browsed it

png is a bitmap format that uses a lossless compression algorithm. It adds some features that the GIF file format does not have. The png format has many features such as small size, lossless compression, indexed color mode, and support for transparency effects.

What format is png?

#The operating environment of this article: windows10 system, thinkpad t480 computer.

png is a bitmap format that uses a lossless compression algorithm. Its design purpose is to try to replace the GIF and TIFF file formats, while adding some features that the GIF file format does not have. PNG uses a lossless data compression algorithm derived from LZ77, which is generally used in JAVA programs, web pages or S60 programs because of its high compression ratio and small file size.

Feature introduction:

Small size

Due to bandwidth constraints in network communication, it is impossible to use files on a large scale in web pages on the premise of ensuring clear and realistic pictures. Larger bmp format files.

Lossless compression

PNG files are compressed using an algorithm derived from the LZ77 algorithm. The result is a high compression ratio without loss of data. It uses a special encoding method to mark repeated data, so it has no impact on the color of the image, and no color loss is possible, so that it can be saved repeatedly without reducing the image quality.

Indexed Color Mode

The PNG-8 format is similar to GIF images, and also uses an 8-bit palette to convert RGB color images into indexed color images. What is saved in the image is no longer the color information of each pixel, but the representative color numbers selected from the image. Each number corresponds to a color, and the amount of data in the image is therefore reduced, which has a negative impact on the dissemination of color images. Very beneficial.

More optimized network transmission display

PNG images are streamed on the browser, even though the interleaved image provides the viewer with a basic image content before being fully downloaded, and then It gradually became clearer. It allows continuous reading and writing of image data, which is very suitable for displaying and generating images during communication.

Support transparency effect

PNG can define 256 transparent levels for the original image, allowing the edges of the color image to blend smoothly with any background, thereby completely eliminating jagged edges. This feature is not available in GIF and JPEG.

PNG also supports alpha channel transparency for true color and grayscale images.

Supports up to 24-bit true color images and 8-bit grayscale images. Supports alpha channel transparency/translucency. Supports gamma calibration information for image brightness. Supports storing additional text information to retain image name, author, copyright, creation time, comments and other information.

Free learning video sharing: Introduction to programming

The above is the detailed content of What format is png?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template