getSuggestedStreamSpecifications

fun getSuggestedStreamSpecifications(cameraMode: Int, attachedSurfaces: List<<Error class: unknown class>>, newUseCaseConfigsSupportedSizeMap: Map<<Error class: unknown class><out <Error class: unknown class>>, List<Size>>, videoStabilization: <Error class: unknown class> = VideoStabilization.UNSPECIFIED, hasVideoCapture: Boolean = false, isFeatureComboInvocation: Boolean, findMaxSupportedFrameRate: Boolean): <Error class: unknown class>

Finds the suggested stream specification of the newly added UseCaseConfig.

Return

a SurfaceStreamSpecQueryResult.

Parameters

cameraMode

the working camera mode.

attachedSurfaces

the existing surfaces.

newUseCaseConfigsSupportedSizeMap

newly added UseCaseConfig to supported output sizes map.

videoStabilization

the video stabilization mode.

hasVideoCapture

whether the use cases has video capture.

isFeatureComboInvocation

whether the code flow involves CameraX feature combo API (e.g. androidx.camera.core.SessionConfig.requiredFeatureGroup).

findMaxSupportedFrameRate

whether to find the max supported frame rate. If this is true, the target frame rate settings will be ignored. If false, the returned value of SurfaceStreamSpecQueryResult.maxSupportedFrameRate is undetermined.

Throws

if the suggested solution for newUseCaseConfigs cannot be found. This may be due to no available output size or no available surface combination.