I\'ve faced a very strange behavior: sometimes my mediarecorder crashes with an error \"Stop failed\" and sometimes it works fine. Is there my fault or it is a bug of the sy
add following in your SurfaceCreated(SurfaceHolder holder):
CamcorderProfile camcorderProfile = CamcorderProfile.get(CamcorderProfile.QUALITY_HIGH); //get your own profile
Camera.Parameters parameters = mCamera.getParameters();
parameters.setPreviewSize(camcorderProfile.videoFrameWidth,camcorderProfile.videoFrameHeight);
mCamera.setParameters(parameters);