/external/libpng/ |
D | pngwtran.c | 25 png_do_pack(png_row_infop row_info, png_bytep row, png_uint_32 bit_depth) in png_do_pack() argument 29 if (row_info->bit_depth == 8 && in png_do_pack() 32 switch ((int)bit_depth) in png_do_pack() 153 row_info->bit_depth = (png_byte)bit_depth; in png_do_pack() 154 row_info->pixel_depth = (png_byte)(bit_depth * row_info->channels); in png_do_pack() 171 png_const_color_8p bit_depth) in png_do_shift() argument 182 shift_start[channels] = row_info->bit_depth - bit_depth->red; in png_do_shift() 183 shift_dec[channels] = bit_depth->red; in png_do_shift() 186 shift_start[channels] = row_info->bit_depth - bit_depth->green; in png_do_shift() 187 shift_dec[channels] = bit_depth->green; in png_do_shift() [all …]
|
D | pngtrans.c | 42 if (png_ptr->bit_depth == 16) in png_set_swap() 57 if (png_ptr->bit_depth < 8) in png_set_packing() 77 if (png_ptr->bit_depth < 8) in png_set_packswap() 162 if (png_ptr->bit_depth >= 8) in png_set_filler() 282 row_info->bit_depth == 8) in png_do_invert() 297 row_info->bit_depth == 16) in png_do_invert() 322 if (row_info->bit_depth == 16) in png_do_swap() 451 if (row_info->bit_depth < 8) in png_do_packswap() 458 if (row_info->bit_depth == 1) in png_do_packswap() 461 else if (row_info->bit_depth == 2) in png_do_packswap() [all …]
|
D | pngrtran.c | 1233 switch (png_ptr->bit_depth) in png_init_rgb_transformations() 1487 png_ptr->bit_depth != 16) in png_init_read_transformations() 1514 png_ptr->bit_depth == 16) in png_init_read_transformations() 1572 png_build_gamma_table(png_ptr, png_ptr->bit_depth); in png_init_read_transformations() 1943 info_ptr->bit_depth = 8; in png_read_transform_info() 1956 if (info_ptr->bit_depth < 8) in png_read_transform_info() 1957 info_ptr->bit_depth = 8; in png_read_transform_info() 1986 if (info_ptr->bit_depth == 16) in png_read_transform_info() 1991 info_ptr->bit_depth = 8; in png_read_transform_info() 1996 info_ptr->bit_depth = 8; in png_read_transform_info() [all …]
|
/external/libpng/contrib/examples/ |
D | pngpixel.c | 33 unsigned int bit_depth, unsigned int channels) in component() argument 40 png_uint_32 bit_offset_hi = bit_depth * ((x >> 6) * channels); in component() 41 png_uint_32 bit_offset_lo = bit_depth * ((x & 0x3f) * channels + c); in component() 51 switch (bit_depth) in component() 62 fprintf(stderr, "pngpixel: invalid bit depth %u\n", bit_depth); in component() 74 PNG_CONST unsigned int bit_depth = png_get_bit_depth(png_ptr, info_ptr); in print_pixel() local 79 printf("GRAY %u\n", component(row, x, 0, bit_depth, 1)); in print_pixel() 88 PNG_CONST unsigned int index = component(row, x, 0, bit_depth, 1); in print_pixel() 117 printf("RGB %u %u %u\n", component(row, x, 0, bit_depth, 3), in print_pixel() 118 component(row, x, 1, bit_depth, 3), in print_pixel() [all …]
|
/external/chromium_org/third_party/libpng/ |
D | pngwtran.c | 57 (png_uint_32)png_ptr->bit_depth); in png_do_write_transformations() 92 png_do_pack(png_row_infop row_info, png_bytep row, png_uint_32 bit_depth) in png_do_pack() argument 96 if (row_info->bit_depth == 8 && in png_do_pack() 102 switch ((int)bit_depth) in png_do_pack() 202 row_info->bit_depth = (png_byte)bit_depth; in png_do_pack() 203 row_info->pixel_depth = (png_byte)(bit_depth * row_info->channels); in png_do_pack() 219 png_do_shift(png_row_infop row_info, png_bytep row, png_color_8p bit_depth) in png_do_shift() argument 235 shift_start[channels] = row_info->bit_depth - bit_depth->red; in png_do_shift() 236 shift_dec[channels] = bit_depth->red; in png_do_shift() 238 shift_start[channels] = row_info->bit_depth - bit_depth->green; in png_do_shift() [all …]
|
D | pngtrans.c | 41 if (png_ptr->bit_depth == 16) in png_set_swap() 55 if (png_ptr->bit_depth < 8) in png_set_packing() 72 if (png_ptr->bit_depth < 8) in png_set_packswap() 144 if (png_ptr->color_type == PNG_COLOR_TYPE_GRAY && png_ptr->bit_depth >= 8) in png_set_filler() 229 row_info->bit_depth == 8) in png_do_invert() 242 row_info->bit_depth == 16) in png_do_invert() 269 row_info->bit_depth == 16) in png_do_swap() 401 row_info->bit_depth < 8) in png_do_packswap() 407 if (row_info->bit_depth == 1) in png_do_packswap() 409 else if (row_info->bit_depth == 2) in png_do_packswap() [all …]
|
D | pngrtran.c | 829 switch (png_ptr->bit_depth) in png_init_read_transformations() 1046 double m = (double)(((png_uint_32)1 << png_ptr->bit_depth) - 1); in png_init_read_transformations() 1214 info_ptr->bit_depth = 8; in png_read_transform_info() 1224 if (info_ptr->bit_depth < 8) in png_read_transform_info() 1225 info_ptr->bit_depth = 8; in png_read_transform_info() 1253 if ((png_ptr->transformations & PNG_16_TO_8) && (info_ptr->bit_depth == 16)) in png_read_transform_info() 1254 info_ptr->bit_depth = 8; in png_read_transform_info() 1272 png_ptr->palette_lookup && info_ptr->bit_depth == 8) in png_read_transform_info() 1280 if ((png_ptr->transformations & PNG_PACK) && (info_ptr->bit_depth < 8)) in png_read_transform_info() 1281 info_ptr->bit_depth = 8; in png_read_transform_info() [all …]
|
/external/qemu/distrib/libpng-1.2.46/ |
D | pngwtran.c | 57 (png_uint_32)png_ptr->bit_depth); in png_do_write_transformations() 92 png_do_pack(png_row_infop row_info, png_bytep row, png_uint_32 bit_depth) in png_do_pack() argument 96 if (row_info->bit_depth == 8 && in png_do_pack() 102 switch ((int)bit_depth) in png_do_pack() 202 row_info->bit_depth = (png_byte)bit_depth; in png_do_pack() 203 row_info->pixel_depth = (png_byte)(bit_depth * row_info->channels); in png_do_pack() 219 png_do_shift(png_row_infop row_info, png_bytep row, png_color_8p bit_depth) in png_do_shift() argument 235 shift_start[channels] = row_info->bit_depth - bit_depth->red; in png_do_shift() 236 shift_dec[channels] = bit_depth->red; in png_do_shift() 238 shift_start[channels] = row_info->bit_depth - bit_depth->green; in png_do_shift() [all …]
|
D | pngtrans.c | 41 if (png_ptr->bit_depth == 16) in png_set_swap() 55 if (png_ptr->bit_depth < 8) in png_set_packing() 72 if (png_ptr->bit_depth < 8) in png_set_packswap() 144 if (png_ptr->color_type == PNG_COLOR_TYPE_GRAY && png_ptr->bit_depth >= 8) in png_set_filler() 229 row_info->bit_depth == 8) in png_do_invert() 242 row_info->bit_depth == 16) in png_do_invert() 269 row_info->bit_depth == 16) in png_do_swap() 401 row_info->bit_depth < 8) in png_do_packswap() 407 if (row_info->bit_depth == 1) in png_do_packswap() 409 else if (row_info->bit_depth == 2) in png_do_packswap() [all …]
|
D | pngrtran.c | 829 switch (png_ptr->bit_depth) in png_init_read_transformations() 1046 double m = (double)(((png_uint_32)1 << png_ptr->bit_depth) - 1); in png_init_read_transformations() 1214 info_ptr->bit_depth = 8; in png_read_transform_info() 1224 if (info_ptr->bit_depth < 8) in png_read_transform_info() 1225 info_ptr->bit_depth = 8; in png_read_transform_info() 1253 if ((png_ptr->transformations & PNG_16_TO_8) && (info_ptr->bit_depth == 16)) in png_read_transform_info() 1254 info_ptr->bit_depth = 8; in png_read_transform_info() 1272 png_ptr->palette_lookup && info_ptr->bit_depth == 8) in png_read_transform_info() 1280 if ((png_ptr->transformations & PNG_PACK) && (info_ptr->bit_depth < 8)) in png_read_transform_info() 1281 info_ptr->bit_depth = 8; in png_read_transform_info() [all …]
|
/external/libpng/contrib/libtests/ |
D | makepng.c | 132 pixel_depth_of_type(int color_type, int bit_depth) in pixel_depth_of_type() argument 134 return channels_of_type(color_type) * bit_depth; in pixel_depth_of_type() 138 image_size_of_type(int color_type, int bit_depth, unsigned int *colors) in image_size_of_type() argument 145 int pixel_depth = pixel_depth_of_type(color_type, bit_depth); in image_size_of_type() 170 generate_palette(png_colorp palette, png_bytep trans, int bit_depth, in generate_palette() argument 210 if (bit_depth == 1) in generate_palette() 219 unsigned int size = 1U << (bit_depth/2); /* 2, 4 or 16 */ in generate_palette() 249 set_value(png_bytep row, size_t rowbytes, png_uint_32 x, unsigned int bit_depth, in set_value() argument 252 unsigned int mask = (1U << bit_depth)-1; in set_value() 254 x *= bit_depth; /* Maximum x is 4*1024, maximum bit_depth is 16 */ in set_value() [all …]
|
D | pngvalid.c | 297 int bit_depth, unsigned int npalette, int interlace_type, in standard_name() argument 308 pos = safecatn(buffer, bufsize, pos, bit_depth); in standard_name() 359 #define PALETTE_COUNT(bit_depth) ((bit_depth) > 4 ? 1U : 16U) argument 362 next_format(png_bytep colour_type, png_bytep bit_depth, in next_format() argument 365 if (*bit_depth == 0) in next_format() 369 *bit_depth = 8; in next_format() 371 *bit_depth = 1; in next_format() 379 if (++*palette_number < PALETTE_COUNT(*bit_depth)) in next_format() 385 *bit_depth = (png_byte)(*bit_depth << 1); in next_format() 388 if (*bit_depth <= 8 in next_format() [all …]
|
/external/libhevc/common/ |
D | ihevc_iquant_recon.c | 125 WORD32 log2_trans_size, bit_depth; in ihevc_iquant_recon_4x4_ttype1() local 128 bit_depth = 8 + 0; in ihevc_iquant_recon_4x4_ttype1() 129 shift_iq = bit_depth + log2_trans_size - 5; in ihevc_iquant_recon_4x4_ttype1() 237 WORD32 log2_trans_size, bit_depth; in ihevc_iquant_recon_4x4() local 240 bit_depth = 8 + 0; in ihevc_iquant_recon_4x4() 241 shift_iq = bit_depth + log2_trans_size - 5; in ihevc_iquant_recon_4x4() 348 WORD32 log2_trans_size, bit_depth; in ihevc_iquant_recon_8x8() local 351 bit_depth = 8 + 0; in ihevc_iquant_recon_8x8() 352 shift_iq = bit_depth + log2_trans_size - 5; in ihevc_iquant_recon_8x8() 460 WORD32 log2_trans_size, bit_depth; in ihevc_iquant_recon_16x16() local [all …]
|
D | ihevc_trans_macros.h | 41 …WORD32 bit_depth,transform_shift; … 46 …bit_depth = 8; … 47 …transform_shift = MAX_TR_DYNAMIC_RANGE - bit_depth - log2_trans_size; … 62 #define QUANT_HBD(out, inp, quant_coeff, qp_div, log2_trans_size, q_add, bit_depth) \ argument 72 …transform_shift = MAX_TR_DYNAMIC_RANGE - bit_depth - log2_trans_size; … 91 …WORD32 bit_depth,transform_shift; … 96 …bit_depth = 8; … 97 …transform_shift = MAX_TR_DYNAMIC_RANGE - bit_depth - log2_trans_size; … 112 #define QUANT_NO_WEIGHTMAT_HBD(out, inp, quant_coeff, qp_div, log2_trans_size, q_add, bit_depth) \ argument 122 …transform_shift = MAX_TR_DYNAMIC_RANGE - bit_depth - log2_trans_size; …
|
D | ihevc_chroma_iquant_recon.c | 131 WORD32 log2_trans_size, bit_depth; in ihevc_chroma_iquant_recon_4x4() local 134 bit_depth = 8 + 0; in ihevc_chroma_iquant_recon_4x4() 135 shift_iq = bit_depth + log2_trans_size - 5; in ihevc_chroma_iquant_recon_4x4() 243 WORD32 log2_trans_size, bit_depth; in ihevc_chroma_iquant_recon_8x8() local 246 bit_depth = 8 + 0; in ihevc_chroma_iquant_recon_8x8() 247 shift_iq = bit_depth + log2_trans_size - 5; in ihevc_chroma_iquant_recon_8x8() 356 WORD32 log2_trans_size, bit_depth; in ihevc_chroma_iquant_recon_16x16() local 359 bit_depth = 8 + 0; in ihevc_chroma_iquant_recon_16x16() 360 shift_iq = bit_depth + log2_trans_size - 5; in ihevc_chroma_iquant_recon_16x16()
|
D | ihevc_intra_pred.h | 169 UWORD8 bit_depth); 179 UWORD8 bit_depth); 189 UWORD8 bit_depth); 199 UWORD8 bit_depth); 209 UWORD8 bit_depth); 219 UWORD8 bit_depth); 229 UWORD8 bit_depth); 239 UWORD8 bit_depth); 248 UWORD8 bit_depth); 259 UWORD8 bit_depth); [all …]
|
D | ihevc_sao.c | 202 WORD32 bit_depth; in ihevc_sao_edge_offset_class0() local 205 bit_depth = BIT_DEPTH_LUMA; in ihevc_sao_edge_offset_class0() 248 … pu1_src[col] = CLIP3(pu1_src[col] + pi1_sao_offset[edge_idx], 0, (1 << bit_depth) - 1); in ihevc_sao_edge_offset_class0() 286 WORD32 bit_depth; in ihevc_sao_edge_offset_class0_chroma() local 289 bit_depth = BIT_DEPTH_CHROMA; in ihevc_sao_edge_offset_class0_chroma() 347 … pu1_src[col] = CLIP3(pu1_src[col] + pi1_sao_offset[edge_idx], 0, (1 << bit_depth) - 1); in ihevc_sao_edge_offset_class0_chroma() 382 WORD32 bit_depth; in ihevc_sao_edge_offset_class1() local 386 bit_depth = BIT_DEPTH_LUMA; in ihevc_sao_edge_offset_class1() 440 … pu1_src[col] = CLIP3(pu1_src[col] + pi1_sao_offset[edge_idx], 0, (1 << bit_depth) - 1); in ihevc_sao_edge_offset_class1() 476 WORD32 bit_depth; in ihevc_sao_edge_offset_class1_chroma() local [all …]
|
D | ihevc_recon.h | 51 UWORD8 bit_depth); 66 UWORD8 bit_depth); 81 UWORD8 bit_depth); 96 UWORD8 bit_depth); 111 UWORD8 bit_depth);
|
D | ihevc_inter_pred.h | 97 UWORD8 bit_depth); 108 UWORD8 bit_depth); 119 UWORD8 bit_depth); 130 UWORD8 bit_depth); 143 UWORD8 bit_depth); 162 UWORD8 bit_depth); 176 UWORD8 bit_depth); 189 UWORD8 bit_depth); 210 UWORD8 bit_depth); 222 UWORD8 bit_depth);
|
D | ihevc_deblk_edge_filter.c | 348 UWORD8 bit_depth) in ihevc_hbd_deblk_luma_vert() argument 372 beta = gai4_ihevc_beta_table[beta_indx] * (1 << (bit_depth - 8)); in ihevc_hbd_deblk_luma_vert() 373 tc = gai4_ihevc_tc_table[tc_indx] * (1 << (bit_depth - 8)); in ihevc_hbd_deblk_luma_vert() 486 tmp_p0 = CLIP3(pu2_src[-1] + delta, 0, ((1 << bit_depth) - 1)); in ihevc_hbd_deblk_luma_vert() 487 tmp_q0 = CLIP3(pu2_src[0] - delta, 0, ((1 << bit_depth) - 1)); in ihevc_hbd_deblk_luma_vert() 494 tmp_p1 = CLIP3(pu2_src[-2] + delta_p, 0, ((1 << bit_depth) - 1)); in ihevc_hbd_deblk_luma_vert() 503 tmp_q1 = CLIP3(pu2_src[1] + delta_q, 0, ((1 << bit_depth) - 1)); in ihevc_hbd_deblk_luma_vert() 847 UWORD8 bit_depth) in ihevc_hbd_deblk_luma_horz() argument 871 beta = gai4_ihevc_beta_table[beta_indx] * (1 << (bit_depth - 8)); in ihevc_hbd_deblk_luma_horz() 872 tc = gai4_ihevc_tc_table[tc_indx] * (1 << (bit_depth - 8)); in ihevc_hbd_deblk_luma_horz() [all …]
|
D | ihevc_iquant_recon.h | 57 UWORD8 bit_depth); 78 UWORD8 bit_depth); 99 UWORD8 bit_depth); 120 UWORD8 bit_depth); 141 UWORD8 bit_depth);
|
/external/libpng/contrib/pngminus/ |
D | pnm2png.c | 207 int bit_depth = 0; in pnm2png() local 237 bit_depth = 1; in pnm2png() 259 bit_depth = 1; in pnm2png() 261 bit_depth = 2; in pnm2png() 263 bit_depth = 4; in pnm2png() 265 bit_depth = 8; in pnm2png() 267 bit_depth = 16; in pnm2png() 283 bit_depth = 1; in pnm2png() 285 bit_depth = 2; in pnm2png() 287 bit_depth = 4; in pnm2png() [all …]
|
D | png2pnm.c | 201 int bit_depth; in png2pnm() local 248 &width, &height, &bit_depth, &color_type, in png2pnm() 257 if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) in png2pnm() 265 if (bit_depth == 16) in png2pnm() 282 png_get_IHDR (png_ptr, info_ptr, &width, &height, &bit_depth, &color_type, in png2pnm() 286 if (bit_depth == 16) in png2pnm() 351 fprintf (pnm_file, "%ld\n", ((1L << (int) bit_depth) - 1L)); in png2pnm() 358 fprintf (pnm_file, "%ld\n", ((1L << (int) bit_depth) - 1L)); in png2pnm() 369 fprintf (alpha_file, "%ld\n", ((1L << (int) bit_depth) - 1L)); in png2pnm() 384 if (bit_depth == 16){ in png2pnm() [all …]
|
/external/libpng/contrib/gregbook/ |
D | readpng.c | 73 int bit_depth, color_type; variable 138 png_get_IHDR(png_ptr, info_ptr, &width, &height, &bit_depth, &color_type, in readpng_init() 182 if (bit_depth == 16) { in readpng_get_bgcolor() 186 } else if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) { in readpng_get_bgcolor() 187 if (bit_depth == 1) in readpng_get_bgcolor() 189 else if (bit_depth == 2) in readpng_get_bgcolor() 233 if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) in readpng_get_image() 238 if (bit_depth == 16) in readpng_get_image()
|
D | readpng2.c | 214 int color_type, bit_depth; in readpng2_info_callback() local 255 png_get_IHDR(png_ptr, info_ptr, &width, &height, &bit_depth, &color_type, in readpng2_info_callback() 276 if (bit_depth == 16) { in readpng2_info_callback() 280 } else if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) { in readpng2_info_callback() 281 if (bit_depth == 1) in readpng2_info_callback() 284 else if (bit_depth == 2) in readpng2_info_callback() 305 if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) in readpng2_info_callback() 310 if (bit_depth == 16) in readpng2_info_callback()
|