White Maskers White Maskers - 10 months ago 53
CSS Question

How is it possible to smoothing the edges of an image using CSS?

When I tried to add an image in to my website its edges feel very rough.

enter image description here(note: in the above image you can see the rough surface around the berry).

This happened when I removed its background using an image editor.Is it possible to smooth the edges using css? If yes,then how?

thanks in advance...!!!

Answer Source

Don't try to fix this using css. Instead use a png24 (not png8 or gif) because that has proper alpha (transparency) and remove the background colour by using the background colour as an alpha mask (or similar technique).

You can do all this with free software like GIMP if you don't have something like PhotoShop

Edit: I just noticed that it's available as an svg, why aren't you using that?