/external/chromium_org/third_party/skia/src/utils/ |
H A D | SkTextureCompressor_R11EAC.cpp | 25 // mod_val is chosen from a palette of values based on the index of the 26 // given pixel. The palette is chosen by the value stored in mod. 56 // Pack the base codeword, palette, and multiplier into the 64 bits necessary 58 static uint64_t pack_r11eac_block(uint16_t base_cw, uint16_t palette, uint16_t multiplier, argument 60 SkASSERT(palette < 16); 66 const uint64_t p = static_cast<uint64_t>(palette) << 48; 81 // 3. Iterate through each palette and choose the one with the most accurate 110 // Finally, choose the proper palette and indices 115 const int *palette = kR11EACModifierPalettes[paletteIdx]; 117 // Iterate through each pixel to find the best palette inde [all...] |
H A D | SkTextureCompressor_LATC.cpp | 21 // Generates an LATC palette. LATC constructs 22 // a palette of eight colors from LUM0 and LUM1 using the algorithm: 43 static void generate_latc_palette(uint8_t palette[], uint8_t lum0, uint8_t lum1) { argument 44 palette[0] = lum0; 45 palette[1] = lum1; 48 palette[i+1] = ((7-i)*lum0 + i*lum1) / 7; 52 palette[i+1] = ((5-i)*lum0 + i*lum1) / 5; 54 palette[6] = 0; 55 palette[7] = 255; 140 uint8_t palette[kLATCPaletteSiz local 186 uint8_t palette[kLATCPaletteSize]; local 410 uint8_t palette[kLATCPaletteSize]; local [all...] |
/external/qemu/distrib/sdl-1.2.15/src/video/aalib/ |
H A D | SDL_aavideo.h | 42 aa_palette palette; member in struct:SDL_PrivateVideoData 54 #define AA_palette (this->hidden->palette)
|
/external/qemu/distrib/sdl-1.2.15/test/ |
H A D | testbitmap.c | 65 SDL_Color palette[256]; local 108 palette[i].r = 255-i; 109 palette[i].g = 255-i; 110 palette[i].b = 255-i; 112 SDL_SetColors(screen, palette, 0, 256);
|
H A D | graywin.c | 109 SDL_Color palette[NUM_COLORS]; local 124 palette[i].r = (NUM_COLORS-1)-i * (256 / NUM_COLORS); 125 palette[i].g = (NUM_COLORS-1)-i * (256 / NUM_COLORS); 126 palette[i].b = (NUM_COLORS-1)-i * (256 / NUM_COLORS); 128 SDL_SetColors(screen, palette, 0, NUM_COLORS);
|
H A D | threadwin.c | 46 if ( icon->format->palette == NULL ) { 47 fprintf(stderr, "Icon must have a palette!\n"); 58 icon->format->palette->colors[*pixels].r, 59 icon->format->palette->colors[*pixels].g, 60 icon->format->palette->colors[*pixels].b); 230 SDL_Color palette[256]; local 304 palette[i].r = 255-i; 305 palette[i].g = 255-i; 306 palette[i].b = 255-i; 308 SDL_SetColors(screen, palette, [all...] |
H A D | testwm.c | 28 SDL_Color palette[256]; local 41 palette[i].r = 255-i; 42 palette[i].g = 255-i; 43 palette[i].b = 255-i; 45 SDL_SetColors(screen, palette, 0, 256); 88 if ( icon->format->palette == NULL ) { 89 fprintf(stderr, "Icon must have a palette!\n"); 100 icon->format->palette->colors[*pixels].r, 101 icon->format->palette->colors[*pixels].g, 102 icon->format->palette [all...] |
/external/chromium_org/third_party/mesa/src/src/gallium/state_trackers/va/ |
H A D | va_image.c | 124 vlVaSetImagePalette(VADriverContextP ctx, VAImageID image, unsigned char *palette) argument
|
/external/chromium_org/third_party/mesa/src/src/gallium/state_trackers/xvmc/ |
H A D | xvmc_private.h | 90 /* optional palette for this subpicture */ 91 struct pipe_sampler_view *palette; member in struct:__anon14240
|
H A D | subpicture.c | 283 subpicture_priv->palette = pipe->create_sampler_view(pipe, tex, &sampler_templ); 399 pipe_sampler_view_reference(&subpicture_priv->palette, NULL); 408 Status XvMCSetSubpicturePalette(Display *dpy, XvMCSubpicture *subpicture, unsigned char *palette) argument 416 assert(palette); 427 upload_sampler(pipe, subpicture_priv->palette, &dst_box, palette, 0, 0, 0);
|
/external/chromium_org/third_party/mesa/src/src/mesa/main/ |
H A D | texcompress_cpal.c | 67 * Get a color/entry from the palette. 70 get_palette_entry(const struct cpal_format_info *info, const GLubyte *palette, argument 73 memcpy(pixel, palette + info->size * index, info->size); 82 paletted_to_color(const struct cpal_format_info *info, const GLubyte *palette, argument 95 pix += get_palette_entry(info, palette, (ind[i] >> 4) & 0xf, pix); 96 pix += get_palette_entry(info, palette, ind[i] & 0xf, pix); 99 get_palette_entry(info, palette, (ind[i] >> 4) & 0xf, pix); 106 pix += get_palette_entry(info, palette, ind[i], pix); 163 * compressed palette format into a regular GLubyte/RGBA glTexImage2D() call. 169 GLsizei imageSize, const void *palette) 166 _mesa_cpal_compressed_teximage2d(GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei imageSize, const void *palette) argument [all...] |
/external/libpng/contrib/examples/ |
H A D | pngpixel.c | 82 /* The palette case is slightly more difficult - the palette and, if 89 png_colorp palette = NULL; local 92 if ((png_get_PLTE(png_ptr, info_ptr, &palette, &num_palette) & 93 PNG_INFO_PLTE) && num_palette > 0 && palette != NULL) 101 palette[index].red, palette[index].green, 102 palette[index].blue, 107 palette[index].red, palette[inde [all...] |
/external/mesa3d/src/gallium/state_trackers/va/ |
H A D | va_image.c | 124 vlVaSetImagePalette(VADriverContextP ctx, VAImageID image, unsigned char *palette) argument
|
/external/mesa3d/src/gallium/state_trackers/xvmc/ |
H A D | xvmc_private.h | 90 /* optional palette for this subpicture */ 91 struct pipe_sampler_view *palette; member in struct:__anon27651
|
H A D | subpicture.c | 283 subpicture_priv->palette = pipe->create_sampler_view(pipe, tex, &sampler_templ); 399 pipe_sampler_view_reference(&subpicture_priv->palette, NULL); 408 Status XvMCSetSubpicturePalette(Display *dpy, XvMCSubpicture *subpicture, unsigned char *palette) argument 416 assert(palette); 427 upload_sampler(pipe, subpicture_priv->palette, &dst_box, palette, 0, 0, 0);
|
/external/mesa3d/src/mesa/main/ |
H A D | texcompress_cpal.c | 67 * Get a color/entry from the palette. 70 get_palette_entry(const struct cpal_format_info *info, const GLubyte *palette, argument 73 memcpy(pixel, palette + info->size * index, info->size); 82 paletted_to_color(const struct cpal_format_info *info, const GLubyte *palette, argument 95 pix += get_palette_entry(info, palette, (ind[i] >> 4) & 0xf, pix); 96 pix += get_palette_entry(info, palette, ind[i] & 0xf, pix); 99 get_palette_entry(info, palette, (ind[i] >> 4) & 0xf, pix); 106 pix += get_palette_entry(info, palette, ind[i], pix); 163 * compressed palette format into a regular GLubyte/RGBA glTexImage2D() call. 169 GLsizei imageSize, const void *palette) 166 _mesa_cpal_compressed_teximage2d(GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei imageSize, const void *palette) argument [all...] |
/external/libpng/ |
H A D | pnginfo.h | 36 * cleaned up before the structure is discarded: palette, trans, text, 63 png_colorp palette; /* array of color values (valid & PNG_INFO_PLTE) */ member in struct:png_info_def 64 png_uint_16 num_palette; /* number of color entries in "palette" (PLTE) */ 65 png_uint_16 num_trans; /* number of transparent palette color (tRNS) */ 148 * same order as the palette colors, starting from index 0. Values 155 png_color_16 trans_color; /* transparent color for non-palette image */ 191 * various palette entries, so that a viewer can intelligently select a 192 * reduced-color palette, if required. Data is an array of "num_palette"
|
/external/libvterm/src/ |
H A D | pen.c | 46 // Normal 8 colours or high intensity - parse as palette 0 67 static int lookup_colour(int palette, const long args[], int argcount, VTermColor *col, int *index) argument 69 switch(palette) { 89 fprintf(stderr, "Unrecognised colour palette %d\n", palette); 287 case 34: case 35: case 36: case 37: // Foreground colour palette 295 case 38: // Foreground colour alternative palette 310 case 44: case 45: case 46: case 47: // Background colour palette 316 case 48: // Background colour alternative palette 331 case 94: case 95: case 96: case 97: // Foreground colour high-intensity palette [all...] |
/external/opencv/otherlibs/highgui/ |
H A D | grfmt_bmp.cpp | 507 PaletteEntry palette[256]; local 532 FillGrayPalette( palette, 8 ); 533 m_strm.PutBytes( palette, sizeof(palette));
|
H A D | grfmt_pxm.cpp | 201 PaletteEntry palette[256]; local 227 FillGrayPalette( palette, m_bpp==1 ? 1 : 8 , m_bpp == 1 ); 246 FillColorRow8( data, src, m_width, palette ); 258 FillColorRow1( data, src, m_width, palette );
|
/external/qemu/distrib/sdl-1.2.15/src/video/ |
H A D | SDL_bmp.c | 58 SDL_Palette *palette; local 231 /* Load the palette, if any */ 232 palette = (surface->format)->palette; 233 if ( palette ) { 239 SDL_RWread(src, &palette->colors[i].b, 1, 1); 240 SDL_RWread(src, &palette->colors[i].g, 1, 1); 241 SDL_RWread(src, &palette->colors[i].r, 1, 1); 242 palette->colors[i].unused = 0; 246 SDL_RWread(src, &palette [all...] |
/external/qemu/distrib/sdl-1.2.15/src/video/photon/ |
H A D | SDL_ph_image.c | 37 PgColor_t* palette=NULL; local 73 /* palette emulation code */ 76 /* creating image palette */ 77 palette=SDL_malloc(_Pg_MAX_PALETTE*sizeof(PgColor_t)); 78 if (palette==NULL) 80 SDL_SetError("ph_SetupImage(): can't allocate memory for palette !\n"); 83 PgGetPalette(palette); 86 if ((SDL_Image = PhCreateImage(NULL, screen->w, screen->h, type, palette, _Pg_MAX_PALETTE, 1)) == NULL) 89 SDL_free(palette); 193 /* store palette fo [all...] |
/external/qemu/distrib/sdl-1.2.15/src/video/quartz/ |
H A D | SDL_QuartzVideo.h | 43 - SetColors sets palette correctly but clears framebuffer 95 CGDirectPaletteRef palette; /* palette of an 8-bit display */ member in struct:SDL_PrivateVideoData 136 #define palette (this->hidden->palette) macro
|
/external/skia/src/utils/ |
H A D | SkTextureCompressor.cpp | 37 // Generates an LATC palette. LATC constructs 38 // a palette of eight colors from LUM0 and LUM1 using the algorithm: 58 static void generate_palette(uint8_t palette[], uint8_t lum0, uint8_t lum1) { argument 59 palette[0] = lum0; 60 palette[1] = lum1; 63 palette[i+1] = ((7-i)*lum0 + i*lum1) / 7; 67 palette[i+1] = ((5-i)*lum0 + i*lum1) / 5; 69 palette[6] = 0; 70 palette[7] = 255; 92 uint8_t palette[kPaletteSiz local 138 uint8_t palette[kPaletteSize]; local [all...] |
/external/zopfli/src/zopflipng/ |
H A D | zopflipng_lib.cc | 116 // If true, means palette is possible so avoid using different RGB values for 118 bool palette = count.size() <= 256; local 122 if (key || palette) { 126 // used as a valid color key, or in case of palette ensures a color 127 // existing in the input image palette is used. 142 if (!key && !palette) { 143 // Use the last encountered RGB value if no key or palette is used: that 152 // If there are now less colors, update palette of input image to match this. 153 if (palette && inputstate->info_png.color.palettesize > 0) { 157 unsigned char* palette_in = inputstate->info_png.color.palette; [all...] |