copyleft.mesh_boolean
mesh_boolean(V1, F1, V2, F2, boolean_type='union')
Finds intersection, union or subtraction of two triangle meshes.
Given two triangle meshes dA and dB, uses exact predicates to compute the intersection, union or subtraction of the two solids A and B, and output its surface dC
Parameters:
Name | Type | Description | Default |
---|---|---|---|
V1 |
numpy double array
|
Matrix of vertex coordinates of the first mesh |
required |
F1 |
numpy int array
|
Matrix of triangle indices of the first mesh |
required |
V2 |
numpy double array
|
Matrix of vertex coordinates of the second mesh |
required |
F2 |
numpy int array
|
Matrix of triangle indices of the second mesh |
required |
boolean_type |
str, optional (default 'union')
|
Operation: one of 'union' (default), 'intersection', 'difference' |
'union'
|
Returns:
Name | Type | Description |
---|---|---|
V3 |
numpy double array
|
Matrix of vertex coordinates of the first mesh |
F3 |
numpy int array
|
Matrix of triangle indices of the first mesh |
See Also
do_meshes_intersect.
Notes
'minus', 'difference' and 'subtraction' are alias or one another
Examples:
TO-DO
Source code in src/gpytoolbox/copyleft/mesh_boolean.py
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 |
|