I am building a camera app, where videos are continuously being captured and saved to the SD card. The videos are short (few minutes), and their length are preset with setMa
You just have to create a surface with MediaCodec by adding the following line:
MediaCodec
Surface mySurface = MediaCodec.createPersistentInputSurface(); mMediaRecorder.setPreviewDisplay(mySurface); ... mMediaRecorder.prepare();