diff --git a/simplecv-android-app/bin/res/drawable-hdpi/ic_launcher.png b/simplecv-android-app/bin/res/drawable-hdpi/ic_launcher.png deleted file mode 100644 index bcfa058..0000000 Binary files a/simplecv-android-app/bin/res/drawable-hdpi/ic_launcher.png and /dev/null differ diff --git a/simplecv-android-app/bin/res/drawable-ldpi/ic_launcher.png b/simplecv-android-app/bin/res/drawable-ldpi/ic_launcher.png deleted file mode 100644 index dd7c05b..0000000 Binary files a/simplecv-android-app/bin/res/drawable-ldpi/ic_launcher.png and /dev/null differ diff --git a/simplecv-android-app/bin/res/drawable-mdpi/ic_launcher.png b/simplecv-android-app/bin/res/drawable-mdpi/ic_launcher.png deleted file mode 100644 index 85848ff..0000000 Binary files a/simplecv-android-app/bin/res/drawable-mdpi/ic_launcher.png and /dev/null differ diff --git a/simplecv-android-app/bin/res/drawable-xhdpi/ic_launcher.png b/simplecv-android-app/bin/res/drawable-xhdpi/ic_launcher.png deleted file mode 100644 index 916901e..0000000 Binary files a/simplecv-android-app/bin/res/drawable-xhdpi/ic_launcher.png and /dev/null differ diff --git a/simplecv-android-app/res/drawable-hdpi/ic_launcher.png b/simplecv-android-app/res/drawable-hdpi/ic_launcher.png deleted file mode 100644 index 96a442e..0000000 Binary files a/simplecv-android-app/res/drawable-hdpi/ic_launcher.png and /dev/null differ diff --git a/simplecv-android-app/res/drawable-ldpi/ic_launcher.png b/simplecv-android-app/res/drawable-ldpi/ic_launcher.png deleted file mode 100644 index 9923872..0000000 Binary files a/simplecv-android-app/res/drawable-ldpi/ic_launcher.png and /dev/null differ diff --git a/simplecv-android-app/res/drawable-mdpi/ic_launcher.png b/simplecv-android-app/res/drawable-mdpi/ic_launcher.png deleted file mode 100644 index 359047d..0000000 Binary files a/simplecv-android-app/res/drawable-mdpi/ic_launcher.png and /dev/null differ diff --git a/simplecv-android-app/res/drawable-xhdpi/ic_launcher.png b/simplecv-android-app/res/drawable-xhdpi/ic_launcher.png deleted file mode 100644 index 71c6d76..0000000 Binary files a/simplecv-android-app/res/drawable-xhdpi/ic_launcher.png and /dev/null differ diff --git a/simplecv-android-app/res/layout/display.xml b/simplecv-android-app/res/layout/display.xml index 7c9f3b7..a566d73 100644 --- a/simplecv-android-app/res/layout/display.xml +++ b/simplecv-android-app/res/layout/display.xml @@ -49,6 +49,8 @@ + android:layout_height="fill_parent" + android:clickable="true" + android:onClick="clickImage" /> \ No newline at end of file diff --git a/simplecv-android-app/src/com/simplecv/hellocamera/DisplayResultsActivity.java b/simplecv-android-app/src/com/simplecv/hellocamera/DisplayResultsActivity.java index af70f35..71974b7 100644 --- a/simplecv-android-app/src/com/simplecv/hellocamera/DisplayResultsActivity.java +++ b/simplecv-android-app/src/com/simplecv/hellocamera/DisplayResultsActivity.java @@ -30,6 +30,13 @@ public void onCreate(Bundle savedInstanceState) { modifiedImage = (ImageView) findViewById(R.id.modifiedimage); new displayImageTask().execute(modifiedImageUri); } + + public void clickImage(View view){ + Intent viewImageIntent = new Intent(Intent.ACTION_VIEW); + viewImageIntent.setDataAndType(modifiedImageUri,"image/*"); + startActivity(viewImageIntent); + } + public void deletePicture(View view){ File picture = new File(modifiedImageUri.getPath()); @@ -60,8 +67,8 @@ public Bitmap decodeFile(File f){ fis.close(); int scale = 1; - if (o.outHeight > 350 || o.outWidth > 350) { //Max size = ? - scale = (int)Math.pow(2, (int) Math.round(Math.log(300 / (double) Math.max(o.outHeight, o.outWidth)) / Math.log(0.5))); + if (o.outHeight > 350 || o.outWidth > 350) { + scale = (int)Math.pow(2, (int) Math.round(Math.log(350 / (double) Math.max(o.outHeight, o.outWidth)) / Math.log(0.5))); } BitmapFactory.Options o2 = new BitmapFactory.Options(); diff --git a/simplecv-android-app/src/com/simplecv/hellocamera/HelloCameraNewApiActivity.java b/simplecv-android-app/src/com/simplecv/hellocamera/HelloCameraNewApiActivity.java index 9d8c8f1..383e27b 100644 --- a/simplecv-android-app/src/com/simplecv/hellocamera/HelloCameraNewApiActivity.java +++ b/simplecv-android-app/src/com/simplecv/hellocamera/HelloCameraNewApiActivity.java @@ -101,7 +101,7 @@ public void onCreate(Bundle savedInstanceState) { } public File getNewPictureFile(){ - File mediaStorageDir = new File(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES), "SimpleCV"); //WHERETO? Context.DIRECTORY_PICTURES? + File mediaStorageDir = new File(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES), "SimpleCV"); if (!mediaStorageDir.exists()){ if (!mediaStorageDir.mkdirs()){ Log.i("SimpleCV", "Failed to create directory");