getOptimalPreviewSize

@Nullable
open fun getOptimalPreviewSize(surfaceWidth: Int, surfaceHeight: Int, @NonNull cameraType: CameraType): Camera.Size

Method returns optimal size for camera preview