Home
last modified time | relevance | path

Searched refs:src (Results 1 – 25 of 52) sorted by relevance

123

/gdk/samples/PhotoEditor/src/com/android/photoeditor/filters/
DImageUtils.java35 public static native void nativeBacklight(Bitmap src, Bitmap dst, float backlight); in nativeBacklight() argument
36 public static native void nativeBlur(Bitmap src, Bitmap dst, float scale); in nativeBlur() argument
37 public static native void nativeColorTemp(Bitmap src, Bitmap dst, float scale); in nativeColorTemp() argument
38 public static native void nativeCopy(Bitmap src, Bitmap dst); in nativeCopy() argument
39 public static native void nativeCrossProcess(Bitmap src, Bitmap dst); in nativeCrossProcess() argument
40 public static native void nativeDuotone(Bitmap src, Bitmap dst, int firstColor, in nativeDuotone() argument
42 public static native void nativeFisheye(Bitmap src, Bitmap dst, float focusX, in nativeFisheye() argument
44 public static native void nativeFlipBoth(Bitmap src, Bitmap dst); in nativeFlipBoth() argument
45 public static native void nativeFlipHorizontal(Bitmap src, Bitmap dst); in nativeFlipHorizontal() argument
46 public static native void nativeFlipVertical(Bitmap src, Bitmap dst); in nativeFlipVertical() argument
[all …]
DCropFilter.java38 public void process(Photo src, Photo dst) { in process() argument
39 ImageUtils.nativeCopy(src.bitmap(), dst.bitmap()); in process()
40 dst.crop((int) (src.width() * bounds.left), (int) (src.height() * bounds.top), in process()
41 (int) (src.width() * bounds.width()), (int) (src.height() * bounds.height())); in process()
DFlipFilter.java36 public void process(Photo src, Photo dst) { in process() argument
38 ImageUtils.nativeFlipBoth(src.bitmap(), dst.bitmap()); in process()
40 ImageUtils.nativeFlipHorizontal(src.bitmap(), dst.bitmap()); in process()
42 ImageUtils.nativeFlipVertical(src.bitmap(), dst.bitmap()); in process()
44 ImageUtils.nativeCopy(src.bitmap(), dst.bitmap()); in process()
DStraightenFilter.java45 public void process(Photo src, Photo dst) { in process() argument
46 bounds.set(0, 0, src.width(), src.height()); in process()
49 matrix.postTranslate((src.width() - bounds.width()) / 2, in process()
50 (src.height() - bounds.height()) / 2); in process()
52 canvas.drawBitmap(src.bitmap(), matrix, paint); in process()
DRedEyeFilter.java42 public void process(Photo src, Photo dst) { in process() argument
43 float radius = Math.max(MIN_RADIUS, RADIUS_RATIO * Math.min(src.width(), src.height())); in process()
46 ImageUtils.nativeRedEye(src.bitmap(), dst.bitmap(), in process()
DSepiaFilter.java31 public void process(Photo src, Photo dst) { in process() argument
32 ImageUtils.nativeSepia(src.bitmap(), dst.bitmap()); in process()
DPosterizeFilter.java31 public void process(Photo src, Photo dst) { in process() argument
32 ImageUtils.nativeQuantize(src.bitmap(), dst.bitmap()); in process()
DWarmifyFilter.java31 public void process(Photo src, Photo dst) { in process() argument
32 ImageUtils.nativeWarmify(src.bitmap(), dst.bitmap()); in process()
DNegativeFilter.java31 public void process(Photo src, Photo dst) { in process() argument
32 ImageUtils.nativeNegative(src.bitmap(), dst.bitmap()); in process()
DCrossProcessFilter.java31 public void process(Photo src, Photo dst) { in process() argument
32 ImageUtils.nativeCrossProcess(src.bitmap(), dst.bitmap()); in process()
/gdk/samples/PhotoEditor/jni/
Dsepia.cpp51 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in Sepia() local
52 pixel32_t* src_line_end = src + src_info.width; in Sepia()
53 while (src < src_line_end) { in Sepia()
54 int dst_red = (src->rgba8[0] * 805 + src->rgba8[1] * 1575 + src->rgba8[2] * 387) >> 11; in Sepia()
55 int dst_green = (src->rgba8[0] * 715 + src->rgba8[1] * 1405 + src->rgba8[2] * 344) >> 11; in Sepia()
56 int dst_blue = (src->rgba8[0] * 557 + src->rgba8[1] * 1094 + src->rgba8[2] * 268) >> 11; in Sepia()
68 *dst = (src->rgba8[3] << 24) | (dst_blue << 16) | (dst_green << 8) | dst_red; in Sepia()
70 src++; in Sepia()
Dsaturate.cpp37 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in BenSaturate() local
38 pixel32_t* src_end = src + src_info->width; in BenSaturate()
40 while (src < src_end) { in BenSaturate()
41 int kv = (src->rgba8[0] + src->rgba8[0] + src->rgba8[1] * 5 + src->rgba8[2] + 4) >> 3; in BenSaturate()
43 int dst_red = kv + (((src->rgba8[0] - kv) * scale) >> 8); in BenSaturate()
44 int dst_green = kv + (((src->rgba8[1] - kv) * scale) >> 8); in BenSaturate()
45 int dst_blue = kv + (((src->rgba8[2] - kv) * scale) >> 8); in BenSaturate()
47 *dst = (src->rgba8[3] << 24) | (dst_blue << 16) | (dst_green << 8) | dst_red; in BenSaturate()
50 src++; in BenSaturate()
82 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in HerfSaturate() local
[all …]
Dwarmify.cpp86 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in Warmify() local
87 pixel32_t* src_line_end = src + src_info.width; in Warmify()
89 while (src < src_line_end) { in Warmify()
90 int dst_red = (map[src->rgba8[0]] & 0xFF0000) >> 16; in Warmify()
91 int dst_green = map[src->rgba8[1]] & 0xFF00; in Warmify()
92 int dst_blue = (map[src->rgba8[2]] & 0xFF) << 16; in Warmify()
94 *dst = (src->rgba8[3] << 24) | dst_blue | dst_green | dst_red; in Warmify()
96 src++; in Warmify()
Dquantize.cpp59 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in Quantize() local
62 pixel32_t* src_line_end = src + src_info.width; in Quantize()
63 while (src < src_line_end) { in Quantize()
64 dst->rgba8[0] = quantize_map[src->rgba8[0]]; in Quantize()
65 dst->rgba8[1] = quantize_map[src->rgba8[1]]; in Quantize()
66 dst->rgba8[2] = quantize_map[src->rgba8[2]]; in Quantize()
67 dst->rgba8[3] = src->rgba8[3]; in Quantize()
69 src++; in Quantize()
Dnegative.cpp51 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in Negative() local
52 pixel32_t* src_line_end = src + src_info.width; in Negative()
54 while (src < src_line_end) { in Negative()
55 uint32_t dst_red = 0xff - src->rgba8[0]; in Negative()
56 uint32_t dst_green = 0xff - src->rgba8[1]; in Negative()
57 uint32_t dst_blue = 0xff - src->rgba8[2]; in Negative()
58 uint32_t src_alpha = src->rgba8[3]; in Negative()
62 src++; in Negative()
Dflip.cpp51 uint32_t* src = reinterpret_cast<uint32_t*>(src_pixels); in FlipHorizontal() local
52 uint32_t* src_line_end = src + src_info.width; in FlipHorizontal()
54 while (src < src_line_end) { in FlipHorizontal()
55 *dst = *src; in FlipHorizontal()
56 src++; in FlipHorizontal()
89 uint32_t* src = reinterpret_cast<uint32_t*>(src_pixels); in FlipVertical() local
90 uint32_t* src_line_end = src + src_info.width; in FlipVertical()
92 while (src < src_line_end) { in FlipVertical()
93 *dst = *src; in FlipVertical()
94 src++; in FlipVertical()
[all …]
Dcrossprocess.cpp53 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in CrossProcess() local
54 pixel32_t* src_line_end = src + src_info.width; in CrossProcess()
56 while (src < src_line_end) { in CrossProcess()
58 uint32_t r = src->rgba8[0]; in CrossProcess()
67 int g = src->rgba8[1]; in CrossProcess()
76 int dst_blue = src->rgba8[2] * 128 / 255 + 64; in CrossProcess()
78 *dst = (src->rgba8[3] << 24) | (dst_blue << 16) | (dst_green << 8) | dst_red; in CrossProcess()
80 src++; in CrossProcess()
Dgrayscale.cpp56 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in Grayscale() local
57 pixel32_t* src_line_end = src + src_info.width; in Grayscale()
58 while (src < src_line_end) { in Grayscale()
59 int32_t src_red = src->rgba8[0]; in Grayscale()
60 int32_t src_green = src->rgba8[1]; in Grayscale()
61 int32_t src_blue = src->rgba8[2]; in Grayscale()
62 int32_t src_alpha = src->rgba8[3]; in Grayscale()
71 src++; in Grayscale()
Dtint.cpp61 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in Tint() local
62 pixel32_t* src_line_end = src + src_info.width; in Tint()
63 while (src < src_line_end) { in Tint()
64 int32_t avg = kRedRatio * src->rgba8[0] + kGreenRatio * src->rgba8[1] + in Tint()
65 kBlueRatio * src->rgba8[2]; in Tint()
81 *dst = (src->rgba8[3] << 24) | (dst_blue << 16) | (dst_green << 8) | dst_red; in Tint()
83 src++; in Tint()
Dconvolution.cpp58 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in SpecialConvolution() local
65 *dst++ = src->rgba32; in SpecialConvolution()
66 src++; in SpecialConvolution()
72 int32_t src_red = src->rgba8[0]; in SpecialConvolution()
73 int32_t src_green = src->rgba8[1]; in SpecialConvolution()
74 int32_t src_blue = src->rgba8[2]; in SpecialConvolution()
75 int32_t src_alpha = src->rgba8[3]; in SpecialConvolution()
78 uint8_t* n2 = reinterpret_cast<uint8_t*>(src - 1); in SpecialConvolution()
83 uint8_t* n7 = reinterpret_cast<uint8_t*>(src + 1); in SpecialConvolution()
100 src++; in SpecialConvolution()
[all …]
Dcolortemp.cpp66 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in ColorTemp() local
67 pixel32_t* src_line_end = src + src_info.width; in ColorTemp()
69 while (src < src_line_end) { in ColorTemp()
70 int32_t src_red = src->rgba8[0]; in ColorTemp()
71 int32_t src_green = src->rgba8[1]; in ColorTemp()
72 int32_t src_blue = src->rgba8[2]; in ColorTemp()
73 int32_t src_alpha = src->rgba8[3]; in ColorTemp()
89 src++; in ColorTemp()
Dbacklight.cpp67 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in Backlight() local
68 pixel32_t* src_line_end = src + src_info.width; in Backlight()
69 while (src < src_line_end) { in Backlight()
70 int32_t src_red = src->rgba8[0]; in Backlight()
71 int32_t src_green = src->rgba8[1]; in Backlight()
72 int32_t src_blue = src->rgba8[2]; in Backlight()
73 int32_t src_alpha = src->rgba8[3]; in Backlight()
98 src++; in Backlight()
Dduotone.cpp73 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in Duotone() local
74 pixel32_t* src_line_end = src + src_info.width; in Duotone()
76 while (src < src_line_end) { in Duotone()
77 uint32_t energy = src->rgba8[0] + src->rgba8[1] + src->rgba8[2]; in Duotone()
83 *dst = (src->rgba8[3] << 24) | (dst_blue << 16) | (dst_green << 8) | dst_red; in Duotone()
85 src++; in Duotone()
Dwhiteblack.cpp72 pixel32_t* src = reinterpret_cast<pixel32_t*>(src_pixels); in WhiteBlack() local
74 pixel32_t* src_line_end = src + src_info.width; in WhiteBlack()
75 while (src < src_line_end) { in WhiteBlack()
76 int32_t red = src->rgba8[0]; in WhiteBlack()
77 int32_t green = src->rgba8[1]; in WhiteBlack()
78 int32_t blue = src->rgba8[2]; in WhiteBlack()
79 int32_t alpha = src->rgba8[3]; in WhiteBlack()
103 src++; in WhiteBlack()
Dvignetting.cpp67 pixel32_t *src = reinterpret_cast<pixel32_t*>( in Vignetting() local
75 uint32_t red = (luminousity * src->rgba8[0]) >> kShiftBits; in Vignetting()
76 uint32_t green = (luminousity * src->rgba8[1]) >> kShiftBits; in Vignetting()
77 uint32_t blue = (luminousity * src->rgba8[2]) >> kShiftBits; in Vignetting()
78 uint32_t alpha = src->rgba8[3]; in Vignetting()
81 src++; in Vignetting()

123