Image conversion guides

Compare two icon sizes before choosing the SVG

·

An icon file can carry artwork tailored to different display sizes. In the two-size beacon, the large entry has orange artwork and a translucent halo. The small entry uses a green mark with a one-pixel highlight.

ICO to SVG

Compare entry 2 with the smaller entry 1

Select Load example or open two-size-beacon.ico. The picker starts at Entry 2, the 32 × 32 PNG. Convert to SVG to see the orange beacon and translucent blue halo. Save two-size-beacon-entry-02.svg.

Change the picker to Entry 1, the 16 × 16 bitmap. Convert again. It has a green block, yellow marker and small white highlight. The background is transparent, and the small artwork comes from a separate entry.

Download the original two-size beacon ICOMicrosoft — Icon resource directory, bitmap masks and PNG entries

Check that each file matches its entry size

Open the 16-pixel result as text. The viewBox is 0 0 16 16 and the SVG contains one PNG image element. The saved 32-pixel version has a 32 × 32 viewport.

Place both SVGs on a colored background. The large icon’s blue halo lets the background show through partially. The smaller icon has hard transparent edges from a bitmap mask.

Microsoft — Icon resource directory, bitmap masks and PNG entriesW3C SVG 2 — Embedded image

Choose the artwork intended for your layout

Choose the entry close to the displayed size when the file has separate artwork for smaller placements. The filename records which directory entry you chose.

A ZIP contains one selected entry per input file. To keep two sizes from the same icon, save one conversion before switching the picker.

Common questions

What does DIB mean in the picker?

It is a bitmap stored in an ICO entry. The decoder reads its pixel data and supported transparency mask before creating the PNG in the SVG.

Why do two sizes have different shapes?

The ICO directory points to separate images. An icon designer can change shapes and detail to keep both sizes readable.

Sources

Put it into practice.

Related guides