# This file is automatically generated by pyo3_stub_gen
# ruff: noqa: E501, F401, F403, F405
r"""
Medial Axis Transform (MAT) computation.

The MAT is the skeleton of a 2D domain — the set of points equidistant
to two or more boundary features.  It is computed via Delaunay-get_circumcenter
extraction from a constrained triangulation of the domain boundary.

* ``MedialAxis.compute`` — compute the MAT of a domain (with optional holes).
* ``MedialAxis.path_between`` — find a path between two points along the skeleton.
* ``MedialAxis.trim_to_polygons`` — filter nodes to those inside given polygons.
"""

import builtins
import typing
__all__ = [
    "MedialAxis",
]

@typing.final
class MedialAxis:
    r"""
    Medial Axis Transform of a planar domain.
    
    The MAT is the set of points equidistant to two or more boundary
    features, forming the skeleton of the free space.
    
    **Usage**:
    
    .. code-block:: python
    
       axis = MedialAxis.compute(outer, holes)
       path = axis.path_between((x1, y1), (x2, y2))
       trimmed = axis.trim_to_polygons(polygons)
       nodes = axis.nodes
       clearances = axis.clearances
       edges = axis.edges
       root = axis.root
       branches = axis.branches
    """
    @property
    def nodes(self) -> builtins.list[tuple[builtins.float, builtins.float]]: ...
    @property
    def clearances(self) -> builtins.list[builtins.float]: ...
    @property
    def edges(self) -> builtins.list[tuple[builtins.int, builtins.int]]: ...
    @property
    def root(self) -> builtins.int: ...
    @property
    def branches(self) -> builtins.list[builtins.list[builtins.int]]: ...
    @staticmethod
    def compute(outer: typing.Sequence[tuple[builtins.float, builtins.float]], holes: typing.Optional[typing.Sequence[typing.Sequence[tuple[builtins.float, builtins.float]]]] = None, min_clearance: builtins.float = 1.0, sampling_spacing: builtins.float = 1.0) -> MedialAxis:
        r"""
        Compute the Medial Axis Transform of a planar domain.
        
        :param outer: Outer boundary polygon (list of ``(x, y)`` vertices).
        :param holes: List of hole polygons (each a list of ``(x, y)`` vertices).
        :param min_clearance: Minimum clearance distance in mm.
        :param sampling_spacing: Spacing between sampling points in mm.
        :returns: ``MedialAxis`` object.
        """
    def path_between(self, from_pt: tuple[builtins.float, builtins.float], to_pt: tuple[builtins.float, builtins.float]) -> typing.Optional[builtins.list[tuple[builtins.float, builtins.float]]]:
        r"""
        Find a path between two points along the medial axis skeleton.
        
        :param from_pt: Start point ``(x, y)``.
        :param to_pt: End point ``(x, y)``.
        :returns: List of ``(x, y)`` waypoints along the medial axis.
        """
    def trim_to_polygons(self, polygons: typing.Sequence[typing.Sequence[tuple[builtins.float, builtins.float]]]) -> MedialAxis:
        r"""
        Return a new ``MedialAxis`` containing only nodes whose
        positions fall inside at least one of the given polygons.
        
        :param polygons: List of polygons to trim against.
        :returns: Trimmed ``MedialAxis``.
        """

