Intersections

ipctk.has_intersections(mesh: ipctk.CollisionMesh, vertices: numpy.ndarray[numpy.float64[m, n]], broad_phase_method: ipctk.BroadPhaseMethod = <BroadPhaseMethod.HASH_GRID: 1>) bool

Determine if the mesh has self intersections.

Parameters:
mesh

The collision mesh.

vertices

Vertices of the collision mesh.

broad_phase_method

The broad phase method to use.

Returns:

A boolean for if the mesh has intersections.

ipctk.is_edge_intersecting_triangle(e0: numpy.ndarray[numpy.float64[3, 1]], e1: numpy.ndarray[numpy.float64[3, 1]], t0: numpy.ndarray[numpy.float64[3, 1]], t1: numpy.ndarray[numpy.float64[3, 1]], t2: numpy.ndarray[numpy.float64[3, 1]]) bool
ipctk.segment_segment_intersect(A: numpy.ndarray[numpy.float64[2, 1]], B: numpy.ndarray[numpy.float64[2, 1]], C: numpy.ndarray[numpy.float64[2, 1]], D: numpy.ndarray[numpy.float64[2, 1]]) bool

Given two segments in 2d test whether they intersect each other using predicates orient2d

Parameters:
A: numpy.ndarray[numpy.float64[2, 1]]

1st endpoint of segment 1

B: numpy.ndarray[numpy.float64[2, 1]]

2st endpoint of segment 1

C: numpy.ndarray[numpy.float64[2, 1]]

1st endpoint of segment 2

D: numpy.ndarray[numpy.float64[2, 1]]

2st endpoint of segment 2

Returns:

true if they intersect


Last update: Dec 12, 2024