• Home
  • Raw
  • Download

Lines Matching refs:png_ptr

21 png_set_bgr(png_structrp png_ptr)  in png_set_bgr()  argument
25 if (png_ptr == NULL) in png_set_bgr()
28 png_ptr->transformations |= PNG_BGR; in png_set_bgr()
35 png_set_swap(png_structrp png_ptr) in png_set_swap() argument
39 if (png_ptr == NULL) in png_set_swap()
42 if (png_ptr->bit_depth == 16) in png_set_swap()
43 png_ptr->transformations |= PNG_SWAP_BYTES; in png_set_swap()
50 png_set_packing(png_structrp png_ptr) in png_set_packing() argument
54 if (png_ptr == NULL) in png_set_packing()
57 if (png_ptr->bit_depth < 8) in png_set_packing()
59 png_ptr->transformations |= PNG_PACK; in png_set_packing()
61 png_ptr->usr_bit_depth = 8; in png_set_packing()
70 png_set_packswap(png_structrp png_ptr) in png_set_packswap() argument
74 if (png_ptr == NULL) in png_set_packswap()
77 if (png_ptr->bit_depth < 8) in png_set_packswap()
78 png_ptr->transformations |= PNG_PACKSWAP; in png_set_packswap()
84 png_set_shift(png_structrp png_ptr, png_const_color_8p true_bits) in png_set_shift() argument
88 if (png_ptr == NULL) in png_set_shift()
91 png_ptr->transformations |= PNG_SHIFT; in png_set_shift()
92 png_ptr->shift = *true_bits; in png_set_shift()
99 png_set_interlace_handling(png_structrp png_ptr) in png_set_interlace_handling() argument
103 if (png_ptr != 0 && png_ptr->interlaced != 0) in png_set_interlace_handling()
105 png_ptr->transformations |= PNG_INTERLACE; in png_set_interlace_handling()
120 png_set_filler(png_structrp png_ptr, png_uint_32 filler, int filler_loc) in png_set_filler() argument
124 if (png_ptr == NULL) in png_set_filler()
130 if ((png_ptr->mode & PNG_IS_READ_STRUCT) != 0) in png_set_filler()
141 png_ptr->filler = (png_uint_16)filler; in png_set_filler()
143 png_app_error(png_ptr, "png_set_filler not supported on read"); in png_set_filler()
155 switch (png_ptr->color_type) in png_set_filler()
158 png_ptr->usr_channels = 4; in png_set_filler()
162 if (png_ptr->bit_depth >= 8) in png_set_filler()
164 png_ptr->usr_channels = 2; in png_set_filler()
174 png_app_error(png_ptr, in png_set_filler()
181 png_app_error(png_ptr, in png_set_filler()
186 png_app_error(png_ptr, "png_set_filler not supported on write"); in png_set_filler()
194 png_ptr->transformations |= PNG_FILLER; in png_set_filler()
197 png_ptr->flags |= PNG_FLAG_FILLER_AFTER; in png_set_filler()
200 png_ptr->flags &= ~PNG_FLAG_FILLER_AFTER; in png_set_filler()
205 png_set_add_alpha(png_structrp png_ptr, png_uint_32 filler, int filler_loc) in png_set_add_alpha() argument
209 if (png_ptr == NULL) in png_set_add_alpha()
212 png_set_filler(png_ptr, filler, filler_loc); in png_set_add_alpha()
214 if ((png_ptr->transformations & PNG_FILLER) != 0) in png_set_add_alpha()
215 png_ptr->transformations |= PNG_ADD_ALPHA; in png_set_add_alpha()
223 png_set_swap_alpha(png_structrp png_ptr) in png_set_swap_alpha() argument
227 if (png_ptr == NULL) in png_set_swap_alpha()
230 png_ptr->transformations |= PNG_SWAP_ALPHA; in png_set_swap_alpha()
237 png_set_invert_alpha(png_structrp png_ptr) in png_set_invert_alpha() argument
241 if (png_ptr == NULL) in png_set_invert_alpha()
244 png_ptr->transformations |= PNG_INVERT_ALPHA; in png_set_invert_alpha()
250 png_set_invert_mono(png_structrp png_ptr) in png_set_invert_mono() argument
254 if (png_ptr == NULL) in png_set_invert_mono()
257 png_ptr->transformations |= PNG_INVERT_MONO; in png_set_invert_mono()
699 png_do_check_palette_indexes(png_structrp png_ptr, png_row_infop row_info) in png_do_check_palette_indexes() argument
701 if (png_ptr->num_palette < (1 << row_info->bit_depth) && in png_do_check_palette_indexes()
702 png_ptr->num_palette > 0) /* num_palette can be 0 in MNG files */ in png_do_check_palette_indexes()
711 png_bytep rp = png_ptr->row_buf + row_info->rowbytes - 1; in png_do_check_palette_indexes()
720 for (; rp > png_ptr->row_buf; rp--) in png_do_check_palette_indexes()
723 png_ptr->num_palette_max = 1; in png_do_check_palette_indexes()
732 for (; rp > png_ptr->row_buf; rp--) in png_do_check_palette_indexes()
736 if (i > png_ptr->num_palette_max) in png_do_check_palette_indexes()
737 png_ptr->num_palette_max = i; in png_do_check_palette_indexes()
741 if (i > png_ptr->num_palette_max) in png_do_check_palette_indexes()
742 png_ptr->num_palette_max = i; in png_do_check_palette_indexes()
746 if (i > png_ptr->num_palette_max) in png_do_check_palette_indexes()
747 png_ptr->num_palette_max = i; in png_do_check_palette_indexes()
751 if (i > png_ptr->num_palette_max) in png_do_check_palette_indexes()
752 png_ptr->num_palette_max = i; in png_do_check_palette_indexes()
762 for (; rp > png_ptr->row_buf; rp--) in png_do_check_palette_indexes()
766 if (i > png_ptr->num_palette_max) in png_do_check_palette_indexes()
767 png_ptr->num_palette_max = i; in png_do_check_palette_indexes()
771 if (i > png_ptr->num_palette_max) in png_do_check_palette_indexes()
772 png_ptr->num_palette_max = i; in png_do_check_palette_indexes()
782 for (; rp > png_ptr->row_buf; rp--) in png_do_check_palette_indexes()
784 if (*rp > png_ptr->num_palette_max) in png_do_check_palette_indexes()
785 png_ptr->num_palette_max = (int) *rp; in png_do_check_palette_indexes()
802 png_set_user_transform_info(png_structrp png_ptr, png_voidp in png_set_user_transform_info() argument
807 if (png_ptr == NULL) in png_set_user_transform_info()
811 if ((png_ptr->mode & PNG_IS_READ_STRUCT) != 0 && in png_set_user_transform_info()
812 (png_ptr->flags & PNG_FLAG_ROW_INIT) != 0) in png_set_user_transform_info()
814 png_app_error(png_ptr, in png_set_user_transform_info()
820 png_ptr->user_transform_ptr = user_transform_ptr; in png_set_user_transform_info()
821 png_ptr->user_transform_depth = (png_byte)user_transform_depth; in png_set_user_transform_info()
822 png_ptr->user_transform_channels = (png_byte)user_transform_channels; in png_set_user_transform_info()
833 png_get_user_transform_ptr(png_const_structrp png_ptr) in png_get_user_transform_ptr() argument
835 if (png_ptr == NULL) in png_get_user_transform_ptr()
838 return png_ptr->user_transform_ptr; in png_get_user_transform_ptr()
844 png_get_current_row_number(png_const_structrp png_ptr) in png_get_current_row_number() argument
849 if (png_ptr != NULL) in png_get_current_row_number()
850 return png_ptr->row_number; in png_get_current_row_number()
856 png_get_current_pass_number(png_const_structrp png_ptr) in png_get_current_pass_number() argument
858 if (png_ptr != NULL) in png_get_current_pass_number()
859 return png_ptr->pass; in png_get_current_pass_number()