securesmartcam / app / src / main / java / org / witness / obscuracam / photo / filters / PicassoObscure.java @ 41590feb
History | View | Annotate | Download (938 Bytes)
1 |
/*
|
---|---|
2 |
* This ObscureMethod pixelizes the region
|
3 |
*/
|
4 |
|
5 |
package org.witness.obscuracam.photo.filters; |
6 |
|
7 |
|
8 |
import java.util.Properties; |
9 |
|
10 |
import android.graphics.Bitmap; |
11 |
import android.graphics.Canvas; |
12 |
import android.graphics.RectF; |
13 |
|
14 |
public class PicassoObscure implements RegionProcesser { |
15 |
|
16 |
Bitmap originalBmp; |
17 |
Properties mProps;
|
18 |
|
19 |
public PicassoObscure ()
|
20 |
{ |
21 |
mProps = new Properties (); |
22 |
mProps.put("size", "10"); |
23 |
mProps.put("obfuscationType", this.getClass().getName()); |
24 |
} |
25 |
|
26 |
public void processRegion(RectF rect, Canvas canvas, Bitmap bitmap) { |
27 |
|
28 |
originalBmp = bitmap; |
29 |
|
30 |
|
31 |
|
32 |
//pixelate(rect, pixelSize);
|
33 |
|
34 |
//originalBmp.setPixels(pixels, 0, pixelSize, x, y, wPixelSize, hPixelSize);
|
35 |
|
36 |
} |
37 |
|
38 |
|
39 |
|
40 |
public Properties getProperties() |
41 |
{ |
42 |
return mProps;
|
43 |
} |
44 |
|
45 |
public void setProperties(Properties props) |
46 |
{ |
47 |
mProps = props; |
48 |
} |
49 |
|
50 |
@Override
|
51 |
public Bitmap getBitmap() {
|
52 |
// TODO Auto-generated method stub
|
53 |
return null; |
54 |
} |
55 |
} |
56 |
|
57 |
|
58 |
|