Record video and store in private mode

243 views Asked by At

I need to save the video files recorded by the camera in a way that can not be accessed by another application or user connecting the device to a PC.

I want to only can access the files the application that created them.

This is how to set the output path files to record video:

 MediaRecorder videoRecorder;     
//(...)    
 videoRecorder.setOutputFile(Environment.getExternalStorageDirectory().getPath() + "/myfile.mp4");

Is it possible to do in private mode?

1

There are 1 answers

0
isma3l On BEST ANSWER

This saves to internal storage, it's accsesible only for your app.

File file = new File(getFilesDir(),filename);
videoRecorder.setOutputFile(file.getAbsolutePath());

If you want to know more: http://developer.android.com/training/basics/data-storage/files.html