Skip to content

Arc2DUtil

implementation of the arc 2D utility class

Arc2DUtil

Canonical path: Utils.Geometry.Arc2DUtil.Arc2DUtil

implementation of the arc 2D utility class

create staticmethod

create(
    center: Point2D,
    radius: float,
    angle_start: float = 0.0,
    angle_end: float = 360.0,
) -> Arc2D | None

create a 2d arc

Parameters:

  • center (Point2D) –

    center point of the arc

  • radius (float) –

    radius

  • angle_start (float, default: 0.0 ) –

    start angle

  • angle_end (float, default: 360.0 ) –

    end angle

Returns:

  • Arc2D | None

    created arc or None if start and end angle are equal

create_arc_from_center_start_delta staticmethod

create_arc_from_center_start_delta(
    center_point: Point2D, start_point: Point2D, delta_angle: float
) -> Arc2D

create an arc from center, start point and delta angle

Parameters:

  • center_point (Point2D) –

    center point of the arc

  • start_point (Point2D) –

    start point of the arc

  • delta_angle (float) –

    angle between start and end point

Returns:

create_arc_from_center_start_end_point staticmethod

create_arc_from_center_start_end_point(
    center_point: Point2D, start_point: Point2D, end_point: Point2D
) -> Arc2D

create an arc from center, start and end point

Parameters:

  • center_point (Point2D) –

    center point of the arc

  • start_point (Point2D) –

    start point of the arc

  • end_point (Point2D) –

    end point of the arc

Returns:

create_arc_from_tangent_and_end_point staticmethod

create_arc_from_tangent_and_end_point(
    tangent: Line2D, end_point: Point2D
) -> Arc2D

create an arc tangential from a line to a point

Parameters:

  • tangent (Line2D) –

    tangent line

  • end_point (Point2D) –

    end point of the arc

Returns:

create_circle staticmethod

create_circle(center_point: Point2D, radius: float)

create a 2d circle

Parameters:

  • center_point (Point2D) –

    center point of the circle

  • radius (float) –

    radius

create_polygonized_arc staticmethod

create_polygonized_arc(
    x_center: float,
    y_center: float,
    radius: float,
    angle_start: float = 0.0,
    angle_end: float = 360.0,
) -> Polygon2D | None

create a 2d arc converted to a polygon

Parameters:

  • x_center (float) –

    x coordinate center

  • y_center (float) –

    y coordinate center

  • radius (float) –

    radius

  • angle_start (float, default: 0.0 ) –

    start angle

  • angle_end (float, default: 360.0 ) –

    end angle

Returns:

  • Polygon2D | None

    created arc or None if start and end angle are equal

Placeholder