setCameraFocusPosition method

FutureOr<int> setCameraFocusPosition(
  1. dynamic position
)

@hidden(macOS) @detail api @author zhangzhenyu.samuel @brief Sets the manual focus position for the currently used camera. @param position The position of the focus point. Setting the upper-left corner of the canvas as the origin, the x in position means the x-coordinate of the focus point in range of 0, 1, and the y in position means the y-coordinate of the focus point in range of 0, 1. @return - 0: Success. - < 0: Failure. See ByteRTCReturnStatus{@link #ByteRTCReturnStatus} for more details. @note - You must call startVideoCapture{@link #ByteRTCEngine#startVideoCapture} to start SDK internal video capturing, and use SDK internal rendering before calling this API. - When you set the focus point at the center of the canvas, the focus point setting will be canceled. - The camera focus point setting will be invalid after calling stopVideoCapture{@link #ByteRTCEngine#stopVideoCapture} to stop internal capturing.

Implementation

FutureOr<int> setCameraFocusPosition(CGPoint position) async {
  return await nativeCall('setCameraFocusPosition:', [position]);
}