diff --git a/demo/src/main/java/com/otaliastudios/cameraview/demo/CameraActivity.java b/demo/src/main/java/com/otaliastudios/cameraview/demo/CameraActivity.java index 7045c042..125e1315 100644 --- a/demo/src/main/java/com/otaliastudios/cameraview/demo/CameraActivity.java +++ b/demo/src/main/java/com/otaliastudios/cameraview/demo/CameraActivity.java @@ -20,6 +20,8 @@ import com.otaliastudios.cameraview.PictureResult; import com.otaliastudios.cameraview.Mode; import com.otaliastudios.cameraview.VideoResult; +import java.io.File; + public class CameraActivity extends AppCompatActivity implements View.OnClickListener, ControlView.Callback { @@ -163,7 +165,7 @@ public class CameraActivity extends AppCompatActivity implements View.OnClickLis } if (camera.isTakingPicture() || camera.isTakingVideo()) return; message("Recording for 5 seconds...", true); - camera.takeVideo(null, 5000); + camera.takeVideo(new File(getFilesDir(), "video.mp4"), 5000); } private void captureVideoSnapshot() { @@ -172,7 +174,7 @@ public class CameraActivity extends AppCompatActivity implements View.OnClickLis return; } message("Recording snapshot for 5 seconds...", true); - camera.takeVideoSnapshot(null, 5000); + camera.takeVideoSnapshot(new File(getFilesDir(), "video.mp4"), 5000); } private void toggleCamera() {