One of the benefits of PNG is its full alpha transparency, which allows you to have smooth edges and shadows in web designs. The main disadvantage is that it only supports lossless compression, which for complex images means a very large file size.
JPEG, on the other hand, provides greater compressibility for complex images, but without transparency.
Finally, I saw Flash elements ( example here ) with highly compressed images that also have smooth edges and shadows. I know little about Flash and have no idea how to do this. Basically this is the effect that I would like to do - a large, complex image with transparent and / or shaded edges.
My questions:
How is lossy compression performed with transparency in Flash?
Are any falsified background tricks used? Are the shadows generated or rasterized into an image, as I would have done with PNG.
Are there any scenarios for creating a SWF or SWF that could replace a PNG image with a lost compressed version?
I am thinking of a gradual improvement to increase the loading speed of certain design elements. If this does not exist, would it be possible to record it?
Are there any formats that allow lossy compression with transparency
It was hard for me to find specific information about this. DjVu can be a candidate? Should we encourage browser developers to support a different format?
Are there other solutions to this problem?
Doing everything in Flash or accepting huge file sizes are current options. Some other features:
- SVG and canvas can use edges, but IE is not supported.
- You can cut PNG along scan lines and compress them using JPEG, leaving the edges in PNG. This would be unpleasant in the source, but it would work in all browsers. Sounds like a fun project, I'll write it by morning. :)
- You can write a lossy image filter that can reduce the color complexity along the scan lines of the PNG algorithm to improve PNG compression. I just knew that this was supposed to exist, but I could not find it. Does anyone know about this?
Thank you for your help!
flash transparency png
Jerph
source share