ViewfinderSurfaceRequest


class ViewfinderSurfaceRequest


The request to get an android.view.Surface to display viewfinder input.

This request contains requirements for the surface resolution and viewfinder input and output information.

Summary

Public constructors

ViewfinderSurfaceRequest(
    width: Int,
    height: Int,
    implementationMode: ImplementationMode?,
    requestId: String?
)

Creates a new surface request with given resolution, and optional implementation mode request ID.

Public functions

ViewfinderSurfaceRequest
copy(
    width: Int,
    height: Int,
    implementationMode: ImplementationMode?,
    requestId: String?
)

Creates a copy of this viewfinder surface request, allowing named properties to be altered while keeping the rest unchanged.

open operator Boolean
equals(other: Any?)
open Int
open String

Public properties

Int

The requested surface height.

ImplementationMode?

The ImplementationMode to apply to the viewfinder.

String?

An optional request ID to allow requests to be differentiated via equals.

Int

The requested surface width.

Public constructors

ViewfinderSurfaceRequest

Added in 1.5.0-beta01
ViewfinderSurfaceRequest(
    width: Int,
    height: Int,
    implementationMode: ImplementationMode? = null,
    requestId: String? = null
)

Creates a new surface request with given resolution, and optional implementation mode request ID.

Public functions

copy

Added in 1.5.0-beta01
fun copy(
    width: Int = this.width,
    height: Int = this.height,
    implementationMode: ImplementationMode? = this.implementationMode,
    requestId: String? = this.requestId
): ViewfinderSurfaceRequest

Creates a copy of this viewfinder surface request, allowing named properties to be altered while keeping the rest unchanged.

equals

open operator fun equals(other: Any?): Boolean

hashCode

open fun hashCode(): Int

toString

open fun toString(): String

Public properties

height

Added in 1.5.0-beta01
val heightInt

The requested surface height.

implementationMode

Added in 1.5.0-beta01
val implementationModeImplementationMode?

The ImplementationMode to apply to the viewfinder. Defaults to null, which will use the viewfinder's default implementation mode.

requestId

Added in 1.5.0-beta01
val requestIdString?

An optional request ID to allow requests to be differentiated via equals. Defaults to null.

width

Added in 1.5.0-beta01
val widthInt

The requested surface width.