Lines Matching refs:transformations

137    png_ptr->transformations |= PNG_COMPOSE | PNG_STRIP_ALPHA;
138 png_ptr->transformations &= ~PNG_ENCODE_ALPHA;
146 png_ptr->transformations |= PNG_BACKGROUND_EXPAND;
148 png_ptr->transformations &= ~PNG_BACKGROUND_EXPAND;
176 png_ptr->transformations |= PNG_SCALE_16_TO_8;
190 png_ptr->transformations |= PNG_16_TO_8;
203 png_ptr->transformations |= PNG_STRIP_ALPHA;
318 png_ptr->transformations &= ~PNG_ENCODE_ALPHA;
324 png_ptr->transformations &= ~PNG_ENCODE_ALPHA;
332 png_ptr->transformations &= ~PNG_ENCODE_ALPHA;
339 png_ptr->transformations |= PNG_ENCODE_ALPHA;
366 png_ptr->transformations &= ~PNG_BACKGROUND_EXPAND;
368 if (png_ptr->transformations & PNG_COMPOSE)
372 png_ptr->transformations |= PNG_COMPOSE;
418 png_ptr->transformations |= PNG_QUANTIZE;
858 png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS);
868 * IOW, a future version of the library may make the transformations flag
889 png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS);
902 png_ptr->transformations |= PNG_EXPAND;
914 png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS);
931 png_ptr->transformations |= (PNG_EXPAND_16 | PNG_EXPAND | PNG_EXPAND_tRNS);
949 png_ptr->transformations |= PNG_GRAY_TO_RGB;
968 png_ptr->transformations |= PNG_RGB_TO_GRAY;
972 png_ptr->transformations |= PNG_RGB_TO_GRAY_WARN;
976 png_ptr->transformations |= PNG_RGB_TO_GRAY_ERR;
985 png_ptr->transformations |= PNG_EXPAND;
991 png_ptr->transformations &= ~PNG_RGB_TO_GRAY;
1062 png_ptr->transformations |= PNG_USER_TRANSFORM;
1070 /* In the case of gamma transformations only do transformations on images where
1134 png_ptr->transformations &= ~PNG_ENCODE_ALPHA;
1138 png_ptr->transformations &= ~(PNG_COMPOSE | PNG_BACKGROUND_EXPAND);
1150 if ((png_ptr->transformations & PNG_BACKGROUND_EXPAND) &&
1151 (png_ptr->transformations & PNG_EXPAND))
1162 if (png_ptr->transformations & PNG_INVERT_ALPHA)
1164 if (!(png_ptr->transformations & PNG_EXPAND_tRNS))
1200 png_ptr->transformations &= ~PNG_ENCODE_ALPHA;
1205 png_ptr->transformations &= ~(PNG_COMPOSE | PNG_BACKGROUND_EXPAND);
1217 if ((png_ptr->transformations & PNG_BACKGROUND_EXPAND) &&
1218 (png_ptr->transformations & PNG_EXPAND) &&
1230 if (!(png_ptr->transformations & PNG_EXPAND_tRNS))
1242 if (!(png_ptr->transformations & PNG_EXPAND_tRNS))
1254 if (!(png_ptr->transformations & PNG_EXPAND_tRNS))
1283 * in here can change or update the transformations flags.
1340 png_ptr->transformations |= PNG_GAMMA;
1343 png_ptr->transformations &= ~PNG_GAMMA;
1347 /* Certain transformations have the effect of preventing other
1348 * transformations that happen afterward in png_do_read_transformations,
1377 if ((png_ptr->transformations & PNG_STRIP_ALPHA) &&
1378 !(png_ptr->transformations & PNG_COMPOSE))
1381 * transformations, before all other transformation, so it cancels out
1385 png_ptr->transformations &= ~(PNG_BACKGROUND_EXPAND | PNG_ENCODE_ALPHA |
1406 png_ptr->transformations &= ~PNG_ENCODE_ALPHA;
1429 if (png_ptr->transformations & PNG_BACKGROUND_EXPAND)
1438 else if (png_ptr->transformations & PNG_COMPOSE)
1445 if (png_ptr->transformations & PNG_GRAY_TO_RGB)
1457 /* For indexed PNG data (PNG_COLOR_TYPE_PALETTE) many of the transformations
1476 if ((png_ptr->transformations & PNG_EXPAND_16) &&
1477 (png_ptr->transformations & PNG_COMPOSE) &&
1478 !(png_ptr->transformations & PNG_BACKGROUND_EXPAND) &&
1527 if ((png_ptr->transformations & PNG_GAMMA)
1528 || ((png_ptr->transformations & PNG_RGB_TO_GRAY)
1531 || ((png_ptr->transformations & PNG_COMPOSE)
1538 )) || ((png_ptr->transformations & PNG_ENCODE_ALPHA)
1545 if (png_ptr->transformations & PNG_COMPOSE)
1664 /* Prevent the transformations being done again.
1666 * NOTE: this is highly dubious; it zaps the transformations in
1668 * transformations elsewhere.
1670 png_ptr->transformations &= ~(PNG_COMPOSE | PNG_GAMMA);
1741 }/* png_ptr->transformations & PNG_BACKGROUND */
1752 /*NOTE: there are other transformations that should probably be in here
1763 png_ptr->transformations &= ~PNG_GAMMA;
1773 if ((png_ptr->transformations & PNG_COMPOSE) &&
1806 png_ptr->transformations &= ~PNG_COMPOSE;
1811 if ((png_ptr->transformations & PNG_SHIFT) &&
1839 /* Modify the info structure to reflect the transformations. The
1841 * assuming the transformations result in valid PNG data.
1849 if (png_ptr->transformations & PNG_EXPAND)
1870 if (png_ptr->transformations & PNG_EXPAND_tRNS)
1886 if (png_ptr->transformations & PNG_COMPOSE)
1903 if (png_ptr->transformations & PNG_SCALE_16_TO_8)
1908 if (png_ptr->transformations & PNG_16_TO_8)
1922 png_ptr->transformations |= PNG_16_TO_8;
1927 png_ptr->transformations |= PNG_SCALE_16_TO_8;
1938 if (png_ptr->transformations & PNG_GRAY_TO_RGB)
1943 if (png_ptr->transformations & PNG_RGB_TO_GRAY)
1948 if (png_ptr->transformations & PNG_QUANTIZE)
1960 if (png_ptr->transformations & PNG_EXPAND_16 && info_ptr->bit_depth == 8 &&
1968 if ((png_ptr->transformations & PNG_PACK) && (info_ptr->bit_depth < 8))
1982 if (png_ptr->transformations & PNG_STRIP_ALPHA)
1994 if ((png_ptr->transformations & PNG_FILLER) &&
2000 if (png_ptr->transformations & PNG_ADD_ALPHA)
2007 if (png_ptr->transformations & PNG_USER_TRANSFORM)
2036 /* Transform the row. The order of transformations is significant,
2038 * decide how it fits in with the other transformations here.
2070 if (png_ptr->transformations & PNG_EXPAND)
2081 (png_ptr->transformations & PNG_EXPAND_tRNS))
2093 if ((png_ptr->transformations & PNG_STRIP_ALPHA) &&
2094 !(png_ptr->transformations & PNG_COMPOSE) &&
2102 if (png_ptr->transformations & PNG_RGB_TO_GRAY)
2111 if ((png_ptr->transformations & PNG_RGB_TO_GRAY) ==
2115 if ((png_ptr->transformations & PNG_RGB_TO_GRAY) ==
2157 if ((png_ptr->transformations & PNG_GRAY_TO_RGB) &&
2164 if (png_ptr->transformations & PNG_COMPOSE)
2169 if ((png_ptr->transformations & PNG_GAMMA) &&
2172 !((png_ptr->transformations & PNG_COMPOSE) &&
2181 if ((png_ptr->transformations & PNG_STRIP_ALPHA) &&
2182 (png_ptr->transformations & PNG_COMPOSE) &&
2190 if ((png_ptr->transformations & PNG_ENCODE_ALPHA) &&
2196 if (png_ptr->transformations & PNG_SCALE_16_TO_8)
2205 if (png_ptr->transformations & PNG_16_TO_8)
2210 if (png_ptr->transformations & PNG_QUANTIZE)
2222 * that previous transformations can handle the PNG_EXPAND_16 flag if this
2226 if (png_ptr->transformations & PNG_EXPAND_16)
2232 if ((png_ptr->transformations & PNG_GRAY_TO_RGB) &&
2238 if (png_ptr->transformations & PNG_INVERT_MONO)
2243 if (png_ptr->transformations & PNG_SHIFT)
2249 if (png_ptr->transformations & PNG_PACK)
2254 if (png_ptr->transformations & PNG_BGR)
2259 if (png_ptr->transformations & PNG_PACKSWAP)
2264 if (png_ptr->transformations & PNG_FILLER)
2270 if (png_ptr->transformations & PNG_INVERT_ALPHA)
2275 if (png_ptr->transformations & PNG_SWAP_ALPHA)
2281 if (png_ptr->transformations & PNG_SWAP_BYTES)
2287 if (png_ptr->transformations & PNG_USER_TRANSFORM)