Learn when to correctly use antialiasing in images that contain text and other objects with sharp edges.

Sponsored Links

When to use anti-aliasing

Before you begin this article make sure you have read about anti-aliasing and anti-aliasing and 'halo' formation. And remember, anti-aliasing increases the number of colors in an image and hence the file size. It should not be applied blindly to all objects and text.

When to use anti-aliasing

Anti-aliasing should be employed for objects with curved edges such as
1). Ovals and circles,
2). Any text above 10 point size, so that its edges appear smooth,
3). Straight lines that are not exactly vertical or horizontal.

When to avoid anti-aliasing

1). Small text (text below 10 point size). Such text, if anti-aliased, appears messy. Check the images below

Image that serves as a button with anti-aliased text24 color Gif image with anti-aliased text: 1350 bytes

Image that serves as a button with non anti-aliased text2 color Gif image with anti-aliased text: 280 bytes

Note the difference in file size.

2). Straight lines that are exactly vertical or horizontal do not need to be anti-aliased. The same is true for objects that contain straight vertical and horizontal lines such as squares and rectangles.

Anti-aliased rectangle 12 color Gif image: 291 bytes
Anti-aliased rectangle

Non Anti-aliased rectangle 2 color Gif image: 218 bytes
Rectangle without anti-aliased lines

The case of the rounded-rectangle

Rounded rectangles have curved edges. It follows from what we have discussed so far, that since the edges are curved, we should use anti-aliasing on the figure. Actually, the decision whether to implement anti-aliasing or not depends on the amount of curvature and the final look of the image you want. I would not like to pass any judgements, but leave the choice to you.

Rounded rectangle with anti-aliased edges16 color gif: 373 bytes
Rounded rectangle with anti-aliased edges

Rounded rectangle with non anti-aliased edges3 color gif: 315 bytes
Rounded rectangle with non anti-aliased edges


Page contents: When to use antialiasing and when to avoid it? Learn the oproper usage of anti-aliasing feature to create optimized images for the web.

AddThis Social Bookmark Button