Q:

What is lossy compression, and when should you use it?

A:

Quick Answer

Lossy compression is a data reduction technique that involves an inexact approximation of encoded data as basis for compression. This kind of compression results in a smaller file size, but the output quality of the lossy-compressed file may be decreased significantly. Because of this, lossy compression is best used when storage size is more important than output quality.

Continue Reading

Full Answer

Lossy compression reduces the file size by removing parts of data that the compression engine sees as redundant or useless. The compressed output is something that is close enough to the original file, but further scrutiny reveals some details missing. An example of lossy compression is in a JPEG image file, wherein a degree of compression is altered to sacrifice image quality for file size. A JPEG image that underwent a high level of compression produces compression artifacts such as noise around certain areas of the picture or pixelated regions. In a similar fashion, an MPEG video shows noise and random dots on the screen when the level of compression is high.

Lossy compression is best used when the output quality is not important, or if the drive storage capacity cannot accommodate large files. In the case of photography and image editing, lossy compression is applied to images that don't need to be viewed in HD quality or in a large format. For instance, a typical website photo with 300 x 300 dimension is compressed at a high level without the viewer noticing any difference from the original picture. Lossy compression is applied to images produced for the purpose of mock-ups or previews that don't require the final image output to be displayed. Higher compression levels are also used in pictures with non-uniform colors and textures because the noise and compression artifacts blend with the background.

Learn more about Software

Related Questions

Explore