/third_party/cups-filters/cupsfilters/ |
H A D | image-bmp.c | 79 cups_ib_t colormap[256][4]; /* Colormap */ in _cupsImageReadBMP() local 132 fprintf(stderr, "DEBUG: Bad BMP colormap size %d\n", colors_used); in _cupsImageReadBMP() 160 * Get colormap... in _cupsImageReadBMP() 167 if (fread(colormap, colors_used, 4, fp) == 0 && ferror(fp)) in _cupsImageReadBMP() 170 memset(colormap, 0, sizeof(colormap)); in _cupsImageReadBMP() 219 *ptr++ = colormap[1][2]; in _cupsImageReadBMP() 220 *ptr++ = colormap[1][1]; in _cupsImageReadBMP() 221 *ptr++ = colormap[1][0]; in _cupsImageReadBMP() 225 *ptr++ = colormap[ in _cupsImageReadBMP() [all...] |
/third_party/skia/third_party/externals/libjpeg-turbo/ |
H A D | rdbmp.c | 58 JSAMPARRAY colormap; /* BMP colormap (converted to my format) */ member 65 int cmap_length; /* colormap length */ 95 /* Read the colormap from a BMP file */ in read_colormap() 103 sinfo->colormap[2][i] = (JSAMPLE)read_byte(sinfo); in read_colormap() 104 sinfo->colormap[1][i] = (JSAMPLE)read_byte(sinfo); in read_colormap() 105 sinfo->colormap[0][i] = (JSAMPLE)read_byte(sinfo); in read_colormap() 106 if (sinfo->colormap[2][i] != sinfo->colormap[1][i] || in read_colormap() 107 sinfo->colormap[ in read_colormap() 148 register JSAMPARRAY colormap = source->colormap; METHODDEF() local [all...] |
H A D | rdgif.c | 51 #define MAXCOLORMAPSIZE 256 /* max # of colors in a GIF colormap */ 68 #define COLORMAPFLAG 0x80 /* mask for bit signifying colormap presence */ 92 JSAMPARRAY colormap; /* GIF colormap (converted to my format) */ member 346 /* Read a GIF colormap */ in ReadColorMap() 421 /* Allocate space to store the colormap */ in start_input_gif() 422 source->colormap = (*cinfo->mem->alloc_sarray) in start_input_gif() 427 /* Read global colormap if header indicates it is present */ in start_input_gif() 430 ReadColorMap(source, colormaplen, source->colormap); in start_input_gif() 467 /* Read local colormap i in start_input_gif() 556 register JSAMPARRAY colormap = source->colormap; METHODDEF() local 626 register JSAMPARRAY colormap = source->colormap; METHODDEF() local [all...] |
H A D | rdtarga.c | 48 JSAMPARRAY colormap; /* Targa colormap (converted to my format) */ member 60 int cmap_length; /* colormap length */ 97 /* Read the colormap from a Targa file */ in read_colormap() 106 sinfo->colormap[2][i] = (JSAMPLE)read_byte(sinfo); in read_colormap() 107 sinfo->colormap[1][i] = (JSAMPLE)read_byte(sinfo); in read_colormap() 108 sinfo->colormap[0][i] = (JSAMPLE)read_byte(sinfo); in read_colormap() 184 /* This version is for reading 8-bit colormap indexes */ in METHODDEF() 190 register JSAMPARRAY colormap = source->colormap; in METHODDEF() local [all...] |
H A D | wrbmp.c | 217 /* Write a Windows-style BMP file header, including colormap if needed */ in write_bmp_header() 234 /* Compute colormap size and total file size */ in write_bmp_header() 250 /* Grayscale output. We need to fake a 256-entry colormap. */ in write_bmp_header() 255 headersize = 14 + 40 + cmap_entries * 4; /* Header and colormap */ in write_bmp_header() 296 /* Write an OS2-style BMP file header, including colormap if needed */ in write_os2_header() 303 /* Compute colormap size and total file size */ in write_os2_header() 319 /* Grayscale output. We need to fake a 256-entry colormap. */ in write_os2_header() 324 headersize = 14 + 12 + cmap_entries * 3; /* Header and colormap */ in write_os2_header() 356 * Write the colormap. 364 JSAMPARRAY colormap in write_colormap() local [all...] |
H A D | rdcolmap.c | 10 * and constructs a colormap to be supplied to the JPEG decompressor. 13 * GIF: the contents of the GIF's global colormap are used. 49 JSAMPROW colormap0 = cinfo->colormap[0]; in add_map_entry() 50 JSAMPROW colormap1 = cinfo->colormap[1]; in add_map_entry() 51 JSAMPROW colormap2 = cinfo->colormap[2]; in add_map_entry() 227 * Output: colormap and actual_number_of_colors fields are set in cinfo. 234 cinfo->colormap = (*cinfo->mem->alloc_sarray) in read_color_map()
|
H A D | wrgif.c | 243 /* Emit 3 copies of same byte value --- handy subr for colormap construction */ in put_3bytes() 252 emit_header(gif_dest_ptr dinfo, int num_colors, JSAMPARRAY colormap) in emit_header() argument 254 /* If colormap == NULL, synthesize a grayscale colormap */ in emit_header() 295 if (colormap != NULL) { in emit_header() 298 putc(colormap[0][i] >> cshift, dinfo->pub.output_file); in emit_header() 299 putc(colormap[1][i] >> cshift, dinfo->pub.output_file); in emit_header() 300 putc(colormap[2][i] >> cshift, dinfo->pub.output_file); in emit_header() 303 put_3bytes(dinfo, colormap[0][i] >> cshift); in emit_header() 340 emit_header(dest, cinfo->actual_number_of_colors, cinfo->colormap); in start_output_gif() [all...] |
H A D | wrtarga.c | 141 register JSAMPROW color_map0 = cinfo->colormap[0]; in put_demapped_gray() 166 /* demap quantized gray output. Never emit a colormap. */ in start_output_tga() 174 /* We only support 8-bit colormap indexes, so only 256 colors */ in start_output_tga() 179 /* Write the colormap. Note Targa uses BGR byte order */ in start_output_tga() 182 putc(cinfo->colormap[2][i], outfile); in start_output_tga() 183 putc(cinfo->colormap[1][i], outfile); in start_output_tga() 184 putc(cinfo->colormap[0][i], outfile); in start_output_tga()
|
H A D | jquant2.c | 60 * This allowed the color conversion math to be done only once per colormap 64 * externally-supplied colormap. We have therefore abandoned that approach. 109 #define MAXNUMCOLORS (MAXJSAMPLE + 1) /* maximum size of colormap */ 175 /* Space for the eventually created colormap is stashed here */ 176 JSAMPARRAY sv_colormap; /* colormap allocated at init time */ 177 int desired; /* desired # of colors = size of colormap */ 231 * Next we have the really interesting routines: selection of a colormap 479 /* Compute representative color for a box, put it in colormap[icolor] */ in compute_color() 511 cinfo->colormap[0][icolor] = (JSAMPLE)((c0total + (total >> 1)) / total); in compute_color() 512 cinfo->colormap[ in compute_color() [all...] |
H A D | wrppm.c | 195 register JSAMPROW color_map0 = cinfo->colormap[0]; in put_demapped_rgb() 196 register JSAMPROW color_map1 = cinfo->colormap[1]; in put_demapped_rgb() 197 register JSAMPROW color_map2 = cinfo->colormap[2]; in put_demapped_rgb() 219 register JSAMPROW color_map = cinfo->colormap[0]; in put_demapped_gray() 335 /* When quantizing, we need an output buffer for colormap indexes
|
H A D | jquant1.c | 30 * In 1-pass quantization the colormap must be chosen in advance of seeing the 36 * Since the colormap is orthogonal, the representative value for each color 38 * then these indexes can be combined into a colormap index by a standard 44 * index of the colormap entry closest to a given pixel value is just 146 /* Initially allocated colormap is saved here */ 152 * premultiplied as described above. Since colormap indexes must fit into 173 * These routines determine the colormap to be used. The rest of the module 174 * only assumes that the colormap is orthogonal. 273 * Create the colormap. 280 JSAMPARRAY colormap; /* Create in create_colormap() local [all...] |
H A D | jdmaster.c | 487 cinfo->colormap = NULL; in master_selection() 488 } else if (cinfo->colormap != NULL) { in master_selection() 625 if (cinfo->quantize_colors && cinfo->colormap == NULL) { in prepare_for_output_pass() 683 * Switch to a new external colormap between output passes. 696 cinfo->colormap != NULL) { in jpeg_new_colormap() 697 /* Select 2-pass quantizer for external colormap use */ in jpeg_new_colormap() 699 /* Notify quantizer of colormap change */ in jpeg_new_colormap()
|
H A D | jdapimin.c | 217 cinfo->colormap = NULL; in default_decompress_parms()
|
/third_party/skia/third_party/externals/angle2/src/libANGLE/renderer/gl/glx/ |
H A D | WindowSurfaceGLX.cpp | 70 Colormap colormap = 0; in initialize() local 103 // The depth, colormap and visual must match otherwise we get a X error in initialize() 104 // so we specify the colormap attribute. Also we do not want the window in initialize() 113 colormap = XCreateColormap(mDisplay, mParent, visual, AllocNone); in initialize() 114 if (!colormap) in initialize() 120 attributes.colormap = colormap; in initialize() 140 XFreeColormap(mDisplay, colormap); in initialize()
|
/third_party/ffmpeg/libavcodec/ |
H A D | dvdsubdec.c | 40 uint8_t colormap[4]; member 158 uint8_t *colormap = ctx->colormap, *alpha = ctx->alpha; in guess_palette() local 162 rgba_palette[i] = (ctx->palette[colormap[i]] & 0x00ffffff) in guess_palette() 172 if (alpha[i] != 0 && !color_used[colormap[i]]) { in guess_palette() 173 color_used[colormap[i]] = 1; in guess_palette() 185 if (!color_used[colormap[i]]) { in guess_palette() 191 color_used[colormap[i]] = (i + 1); in guess_palette() 194 rgba_palette[i] = (rgba_palette[color_used[colormap[i]] - 1] & 0x00ffffff) | in guess_palette() 224 uint8_t *colormap in decode_dvd_subtitles() local [all...] |
/third_party/backends/sanei/ |
H A D | sanei_jpeg.c | 138 register JSAMPROW color_map0 = cinfo->colormap[0]; in sanei_jpeg_put_demapped_rgb() 139 register JSAMPROW color_map1 = cinfo->colormap[1]; in sanei_jpeg_put_demapped_rgb() 140 register JSAMPROW color_map2 = cinfo->colormap[2]; in sanei_jpeg_put_demapped_rgb() 165 register JSAMPROW color_map = cinfo->colormap[0]; in sanei_jpeg_put_demapped_gray()
|
/third_party/skia/third_party/externals/libpng/contrib/gregbook/ |
H A D | rpng-x.c | 151 static Colormap colormap; variable 516 colormap = XCreateColormap(display, root, visual, AllocNone); in rpng_x_create_window() 517 if (!colormap) { in rpng_x_create_window() 552 attr.colormap = colormap; in rpng_x_create_window() 568 XSetWindowColormap(display, window, colormap); in rpng_x_create_window() 891 XFreeColormap(display, colormap); in rpng_x_cleanup()
|
H A D | rpng2-x.c | 300 static Colormap colormap; variable 905 colormap = XCreateColormap(display, root, visual, AllocNone); in rpng2_x_create_window() 906 if (!colormap) { in rpng2_x_create_window() 936 attr.colormap = colormap; in rpng2_x_create_window() 952 XSetWindowColormap(display, window, colormap); in rpng2_x_create_window() 2123 XFreeColormap(display, colormap); in rpng2_x_cleanup()
|
/third_party/skia/third_party/externals/libpng/ |
H A D | pngwrite.c | 1511 png_const_voidp colormap; member 1787 const void *cmap = display->colormap; in png_image_set_PLTE() 1940 int colormap = (format & PNG_FORMAT_FLAG_COLORMAP); in png_image_write_main() local 1941 int linear = !colormap && (format & PNG_FORMAT_FLAG_LINEAR); /* input */ in png_image_write_main() 1942 int alpha = !colormap && (format & PNG_FORMAT_FLAG_ALPHA); in png_image_write_main() 1991 if (display->colormap != NULL && image->colormap_entries > 0) in png_image_write_main() 2064 if (colormap == 0 && (format & PNG_FORMAT_FLAG_COLOR) != 0) in png_image_write_main() 2073 if (colormap == 0 && (format & PNG_FORMAT_FLAG_ALPHA) != 0) in png_image_write_main() 2082 if (colormap != 0 && image->colormap_entries <= 16) in png_image_write_main() 2123 (colormap in png_image_write_main() 2212 png_image_write_to_memory(png_imagep image, void *memory, png_alloc_size_t * PNG_RESTRICT memory_bytes, int convert_to_8bit, const void *buffer, png_int_32 row_stride, const void *colormap) png_image_write_to_memory() argument 2279 png_image_write_to_stdio(png_imagep image, FILE *file, int convert_to_8bit, const void *buffer, png_int_32 row_stride, const void *colormap) png_image_write_to_stdio() argument 2328 png_image_write_to_file(png_imagep image, const char *file_name, int convert_to_8bit, const void *buffer, png_int_32 row_stride, const void *colormap) png_image_write_to_file() argument [all...] |
H A D | pngread.c | 1544 png_voidp colormap; member 2146 png_uint_16p entry = png_voidcast(png_uint_16p, display->colormap); in png_create_colormap_entry() 2201 png_bytep entry = png_voidcast(png_bytep, display->colormap); in png_create_colormap_entry() 2640 * colormap containing gray levels (for the opaque grays), a in png_image_read_colormap() 2841 * the colormap and that completely transparent pixels map to in png_image_read_colormap() 2991 if (memcmp((png_const_bytep)display->colormap + in png_image_read_colormap() 2993 (png_const_bytep)display->colormap + in png_image_read_colormap() 3065 png_const_colorp colormap = png_ptr->palette; in png_image_read_colormap() local 3097 png_colormap_compose(display, colormap[i].red, in png_image_read_colormap() 3099 png_colormap_compose(display, colormap[ in png_image_read_colormap() 4363 png_image_finish_read(png_imagep image, png_const_colorp background, void *buffer, png_int_32 row_stride, void *colormap) png_image_finish_read() argument [all...] |
H A D | png.h | 2869 * png_uint_16 colormap[PNG_IMAGE_MAXIMUM_COLORMAP_COMPONENTS(linear_fmt)]; 2871 * png_byte colormap[PNG_IMAGE_MAXIMUM_COLORMAP_COMPONENTS(sRGB_fmt)]; 2997 void *colormap)); 3024 * colormap must be supplied when PNG_FORMAT_FLAG_COLORMAP is set. It must 3027 * written to the colormap; this may be less than the original value. 3056 png_int_32 row_stride, const void *colormap)); 3061 const void *colormap)); 3070 * With color-mapped data formats the colormap parameter point to a color-map 3088 const void *buffer, png_int_32 row_stride, const void *colormap)); 3112 row_stride, colormap)\ [all...] |
/third_party/skia/third_party/externals/angle2/util/x11/ |
H A D | X11Window.cpp | 318 Colormap colormap = XCreateColormap(mDisplay, root, visual, AllocNone); in initializeImpl() local 327 attributes.colormap = colormap; in initializeImpl() 331 XFreeColormap(mDisplay, colormap); in initializeImpl()
|
/third_party/ffmpeg/libavformat/ |
H A D | swfdec.c | 331 uint32_t colormap[AVPALETTE_COUNT] = {0}; in swf_read_packet() local 436 if (alpha_bmp) colormap[i] = buf[3]<<24 | AV_RB24(buf + 4*i); in swf_read_packet() 437 else colormap[i] = 0xffU <<24 | AV_RB24(buf + 3*i); in swf_read_packet() 443 memcpy(pal, colormap, AVPALETTE_SIZE); in swf_read_packet()
|
/third_party/skia/third_party/externals/libpng/contrib/libtests/ |
H A D | pngstest.c | 587 png_uint_16 colormap[256*4]; member 1990 * the different algorithms used in libpng for colormap and direct conversions 2013 * Mapping to a colormap smashes the colors, it is necessary to have separate 2126 /* The caller handles the colormap->pixel value conversion, so the in transform_from_formats() 2128 * currently contains a different implementation for mapping a colormap if in transform_from_formats() 2154 * that for the colormap (i.e. linear colormapped output) black is used. in transform_from_formats() 2637 /* First shortcut the two colormap case by comparing the image data; if it in compare_two_images() 2644 /* Only check colormap entries that actually exist; */ in compare_two_images() 2685 png_const_bytep a_cmap = (png_const_bytep)a->colormap; in compare_two_images() 2686 png_const_bytep b_cmap = (png_const_bytep)b->colormap; in compare_two_images() [all...] |
/third_party/mesa3d/src/gallium/targets/graw-xlib/ |
H A D | graw_xlib.c | 109 attr.colormap = XCreateColormap( graw.display, root, visinfo->visual, AllocNone); in graw_create_window_and_screen()
|