Lines Matching defs:src
311 const uint8_t *src, int src_stride, int width, int height,
327 uint16_t *src_u16 = (uint16_t *)src;
342 src += src_stride * sizeof(uint16_t);
350 uint16_t *src_u16 = (uint16_t *)src;
356 src += src_stride * sizeof(uint16_t);
361 const uint8_t *src_u8 = src;
367 src += src_stride;
375 int usePtr, const uint8_t *src,
381 dst[(width+offset)*8+7] = (usePtr ? src[width] : c) & 0x1;
382 dst[(width+offset)*8+6] = (usePtr ? src[width] : c) >> 1 & 0x1;
383 dst[(width+offset)*8+5] = (usePtr ? src[width] : c) >> 2 & 0x1;
384 dst[(width+offset)*8+4] = (usePtr ? src[width] : c) >> 3 & 0x1;
385 dst[(width+offset)*8+3] = (usePtr ? src[width] : c) >> 4 & 0x1;
386 dst[(width+offset)*8+2] = (usePtr ? src[width] : c) >> 5 & 0x1;
387 dst[(width+offset)*8+1] = (usePtr ? src[width] : c) >> 6 & 0x1;
388 dst[(width+offset)*8+0] = (usePtr ? src[width] : c) >> 7;
393 dst[(width+offset)*4+3] = (usePtr ? src[width] : c) & 0x3;
394 dst[(width+offset)*4+2] = (usePtr ? src[width] : c) >> 2 & 0x3;
395 dst[(width+offset)*4+1] = (usePtr ? src[width] : c) >> 4 & 0x3;
396 dst[(width+offset)*4+0] = (usePtr ? src[width] : c) >> 6;
401 dst[(width+offset)*2+1] = (usePtr ? src[width] : c) & 0xF;
402 dst[(width+offset)*2+0] = (usePtr ? src[width] : c) >> 4;
413 init_get_bits8(&gb, src, width);
421 memcpy(dst + offset, src, width);
428 static int deinvert_buffer(TiffContext *s, const uint8_t *src, int size)
436 s->deinvert_buf[i] = ff_reverse[src[i]];
442 const uint8_t *src, int lnum, int width, int bpp)
447 init_get_bits8(&gb, src, width);
455 const uint8_t *src, int lnum)
466 FFMIN(i * s->subsampling[0] + k, s->width-1)] = *src++;
467 *pu++ = *src++;
468 *pv++ = *src++;
475 i * s->subsampling[0] + k] = *src++;
476 *pu++ = *src++;
477 *pv++ = *src++;
483 static int tiff_uncompress(uint8_t *dst, unsigned long *len, const uint8_t *src,
489 zstream.next_in = src;
505 const uint8_t *src, int size, int width, int lines,
516 if ((ret = deinvert_buffer(s, src, size)) < 0) {
520 src = s->deinvert_buf;
522 ret = tiff_uncompress(zbuf, &outlen, src, size);
530 src = zbuf;
533 horizontal_fill(s, s->bpp, dst, 1, src, 0, width, 0);
535 memcpy(dst, src, width);
542 src += width;
550 static int tiff_uncompress_lzma(uint8_t *dst, uint64_t *len, const uint8_t *src,
556 stream.next_in = (uint8_t *)src;
572 const uint8_t *src, int size, int width, int lines,
581 if ((ret = deinvert_buffer(s, src, size)) < 0) {
585 src = s->deinvert_buf;
587 ret = tiff_uncompress_lzma(buf, &outlen, src, size);
595 src = buf;
598 horizontal_fill(s, s->bpp, dst, 1, src, 0, width, 0);
600 memcpy(dst, src, width);
607 src += width;
615 const uint8_t *src, int size, int width, int lines)
621 if ((ret = deinvert_buffer(s, src, size)) < 0)
623 src = s->deinvert_buf;
625 ret = ff_ccitt_unpack(s->avctx, src, size, dst, lines, stride,
726 const uint8_t *src, int size, int strip_start, int lines)
730 const uint8_t *ssrc = src;
776 return tiff_unpack_zlib(s, p, dst, stride, src, size, width, lines,
787 return tiff_unpack_lzma(s, p, dst, stride, src, size, width, lines,
797 if ((ret = deinvert_buffer(s, src, size)) < 0)
799 ssrc = src = s->deinvert_buf;
801 if (size > 1 && !src[0] && (src[1]&1)) {
804 if ((ret = ff_lzw_decode_init(s->lzw, 8, src, size, FF_LZW_TIFF)) < 0) {
833 return tiff_unpack_fax(s, dst, stride, src, size, width, lines);
836 bytestream2_init(&s->gb, src, size);
858 if (src - ssrc > size) {
868 if (ssrc + size - src < width)
873 dst, 1, src, 0, width, 0);
877 dst[i] = ff_reverse[src[i]];
901 src += width;
905 if (ssrc + size - src < 2) {
909 code = s->fill_order ? (int8_t) ff_reverse[*src++]: (int8_t) *src++;
913 ssrc + size - src < code) {
919 dst, 1, src, 0, code, pixels);
920 src += code;
929 c = *src++;
2069 uint8_t *src = five_planes ? five_planes : p->data[plane];
2073 int k = 255 - src[x * j + 3];
2074 int r = (255 - src[x * j ]) * k;
2075 int g = (255 - src[x * j + 1]) * k;
2076 int b = (255 - src[x * j + 2]) * k;
2080 dst[4 * j + 3] = s->avctx->pix_fmt == AV_PIX_FMT_RGBA ? src[x * j + 4] : 255;
2082 src += stride;