How to read length of video recorded with MediaRecorder into private app storage directory constructed via context.getFilesDir()?
问题 I am having a weird issue reading the length/duration of a video file recorded with a device's camera by using MediaRecorder. The file is recorded into the application's private storage directory, which is set like so: mMediaRecorder.setOutputFile(context.getFilesDir() + "/recordings/webcam.3gpp"); After recording is complete, I attempt to read the length of the video with these methods: Method 1: MediaMetadataRetriever mediaMetadataRetriever = new MediaMetadataRetriever();