# This file is automatically generated by pyo3_stub_gen
# ruff: noqa: E501, F401, F403, F405
r"""
Circle-boundary overlap (engagement) metrics.
"""

__all__ = [
    "compute_engagement",
    "get_angular_engagement",
    "get_disk_segment_area",
    "get_point_engagement",
]

def compute_engagement(d_to_boundary: float, radius: float) -> tuple[float, float, float]:
    r"""
    Compute engagement angle, area, and chord depth.
    
    :param d_to_boundary: Signed distance from the point to the nearest boundary
        (mm).  Positive = outside the boundary.
    :param radius: Disk radius (mm).
    :returns: ``(angle_rad, area, chord_depth)``.
    """

def get_angular_engagement(center: tuple[float, float], radius: float, fragments: list[list[tuple[float, float]]]) -> float:
    r"""
    Angular engagement (exact circle–polygon intersection).
    
    Returns uncleared angular extent in ``[0, 2π]``.
    
    :param center: Disk centre ``(x, y)``.
    :param radius: Disk radius (mm).
    :param fragments: List of polygons (cleared fragments).
    :returns: Angular engagement in radians.
    """

def get_disk_segment_area(x: float, r: float) -> float:
    r"""
    Area under 2*sqrt(r²-x²) from x to r.
    
    Equivalent to the area of the circular segment to the right of
    the vertical line at ``x`` for a disk of radius ``r`` centred
    at the origin.
    
    :param x: Left boundary of the segment.
    :param r: Disk radius.
    :returns: Area of the circular segment.
    """

def get_point_engagement(center: tuple[float, float], radius: float, fragments: list[list[tuple[float, float]]]) -> tuple[float, float, float]:
    r"""
    Engagement angle, area, and chord depth at a disk centre.
    
    :param center: Disk centre ``(x, y)``.
    :param radius: Disk radius (mm).
    :param fragments: List of polygons (cleared fragments).
    :returns: ``(angle_rad, area, chord_depth)``.
    """

