Skip to main content

OH_Drawing_PathConicTo

Function OH_Drawing_PathConicTo 

Source
pub unsafe extern "C" fn OH_Drawing_PathConicTo(
    path: *mut OH_Drawing_Path,
    ctrlX: f32,
    ctrlY: f32,
    endX: f32,
    endY: f32,
    weight: f32,
)
Expand description

@brief Draws a conic curve from the last point of a path to the target point. If the path is empty, the start point ( 0, 0) is used. This API may return an error code. For details, call {@link OH_Drawing_ErrorCodeGet}. If path is NULL, OH_DRAWING_ERROR_INVALID_PARAMETER is returned.

@param path Pointer to the {@link OH_Drawing_Path} object. @param ctrlX X coordinate of the control point. @param ctrlY Y coordinate of the control point. @param endX X coordinate of the target point. @param endY Y coordinate of the target point. @param weight Weight of the curve, which determines its shape. The larger the value, the closer of the curve to the control point. If the value is less than or equal to 0, the result is equivalent to a line segment from the start point to the end point, which is added by calling {@link OH_Drawing_PathLineTo}. If the value is 1, the result is equivalent to {@link OH_Drawing_PathQuadTo}. @since 12 @version 1.0