i need to capture video from required portion of the screen like -
I have tried
...
try {
camera.unlock();
recorder.setCamera(camera);
recorder.setOrientationHint(cameraRotationDegree);
recorder.setAudioSource(MediaRecorder.AudioSource.MIC);
recorder.setVideoSource(MediaRecorder.VideoSource.CAMERA);
recorder.setOutputFormat(MediaRecorder.OutputFormat.MPEG_4);
**recorder.setVideoSize(sz.width, sz.height);**
recorder.setAudioEncoder(MediaRecorder.AudioEncoder.DEFAULT);
recorder.setVideoEncoder(MediaRecorder.VideoEncoder.MPEG_4_SP);
recorder.setOutputFile(fileName);
recorder.prepare();
recorder.start();
isRecording = true;
} catch (IllegalStateException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
but it records while screen.
is it possible to capture video from required portion of the screen?