Lines Matching defs:background

294 /* Initialize palette, background, etc, after transformations
1219 * the background (not recommended).
1260 /* We don't handle background color or gamma transformation or quantizing.
1341 /* Optional call to gamma correct and add the background to the palette
1398 #define PNG_CMAP_TRANS 2 /* Process GA data to a background index */
1402 /* The following document where the background is for each processing case. */
1416 png_const_colorp background;
1850 png_uint_32 background, int encoding)
1852 /* The file value is composed on the background, the background has the given
1858 png_uint_32 b = decode_gamma(display, background, encoding);
2224 /* Background information; the background color and the index of this color
2245 else if (display->background == NULL /* no way to remove it */)
2247 "a background color must be supplied to remove alpha/transparency");
2249 /* Get a copy of the background color (this avoids repeating the checks
2255 back_g = display->background->green;
2258 back_r = display->background->red;
2259 back_b = display->background->blue;
2317 * value or, if the output has no alpha, the background color.
2350 * supplied background color when it is used.
2382 * If the output has no alpha channel *and* the background color is
2384 * ensuring that the corresponding gray level matches the background
2422 /* The background passed to libpng, however, must be the
2446 * transparent entry or by the background color at full
2447 * precision (and the background color is not a simple gray leve
2455 * background color at full precision.
2469 * removed there are only 256 possibilities if the background is gray.
2471 * the triangle between black, white and the background color.)
2493 * background is a color because the G and A channels are
2499 * background entry (for a transparent pixel) and a set of four six
2504 * If the background is gray, however, we only need a 256 entry gray
2506 * for the background color be exactly the color specified.
2529 /* The background passed to libpng, however, must be the sRGB
2561 * background color.
2567 /* For non-opaque input composite on the sRGB background - this
2573 * 'A' is linear. We need the linear background colors.
2578 * background, but that's ok because these numbers are only
2627 * transparent color in background color handling; call
2641 /* Both input and output have an alpha channel, so no background
2691 /* We need to ensure that the application background exists in
2694 * selected for the background really is the background color.
2726 /* The background passed to libpng, however, must be the
2775 /* This is stored as the background index for the processing
2804 /* Alpha/transparency must be removed. The background must
2808 * required; libpng can be called to do the background
2813 png_uint_32 r, g, b; /* sRGB background */
2839 * match, add the new one and set this as the background
2848 /* The background color must be added. */
2852 * the background at alpha 0.5.
2877 else /* background color is in the standard color-map */
3007 /* Double check using the recorded background index */
3040 png_error(png_ptr, "bad background index (internal error)");
3510 * libpng doing rgb to gray and gamma correction but background processing
3555 * to be removed by composing on a background: either the row if
3556 * display->background is NULL or display->background->green if not.
3589 if (display->background == NULL)
3631 else /* constant background value */
3633 png_byte background8 = display->background->green;
3634 png_uint_16 background = png_sRGB_table[background8];
3652 if (alpha > 0) /* else use background */
3659 component += background * (255-alpha);
3814 * background/pre-multiplication if there is also significant gamma
3817 * Handle this by doing the pre-multiplication or background
3913 /* Now the background/alpha channel changes. */
3935 else if (display->background != NULL)
3940 c.red = display->background->red;
3941 c.green = display->background->green;
3942 c.blue = display->background->blue;
3943 c.gray = display->background->green;
4034 /* Disable this if doing a local background,
4035 * TODO: remove this when local background is no longer required.
4202 png_image_finish_read(png_imagep image, png_const_colorp background,
4232 display.background = background;