Mit einer Kamera Absicht, ein Bild in meiner App zu machen, wurde Bilder von SD-Karte und Galerie dupliziert. Hier ist mein Code Bild zu machen:Bilder dupliziert, wenn das Bild mit der eigenen Kamera innerhalb der App aufgenommen wurde
Intent takePictureIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
// Ensure that there's a camera activity to handle the intent
if (takePictureIntent.resolveActivity(getPackageManager()) != null) {
// Create the File where the photo should go
File photoFile = null;
try {
photoFile = "file to /storage/emulated/0/Pictures/folder/image.jpg"
} catch (IOException ex) {
// Error occurred while creating the File
Log.e("Can't create file", ex.getLocalizedMessage());
}
Uri photoUri = Uri.fromFile(photoFile);
// Continue only if the File was successfully created
if (photoFile != null) {
takePictureIntent.putExtra(MediaStore.EXTRA_OUTPUT, photoUri);
startActivityForResult(takePictureIntent, CAMERA_REQUEST_CODE);
}
Bild gespeichert photoFile
und eine andere gleiche Galerie gespeichert. Wie man es löste?