I am working on a app about recording videos, but I have problems using the app. When I click the record button, it stops. I have already checked the logcat, it said "setVideoSource failed." :( By the way, I am not really good at English, I may make some mistakes... QAQ And here is my code:
recorder = new MediaRecorder();
recorder.setPreviewDisplay(holder.getSurface());
recorder.setVideoSource(MediaRecorder.VideoSource.CAMERA);
recorder.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP);
recorder.setVideoFrameRate(25);
recorder.setVideoSize(800,480);
recorder.setVideoEncoder(MediaRecorder.VideoEncoder.H264);
recorder.setOutputFile(path);