
    l0j                     6    d dl ZddlmZmZ dee         fdZdS )    N   )DictListreturnc                 :   ddl m} t          j        t          j        t          | j                  t          j                  dz  | j        f                                          	                    t          j
                  }d  || j        |fi |D             S )a  
    Compute an approximate convex decomposition of a mesh.

    VHACD Parameters which can be passed as kwargs:

    Name                              Default
    -----------------------------------------
    maxConvexHulls                    64
    resolution                        400000
    minimumVolumePercentErrorAllowed  1.0
    maxRecursionDepth                 10
    shrinkWrap                        True
    fillMode                          "flood"
    maxNumVerticesPerCH               64
    asyncACD                          True
    minEdgeLength                     2
    findBestPlane                     False

    Parameters
    ----------
    mesh : trimesh.Trimesh
      Mesh to be decomposed into convex parts
    **kwargs : VHACD keyword arguments

    Returns
    -------
    mesh_args : list
      List of **kwargs for Trimeshes that are nearly
      convex and approximate the original.
    r   )compute_vhacd)dtype   c                     g | ]
\  }}||d S ))verticesfaces ).0vfs      X/home/wildlama/miniconda3/envs/lam/lib/python3.11/site-packages/trimesh/decomposition.py
<listcomp>z(convex_decomposition.<locals>.<listcomp>0   s4       Aq ##      )vhacdxr   npcolumn_stackoneslenr   int64ravelastypeuint32r   )meshkwargsr   r   s       r   convex_decompositionr       s    > %$$$$$ 	TZAAAAEtzRSS					 
 !M$-AA&AA   r   )numpyr   typedr   r   r    r   r   r   <module>r#      sR               -DJ - - - - - -r   