The Developer Preview for Android 11 is now available; test it out and share your feedback.

Camera2CameraCaptureResult

open class Camera2CameraCaptureResult : CameraCaptureResult
kotlin.Any
   ↳ androidx.camera.camera2.internal.Camera2CameraCaptureResult

The camera2 implementation for the capture result of a single image capture.

Summary

Public constructors

<init>(@Nullable tag: Any?, @NonNull captureResult: CaptureResult)

Public methods

open AeState

Converts the camera2 CaptureResult#CONTROL_AE_STATE to AeState.

open AfMode

Converts the camera2 CaptureResult#CONTROL_AF_MODE to AfMode.

open AfState

Converts the camera2 CaptureResult#CONTROL_AF_STATE to AfState.

open AwbState

Converts the camera2 CaptureResult#CONTROL_AWB_STATE to AwbState.

open CaptureResult

open FlashState

Converts the camera2 CaptureResult#FLASH_STATE to FlashState.

open Any?

open Long

Returns the timestamp in nanoseconds.

Public constructors

<init>

Camera2CameraCaptureResult(
    @Nullable tag: Any?,
    @NonNull captureResult: CaptureResult)

Public methods

getAeState

@NonNull open fun getAeState(): AeState

Converts the camera2 CaptureResult#CONTROL_AE_STATE to AeState.

Return
AeState the AeState.

getAfMode

@NonNull open fun getAfMode(): AfMode

Converts the camera2 CaptureResult#CONTROL_AF_MODE to AfMode.

Return
AfMode the AfMode.

getAfState

@NonNull open fun getAfState(): AfState

Converts the camera2 CaptureResult#CONTROL_AF_STATE to AfState.

Return
AfState the AfState.

getAwbState

@NonNull open fun getAwbState(): AwbState

Converts the camera2 CaptureResult#CONTROL_AWB_STATE to AwbState.

Return
AwbState the AwbState.

getCaptureResult

@NonNull open fun getCaptureResult(): CaptureResult

getFlashState

@NonNull open fun getFlashState(): FlashState

Converts the camera2 CaptureResult#FLASH_STATE to FlashState.

Return
FlashState the FlashState.

getTag

@Nullable open fun getTag(): Any?

getTimestamp

open fun getTimestamp(): Long

Returns the timestamp in nanoseconds.

If the timestamp was unavailable then it will return -1L.