开发者

24 bit Alpha Channel in Base64_encode

So I am experimenting with using icons in my CSS using base64 encoded pngs. I have used http://www.motobit.com/util/base64-decoder-encoder.asp to convert them. However, the pngs开发者_开发问答 only have an 8bit alpha channel, the pixels are either fully opaque, or fully transparent, no partial transparency. This is leaving my icons with hard edges. Any ideas of a 24bit alpha channel is possible through base64_encode?


The encoder in that page may be buggy. I made a PNG with alpha channels in Photoshop, encoded it using PHP's base64_encode(), put it in an image, and it works. Take a look at this fiddle for HTML and this fiddle for CSS.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜