Home  >  Article  >  Web Front-end  >  One trick to teach you how to optimize the file size of PNG and JPG images

One trick to teach you how to optimize the file size of PNG and JPG images

little bottle
little bottleOriginal
2019-04-08 14:53:327913browse

This article mainly talks about using PhotoShop to optimize the file size of PNG and JPG images.

One trick to teach you how to optimize the file size of PNG and JPG images

PNG (Portable Network Graphic Format, PNG) picture is an image file storage format, its purpose is to try to replace the GIF and TIFF file formats, while adding some GIF file formats Features that are not available. When PNG is used to store grayscale images, the depth of the grayscale image can be up to 16 bits. When storing color images, the depth of the color image can be up to 48 bits, and it can also store up to 16 bits of alpha channel data.

It is precisely because of the superiority of using PNG images in web pages that a large number of website images now use PNG images. However, many times the size of the PNG images we make is too large, which requires the use of special software to edit PNG images. Image size is compressed and optimized.

Use PhotoShop to open the PNG and JPG images to be optimized

One trick to teach you how to optimize the file size of PNG and JPG images

##"Save as WEB format Alt Ctrl Shift s"

In the dialog box, set the default value to "PNG-8 128 dither" or other png formats, Set the picture color according to the picture color complexity: 2, 4, 8, 16, 32, 64, 128, 256. The fewer the number of colors, the fewer colors can be displayed and the smaller the picture size.


One trick to teach you how to optimize the file size of PNG and JPG images

Storage

When setting, you can see the optimization in the status bar below the picture After adjusting the image file size to the size and image quality you are satisfied with, click the "Save" button.

[Recommended course:

PS video tutorial]

The above is the detailed content of One trick to teach you how to optimize the file size of PNG and JPG images. For more information, please follow other related articles on the PHP Chinese website!

Statement:
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
Previous article:How to set ps preferencesNext article:How to set ps preferences