summaryrefslogtreecommitdiffstats
path: root/src/org
diff options
context:
space:
mode:
authorjunjiez <junjiez@codeaurora.org>2017-07-13 17:35:49 +0800
committerGerrit - the friendly Code Review server <code-review@localhost>2017-07-26 00:29:59 -0700
commitf18663eae3f80a46bdaa1a140abd2799577bb739 (patch)
tree490a263637642c89df6af2bccabc1deb0e20a434 /src/org
parentef407574ede2694755abbd5a872936623030c1d7 (diff)
downloadandroid_packages_apps_Snap-f18663eae3f80a46bdaa1a140abd2799577bb739.tar.gz
android_packages_apps_Snap-f18663eae3f80a46bdaa1a140abd2799577bb739.tar.bz2
android_packages_apps_Snap-f18663eae3f80a46bdaa1a140abd2799577bb739.zip
SnapdragonCamera:modify RTB UI
1. reduce the size of the bokeh focus circle. 2. hide bokeh focus circle and seekbar when it's not needed. 3. update the location of the seekbar according the location of the bokeh focus circle 4. convert depth map buffer to rgb then compress to jpeg Change-Id: Ibfa4d1d90413939566129247a23325f941507691
Diffstat (limited to 'src/org')
-rwxr-xr-xsrc/org/codeaurora/snapcam/filter/GDepth.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/org/codeaurora/snapcam/filter/GDepth.java b/src/org/codeaurora/snapcam/filter/GDepth.java
index 92c0e07f5..d3a7cb19c 100755
--- a/src/org/codeaurora/snapcam/filter/GDepth.java
+++ b/src/org/codeaurora/snapcam/filter/GDepth.java
@@ -77,6 +77,7 @@ public class GDepth{
private String mData;
private final String mFormat = FORMAT_8_BIT;
private int[] mMap;
+ private byte[] mGdepthJpeg;
static {
try {
@@ -139,6 +140,7 @@ public class GDepth{
ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
bitmap.compress(Bitmap.CompressFormat.JPEG, 100, outputStream);
byte[] jpegBytes = outputStream.toByteArray();
+ mGdepthJpeg = jpegBytes;
if (jpegBytes != null ) {
String base64String = serializeAsBase64Str(jpegBytes);
result = true;
@@ -179,6 +181,10 @@ public class GDepth{
return outputStream.toByteArray();
}
+ public byte[] getDepthJpeg() {
+ return mGdepthJpeg;
+ }
+
private String serializeAsBase64Str(byte[] image) {
Log.d(TAG, "serializeAsBase64Str");
return Base64.encodeToString(image, Base64.DEFAULT);