summaryrefslogtreecommitdiffstats
path: root/src/com/android/gallery3d/filtershow/filters/ImageFilterExposure.java
diff options
context:
space:
mode:
authorJohn Hoford <hoford@google.com>2012-10-01 17:21:55 -0700
committerJohn Hoford <hoford@google.com>2012-10-01 17:47:50 -0700
commitaab2640d1eec784f75fea0b4c8bb2ea4fb4325fd (patch)
tree6b49b7bc946ae2e4b40f06f2e913073652a0a1d5 /src/com/android/gallery3d/filtershow/filters/ImageFilterExposure.java
parentdb61fdf195283c18b9dfbc523fced2358b437008 (diff)
downloadandroid_packages_apps_Snap-aab2640d1eec784f75fea0b4c8bb2ea4fb4325fd.tar.gz
android_packages_apps_Snap-aab2640d1eec784f75fea0b4c8bb2ea4fb4325fd.tar.bz2
android_packages_apps_Snap-aab2640d1eec784f75fea0b4c8bb2ea4fb4325fd.zip
Fix exposure and fixed warnings
bug:7234321
Diffstat (limited to 'src/com/android/gallery3d/filtershow/filters/ImageFilterExposure.java')
-rw-r--r--src/com/android/gallery3d/filtershow/filters/ImageFilterExposure.java22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/com/android/gallery3d/filtershow/filters/ImageFilterExposure.java b/src/com/android/gallery3d/filtershow/filters/ImageFilterExposure.java
new file mode 100644
index 000000000..85b6e4f6b
--- /dev/null
+++ b/src/com/android/gallery3d/filtershow/filters/ImageFilterExposure.java
@@ -0,0 +1,22 @@
+
+package com.android.gallery3d.filtershow.filters;
+
+import android.graphics.Bitmap;
+
+public class ImageFilterExposure extends ImageFilter {
+
+ public ImageFilterExposure() {
+ mName = "Exposure";
+ }
+
+ native protected void nativeApplyFilter(Bitmap bitmap, int w, int h, float bright);
+
+ @Override
+ public void apply(Bitmap bitmap) {
+ int w = bitmap.getWidth();
+ int h = bitmap.getHeight();
+ int p = mParameter;
+ float value = p;
+ nativeApplyFilter(bitmap, w, h, value);
+ }
+}