我需要这样的东西,但是对于记录意图 (* Intent recordIntent = new Intent( MediaRecorder recorder; * ) :
Intent cameraIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
File imagesFolder = new File(Environment.getExternalStorageDirectory(),
"SecExPhotos");
imagesFolder.mkdirs(); // <----
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyymmddhhmmss");
String date = dateFormat.format(new Date());
File image = new File(imagesFolder, date + ".jpg");
Uri uriSavedImage = Uri.fromFile(image);
cameraIntent.putExtra(MediaStore.EXTRA_OUTPUT,uriSavedImage);
startActivityForResult(cameraIntent, 2);
我希望它是可行的。