Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
August 10, 2017 03:42 pm GMT

Combine the transparency of a PNG with the compression of a JPG

JPG doesn't support alpha transparency. PNGs that do support alpha transparency don't compress nearly as well as JPG. SVG has masks and clipping paths, which we can use to our advantage here.

  • Drag and drop tool by Shaw to help do the trick. It produces an SVG containing a mask (for the transparency) and the raster graphic put together.
  • It's like ZorroSVG with more features. There is also some prior art here.
  • You can see how the masking works


“Combine the transparency of a PNG with the compression of a JPG” is a post from CSS-Tricks


Original Link: https://codepen.io/shshaw/full/LVKEdv

Share this article:    Share on Facebook
View Full Article

CSS Tricks

A Web Design Community curated by Chris Coyier

More About this Source Visit CSS Tricks