Regular Contributor
Posts: 55
Accepted Solution

Boolean fails with "Inconsistent face-body relationships"


Could you please clarify the INCONS_FACE failure of api_unite?

There is a description at:


but it is still not clear what geometric/topological situation could lead to this failure.

Also, for some reason the info about position at which the failure happens is not present in "result".

Thank you!



Spatial Employee
Posts: 151

Re: Boolean fails with "Inconsistent face-body relationships"

Hi yt


for each intersecting pair of faces (one from tool and one from blank), the boolean algorithm generates an intersection edge.  These intersection edges form what we call the intersection graph.  The intersection graph should usually consist of a bunch of loops or circuits.  Booleans then imprints the intersection graph into the tool and the blank (to split the input faces with the edges from the intersection graph).  Then Booleans labels the faces depending on whether they were part of the tool or blank and inside of the tool or blank.  (There are really four states: face came from blank, inside tool; face came from blank outside of tool; face came from tool inside blank; face came from tool outside blank.)  


I think the incosistent face body relationship happens when the intersection graph doesn't form complete loops.  If this happens, some of the faces on the revised version of the (tool/blank) are partially inside and outside of the (blank/tool).  this makes it impossible to determine how to build the result.


The following scheme code gives a very oversimplified case where this can happen.  If you run the scheme script unmodified, it gives the error you describe because the intersection of the disk and block doesn't split the block into two pieces.  If you increase the radius of the disk to 8 then the disk splits the block and the boolean succeeds.


(define block (solid:block 0 0 0 8 8 8))
(entity:set-color block YELLOW)
(map (lambda(x)
(entity:set-material-transparency x .8))
(entity:faces block))
(define disk
(sheet:face ; turns face into sheet body
(position 4 4 4) ; center
(gvector 0 0 1) ; normal
6))) ;radius

(bool:intersect block disk)



The more typical cause for this problem is near coincident faces where the intersections are not clean between faces.  If intersectors gives up making a part of the intersection graph, there is a hole in the intersection graph and you can't tell how to classify the faces.


best regards


Eric Zenk

Regular Contributor
Posts: 55

Re: Boolean fails with "Inconsistent face-body relationships"

Thanks, it clarifies the issue!

I'm a little confused about radius=6, would not value 5 work better (so that disk would not split the block)? (it's not a problem of course, just something that caught my eye :) )