++ed by:

32 PAUSE users
18 non-PAUSE users.

Tony Cook
i_quant_makemap(quant, imgs, count)

Analyzes the count images in imgs according to the rules in quant to build a color map (optimal or not depending on quant->make_colors).

i_quant_translate(quant, img)

Quantize the image given the palette in quant.

On success returns a pointer to a memory block of img->xsize * img->ysize i_palidx entries.

On failure returns NULL.

You should call myfree() on the returned block when you're done with it.

This function will fail if the supplied palette contains no colors.

calc_part(part, colors)

Calculates the new color limits for the given partition.

Giflib assumes that the limits for the non-split channels stay the same, but this strikes me as incorrect, especially if the colors tend to be color ramps.

Of course this could be optimized by not recalculating the channel we just sorted on, but it's not worth the effort right now.

makemap_palette(quant, imgs, count)

Tests if all the given images are paletted and have a common palette, if they do it builds that palette.

A possible improvement might be to eliminate unused colors in the images palettes.

i_quant_transparent(quant, data, img, trans_index)

Dither the alpha channel on img into the palette indexes in data. Pixels to be transparent are replaced with trans_pixel.

The method used depends on the tr_* members of quant.

4 POD Errors

The following errors were encountered while parsing the POD:

Around line 36:

'=item' outside of any '=over'

=over without closing =back

Around line 38:

Unknown directive: =category

Around line 102:

Unknown directive: =category

Around line 1657:

Unknown directive: =category