Lines Matching refs:pixels

103 //!	Make RGB32 scanline from *pixels[3]
105 read_rgb24_to_rgb32(jas_matrix_t** pixels, uchar* scanline, int width)
110 scanline[index++] = (uchar)jas_matrix_getv(pixels[2], x);
111 scanline[index++] = (uchar)jas_matrix_getv(pixels[1], x);
112 scanline[index++] = (uchar)jas_matrix_getv(pixels[0], x);
119 //! Make gray scanline from *pixels[1]
121 read_gray_to_rgb32(jas_matrix_t** pixels, uchar* scanline, int width)
127 color = (uchar)jas_matrix_getv(pixels[0], x++);
137 Make RGBA32 scanline from *pixels[4]
141 read_rgba32(jas_matrix_t** pixels, uchar *scanline, int width)
146 scanline[index++] = (uchar)jas_matrix_getv(pixels[2], x);
147 scanline[index++] = (uchar)jas_matrix_getv(pixels[1], x);
148 scanline[index++] = (uchar)jas_matrix_getv(pixels[0], x);
149 scanline[index++] = (uchar)jas_matrix_getv(pixels[3], x);
156 Make gray scanline from *pixels[1]
160 read_gray(jas_matrix_t** pixels, uchar* scanline, int width)
164 scanline[x] = (uchar)jas_matrix_getv(pixels[0], x);
170 //! Make *pixels[1] from gray1 scanline
172 write_gray1_to_gray(jas_matrix_t** pixels, uchar* scanline, int width)
180 jas_matrix_setv(pixels[0], index++, 0);
182 jas_matrix_setv(pixels[0], index++, 255);
188 //! Make *pixels[3] from gray1 scanline
190 write_gray1_to_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
198 jas_matrix_setv(pixels[0], index, 0);
199 jas_matrix_setv(pixels[1], index, 0);
200 jas_matrix_setv(pixels[2], index, 0);
202 jas_matrix_setv(pixels[0], index, 255);
203 jas_matrix_setv(pixels[1], index, 255);
204 jas_matrix_setv(pixels[2], index, 255);
212 //! Make *pixels[3] from cmap8 scanline
214 write_cmap8_to_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
221 jas_matrix_setv(pixels[0], x, color.red);
222 jas_matrix_setv(pixels[1], x, color.green);
223 jas_matrix_setv(pixels[2], x, color.blue);
230 Make *pixels[1] from gray scanline
231 (just write data to pixels)
234 write_gray(jas_matrix_t** pixels, uchar* scanline, int width)
238 jas_matrix_setv(pixels[0], x, scanline[x]);
245 Make *pixels[3] from RGB15/RGBA15 scanline
246 (just write data to pixels)
249 write_rgb15_to_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
258 jas_matrix_setv(pixels[0], x, (char)(((in_pixel & 0x7c00)) >> 7)
260 jas_matrix_setv(pixels[1], x, (char)(((in_pixel & 0x3e0)) >> 2)
262 jas_matrix_setv(pixels[2], x, (char)(((in_pixel & 0x1f)) << 3)
270 Make *pixels[3] from RGB15/RGBA15 bigendian scanline
271 (just write data to pixels)
274 write_rgb15b_to_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
283 jas_matrix_setv(pixels[0], x, (char)(((in_pixel & 0x7c00)) >> 7)
285 jas_matrix_setv(pixels[1], x, (char)(((in_pixel & 0x3e0)) >> 2)
287 jas_matrix_setv(pixels[2], x, (char)(((in_pixel & 0x1f)) << 3)
295 Make *pixels[3] from RGB16/RGBA16 scanline
296 (just write data to pixels)
299 write_rgb16_to_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
308 jas_matrix_setv(pixels[0], x, (char)(((in_pixel & 0xf800)) >> 8)
310 jas_matrix_setv(pixels[1], x, (char)(((in_pixel & 0x7e0)) >> 3)
312 jas_matrix_setv(pixels[2], x, (char)(((in_pixel & 0x1f)) << 3)
320 Make *pixels[3] from RGB16/RGBA16 bigendian scanline
321 (just write data to pixels)
324 write_rgb16b_to_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
333 jas_matrix_setv(pixels[0], x, (char)(((in_pixel & 0xf800)) >> 8)
335 jas_matrix_setv(pixels[1], x, (char)(((in_pixel & 0x7e0)) >> 3)
337 jas_matrix_setv(pixels[2], x, (char)(((in_pixel & 0x1f)) << 3)
345 Make *pixels[3] from RGB24 scanline
346 (just write data to pixels)
349 write_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
354 jas_matrix_setv(pixels[2], x, scanline[index++]);
355 jas_matrix_setv(pixels[1], x, scanline[index++]);
356 jas_matrix_setv(pixels[0], x, scanline[index++]);
363 Make *pixels[3] from RGB24 bigendian scanline
364 (just write data to pixels)
367 write_rgb24b(jas_matrix_t** pixels, uchar* scanline, int width)
372 jas_matrix_setv(pixels[0], x, scanline[index++]);
373 jas_matrix_setv(pixels[1], x, scanline[index++]);
374 jas_matrix_setv(pixels[2], x, scanline[index++]);
381 Make *pixels[3] from RGB32 scanline
382 (just write data to pixels)
385 write_rgb32_to_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
390 jas_matrix_setv(pixels[2], x, scanline[index++]);
391 jas_matrix_setv(pixels[1], x, scanline[index++]);
392 jas_matrix_setv(pixels[0], x, scanline[index++]);
400 Make *pixels[3] from RGB32 bigendian scanline
401 (just write data to pixels)
404 write_rgb32b_to_rgb24(jas_matrix_t** pixels, uchar* scanline, int width)
410 jas_matrix_setv(pixels[0], x, scanline[index++]);
411 jas_matrix_setv(pixels[1], x, scanline[index++]);
412 jas_matrix_setv(pixels[2], x, scanline[index++]);
419 Make *pixels[4] from RGBA32 scanline
420 (just write data to pixels)
424 write_rgba32(jas_matrix_t** pixels, uchar* scanline, int width)
429 jas_matrix_setv(pixels[3], x, scanline[index++]);
430 jas_matrix_setv(pixels[2], x, scanline[index++]);
431 jas_matrix_setv(pixels[1], x, scanline[index++]);
432 jas_matrix_setv(pixels[0], x, scanline[index++]);
439 Make *pixels[4] from RGBA32 bigendian scanline
440 (just write data to pixels)
444 write_rgba32b(jas_matrix_t** pixels, uchar* scanline, int width)
449 jas_matrix_setv(pixels[0], x, scanline[index++]);
450 jas_matrix_setv(pixels[1], x, scanline[index++]);
451 jas_matrix_setv(pixels[2], x, scanline[index++]);
452 jas_matrix_setv(pixels[3], x, scanline[index++]);
904 void (*converter)(jas_matrix_t** pixels, uchar* inscanline,
999 jas_matrix_t* pixels[4];
1028 pixels[i] = jas_matrix_create(1, (unsigned int)width);
1029 if (pixels[i] == (jas_matrix_t *)NULL)
1030 return Error(outs, image, pixels, i+1, in_scanline, B_ERROR);
1037 return (err < B_OK) ? Error(outs, image, pixels,
1039 : Error(outs, image, pixels, out_color_components, in_scanline,
1043 converter(pixels, in_scanline, width);
1047 (unsigned int)width, 1, pixels[i]);
1058 return Error(outs, image, pixels,
1065 jas_matrix_destroy(pixels[i]);
1083 jas_matrix_t* pixels[4];
1101 void (*converter)(jas_matrix_t** pixels, uchar* outscanline,
1176 pixels[i] = jas_matrix_create(1, (unsigned int)width);
1177 if (pixels[i] == (jas_matrix_t *)NULL)
1178 return Error(ins, image, pixels, i + 1, out_scanline, B_ERROR);
1185 (unsigned int)width, 1, pixels[i]);
1188 converter(pixels, out_scanline, (int32)width);
1192 return (err < B_OK) ? Error(ins, image, pixels, in_color_components,
1194 : Error(ins, image, pixels, in_color_components, out_scanline,
1202 jas_matrix_destroy(pixels[i]);
1264 Error(jas_stream_t* stream, jas_image_t* image, jas_matrix_t** pixels,
1267 if (pixels) {
1270 if (pixels[i] != NULL)
1271 jas_matrix_destroy(pixels[i]);