Google se compromete a impulsar la igualdad racial para las comunidades afrodescendientes. Obtén información al respecto.

OnVideoSavedCallback

interface OnVideoSavedCallback
androidx.camera.view.video.OnVideoSavedCallback

Listener containing callbacks for video file I/O events.

Summary

Constants
static Int

An error occurred with encoder state, either when trying to change state or when an unexpected state change occurred.

static Int

An error indicating the file saving operations.

static Int

An error indicating this VideoCapture is not bound to a camera.

static Int

An error with muxer state such as during creation or when stopping.

static Int

An error indicating start recording was called when video recording is still in progress.

static Int

An unknown error occurred.

Public methods
abstract Unit
onError(videoCaptureError: Int, @NonNull message: String, @Nullable cause: Throwable?)

Called when an error occurs while attempting to save the video.

abstract Unit
onVideoSaved(@NonNull outputFileResults: OutputFileResults)

Called when the video has been successfully saved.

Constants

ERROR_ENCODER

static val ERROR_ENCODER: Int

An error occurred with encoder state, either when trying to change state or when an unexpected state change occurred.

Value: VideoCapture.ERROR_ENCODER

ERROR_FILE_IO

static val ERROR_FILE_IO: Int

An error indicating the file saving operations.

Value: VideoCapture.ERROR_FILE_IO

ERROR_INVALID_CAMERA

static val ERROR_INVALID_CAMERA: Int

An error indicating this VideoCapture is not bound to a camera.

Value: VideoCapture.ERROR_INVALID_CAMERA

ERROR_MUXER

static val ERROR_MUXER: Int

An error with muxer state such as during creation or when stopping.

Value: VideoCapture.ERROR_MUXER

ERROR_RECORDING_IN_PROGRESS

static val ERROR_RECORDING_IN_PROGRESS: Int

An error indicating start recording was called when video recording is still in progress.

Value: VideoCapture.ERROR_RECORDING_IN_PROGRESS

ERROR_UNKNOWN

static val ERROR_UNKNOWN: Int

An unknown error occurred.

See message parameter in onError callback or log for more details.

Value: VideoCapture.ERROR_UNKNOWN

Public methods

onError

abstract fun onError(
    videoCaptureError: Int,
    @NonNull message: String,
    @Nullable cause: Throwable?
): Unit

Called when an error occurs while attempting to save the video.

onVideoSaved

abstract fun onVideoSaved(@NonNull outputFileResults: OutputFileResults): Unit

Called when the video has been successfully saved.