I have this working code for saving a spoken text as an array of Strings:
@Override
protected void onActivityResult(int requestCode, int resultCode,
Intent data) {
if (requestCode == SPEECH_REQUEST && resultCode == RESULT_OK) {
List<String> results = data.getStringArrayListExtra(
RecognizerIntent.EXTRA_RESULTS);
spokenText = results.get(0);
if(strArray.length>arrayKey){
strArray[arrayKey]=spokenText;
arrayKey++;
}
}
I want to do exactly the same not only with spoken text, but with photos and videos I just took. For example, I take photos using this:
private void takePicture() {
Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
startActivityForResult(intent, TAKE_PICTURE_REQUEST);
}
How can I store photos and videos I just captured with the glasses each time after I take them into an array? Obviously, I need to add another "if" case to onActivityResult(), but I would like to know what is the parallel of the SPEECH_REQUEST in photos and videos.
Many thanks!